You are correct. I actually saw that after posting the message by looking at an event sent from Outlook. Must be a new requirement. The UDF that I based the CFC off off didn't have it but it still worked.
Thanks.
Main Topics
Browse All TopicsI have created the following CFC based on a UDF I found online somewhere. It basically creates a .ics (iCalendar) file that is e-mailed to a client. The event is accepted by iCal on the Mac but fails when someone with MS Outlook tries to open it. I even added a bunch of fields that I noticed in an icalendar event sent from Outlook but it still fails. I also added the contents of the generated ics file below...
Any suggestion?
===========The CFC======================
<cfcomponent>
<cffunction name="iCal" access="public" returntype="string">
<cfargument name="EventID" type="numeric" required="no" default="1">
<cfquery name="stEvent" datasource="#application.d
SELECT Title as subject,"Host", (City + '\, ' + State) as location, StartDate as StartTime, EndDate as EndTime, Description, contactemail, '1' as Priority
FROM dbo.tbl_calendar WHERE EventID = #Arguments.EventID#
</cfquery>
<cfset vCal = "">
<cfset CRLF = "#chr(13)#">
<cfscript>
if (NOT IsDefined("stEvent.StartTi
stEvent.StartTime = DateConvert('local2Utc', Now());
//if (NOT IsDefined("stEvent.EndTime
//stEvent.EndTime = DateConvert('local2Utc', Now());
if (NOT IsDefined("stEvent.locatio
stEvent.location = "N/A";
if (NOT IsDefined("stEvent.subject
stEvent.subject = "Auto vCalendar Generated";
if (NOT IsDefined("stEvent.descrip
stEvent.description = "Autobot VCalendar Generated";
if (NOT IsDefined("stEvent.priorit
stEvent.priority = "1";
vCal = "BEGIN:VCALENDAR" & CRLF;
vCal = vCal & "PRODID:-//Microsoft Corporation//Outlook 10.0 MIMEDIR//EN" & CRLF;
vCal = vCal & "VERSION:2.0" & CRLF;
vCal = vCal & "METHOD:PUBLISH" & CRLF;
vCal = vCal & "BEGIN:VEVENT" & CRLF;
vCal = vCal & "ORGANIZER:MAILTO:support@
vCal = vCal & "DTSTART:" &
DateFormat(stEvent.StartTi
TimeFormat(stEvent.StartTi
vCal = vCal & "DTEND:" &
DateFormat(stEvent.StartTi
TimeFormat(stEvent.StartTi
vCal = vCal & "LOCATION:" & stEvent.location & CRLF;
vCal = vCal & "TRANSP:OPAQUE" & CRLF;
vCal = vCal & "SEQUENCE:0" & CRLF;
vCal = vCal & "DESCRIPTION:";
// Convert CF_CRLF (13_10) into =0D=0A with CR/LF and indent sequences
description = REReplace(stEvent.descript
vCal = vCal & description & CRLF;
vCal = vCal & "SUMMARY:" & stEvent.subject & CRLF;
vCal = vCal & "PRIORITY:" & stEvent.priority & CRLF;
vCal = vCal & "CLASS:PUBLIC" & CRLF;
vCal = vCal & "END:VEVENT" & CRLF;
vCal = vCal & "END:VCALENDAR";
</cfscript>
<cffile action="write" file="D:\Websites\test\san
<cfmail to="phayes@xxxs.com" from="phayes@xxx.com" subject="Vcal Test">
<cfmailparam file="D:\Websites\test\san
</cfmail>
<cfset Status = "Success!">
<cfreturn status>
</cffunction>
==========================
=========The contents of the ICS file=========
BEGIN:VCALENDAR
PRODID:-//Microsoft Corporation//Outlook 10.0 MIMEDIR//EN
VERSION:2.0
METHOD:PUBLISH
BEGIN:VEVENT
ORGANIZER:MAILTO:support@s
DTSTART:20050916T000000Z
DTEND:20050916T000000Z
LOCATION:Norwalk\, CT
TRANSP:OPAQUE
SEQUENCE:0
DESCRIPTION:The MAC meeting is scheduled for Wednesday, June 16, 2004 1 p.m. at Norwalk Hospital Emergency Department Conference Room.
SUMMARY:Medical Advisory Committee (MAC) Meeting
PRIORITY:1
CLASS:PUBLIC
END:VEVENT
END:VCALENDAR
=======================
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Business Accounts
Answer for Membership
by: mmc98dl1Posted on 2005-05-22 at 16:54:19ID: 14056972
You are missing a UID and DTSTAMP line:
iriusinnov ations.com
BEGIN:VCALENDAR
PRODID:-//Microsoft Corporation//Outlook 10.0
MIMEDIR//EN
VERSION:2.0
METHOD:PUBLISH
BEGIN:VEVENT
ORGANIZER:MAILTO:support@s
DTSTART:20050916T000000Z
DTEND:20050916T000000Z
DTSTAMP:20050916T000000Z
UID:9047850398543
LOCATION:Norwalk\, CT
TRANSP:OPAQUE
SEQUENCE:0
DESCRIPTION:The MAC meeting is scheduled for
Wednesday, June 16, 2004 1 p.m. at Norwalk
Hospital Emergency Department Conference Room.
SUMMARY:Medical Advisory Committee (MAC) Meeting
PRIORITY:1
CLASS:PUBLIC
END:VEVENT
END:VCALENDAR