PRB: CDO Can't Send Meeting Requests Based on Custom AppointmentItems
ID: Q246616
|
The information in this article applies to:
-
Collaboration Data Objects (CDO), versions 1.2, 1.21
SYMPTOMS
When you use CDO to programmatically create a MeetingItem from a customized AppointmentItem, and send it to a recipient, the recipient gets a meeting request with a standard AppointmentItem in it. Accepting the meeting request saves a standard AppointmentItem into the recipient's calendar.
Please note that in this scenario, CDO doesn't produce any error message when you send the MeetingItem.
CAUSE
This is a design limitation of CDO library. It doesn't support sending meeting requests based on custom AppointmentItems.
RESOLUTION
If possible, use Outlook Object model to send such meeting requests. The following Microsoft Visual Basic code demonstrates how to do this using the Outlook Object Model:
'To run the code, please have a reference to Microsoft Outlook Object library from your Visual Basic project.
Set objOlApp = CreateObject("Outlook.Application")
Set objNamespace = objOlApp.GetNamespace("MAPI")<BR/>
objNamespace.Logon
Set objFolder = objNamespace.GetDefaultFolder(olFolderCalendar)
Set objItems = objFolder.Items
Set objItem = objItems.Add("IPM.Appointment.CustomAppointmentItem") 'TO DO:Please replace the message class in parenthesis with your custom AppointmentItem's message class
objItem.MeetingStatus = 1 'olMeeting
objItem.Subject = "Strategy Meeting"
objItem.Start = #12/27/99 1:30:00 PM#
objItem.Duration = 90
Set objRequiredAttendee = objItem.Recipients.Add("A recipient name goes here")
objItem.Send
Additional query words:
Keywords : kbCDO120 kbCDO121 kbMAPI kbDSupport
Version : WINDOWS:1.2,1.21
Platform : WINDOWS
Issue type : kbprb