ID: Q196258
The information in this article applies to:
When you use the Exchange Scripting Agent to accept or decline meeting requests programmatically, the following line of code might return a Message object instead of a MeetingItem object:
Set oMtg = EventDetails.Session.GetMessage(EventDetails.MessageID, Null)
For example, if you use AutoAccept script, the following log might be added
into the script log when a meeting item (that is, a meeting request or
meeting response) arrives:
Message is not a meeting request or response.
The Event Scripting Agent might be using an earlier version of CDO library. In this case, the Class property of the Message object returns 3 (for a Message) instead of 26 (for an AppointmentItem).
This might happen if you install Microsoft Outlook 97 after you install Microsoft Exchange Server on the same computer and you stop or start Microsoft Exchange Event Service.
When you install Microsoft Outlook 97, Outlook 97 installs and registers an earlier version of CDO, that is, the Active Messaging Library (OLEMsg32.dll). The Active Messaging Library (CDO 1.1) does not support meeting items. Therefore, the GetMessage method of the Session object returns a Message object instead of a MeetingItem object.
Follow these steps to resolve the problem:
1. Re-register CDO.dll by typing the following line at the MS-DOS command
prompt:
regsvr32.exe cdo.dll
2. Go to Control Panel, and click Services.
3. Stop and start Microsoft Exchange Event Service.
This behavior is by design.
To see what version of CDO that the Event Scripting Agent is using, use the Version property of the Session object (EventDetails.Session.Version).
The following article in the Microsoft Knowledge Base explains another possible cause for getting the incorrect Message.Class from GetMessage method:
ARTICLE-ID: Q194806
TITLE : PRB: Message.Class Incorrect After Calling GetMessage()
Additional query words:
Keywords : kbActMsg kbCDO kbCDO110 kbXchge550 kbMsg
Version : WINDOWS:1.1; WINNT:5.5
Issue type : kbprb
Last Reviewed: November 25, 1998