Platform SDK: Exchange 2000 Server

Creating a Message

[This is preliminary documentation and subject to change.]

To begin building a new message, first create an instance of the Message COM class, as shown in the following example:

[Visual Basic]
' Reference to Microsoft ActiveX Data Objects 2.5 Library
' Reference to Microsoft CDO for Exchange 2000 Server Library
Dim iMsg as new CDO.Message
[C++,IDL]
#import "c:\program files\common files\system\ado\msado15.dll" no_namespace
#import "c:\exchsrvr\cdoex.dll" no_namespace
// ...
MessagePtr iMsg(__uuidof(Message));
[VBScript]
Dim iMsg
Set iMsg = CreateObject("CDO.Message")

You can create and send or post a simple message using only the IMessage interface.