The CreateMessage method creates a new message within the current folder.
CreateMessage creates a new message with generic or associated content and assigns an entry identifier. The entry identifier is made up of a part that represents the message store provider and a part that represents the individual message.
The lppMessage must be released to clean up the allocated memory.
The entry identifier of the new message is available immediately after CreateMessage returns.
Expect the entry identifier assigned to the new message to be unique within the current message store as well as across all of the message stores that are open concurrently. One exception to this general rule occurs when multiple entries for a message store appear in the profile, causing the message store to be opened multiple times and entry identifiers to be duplicated.
To create an outgoing message, call the Outbox folder's CreateMessage method. Then call IMessage::SubmitMessage to actually send the message.
If you delete a folder containing a new message before the message is saved, the results are undefined.