Rediger

Del via


IMAPISupport::DoSentMail

Applies to: Outlook 2013 | Outlook 2016

Processes a sent message.

HRESULT DoSentMail(
  ULONG ulFlags,
  LPMESSAGE lpMessage
);

Parameters

ulFlags

[in] Reserved; must be zero.

lpMessage

[in] A pointer to the open message for which a message should be generated in the folder designated to hold sent items.

Return value

S_OK

The call succeeded and has returned the expected value or values.

Remarks

The IMAPISupport::DoSentMail method is implemented for message store provider support objects. Message store providers call DoSentMail from their implementation of the IMsgStore::FinishedMsg method, which is called by the MAPI spooler when it has finished processing a message. FinishedMsg unlocks the message, ensures that the message's reference count is 1, and calls DoSentMail.

DoSentMail performs the following tasks:

  • Checks the message for the PR_DELETE_AFTER_SUBMIT (PidTagDeleteAfterSubmit) property to determine whether the message should be deleted after sending.

  • Determines the location of the Sent Items folder.

  • Initiates message hook processing for any hooks set on the Sent Items folder.

  • Moves the message to the Sent Items folder, Deleted Items folder, or to another folder.

  • Releases the message.

See also

IMsgStore::FinishedMsg

PidTagDeleteAfterSubmit Canonical Property

IMAPISupport : IUnknown