Platform SDK: Exchange Server

IExchExtSessionEvents::OnDelivery

Replaces or enhances the behavior of Microsoft Exchange when a new message arrives.

Quick Info

See IExchExtSessionEvents : IUnknown.

HRESULT OnDelivery(
  LPEXCHEXTCALLBACK lpeecb  
);
 

Parameters

lpeecb
[in] Pointer to the IExchExtCallback interface. The lpeecb parameter is used to determine information about the message or messages which have arrived.

Return Values

S_OK
The extension object replaced Microsoft Exchange default behavior with its own behavior. Microsoft Exchange will consider the task handled.
S_FALSE
The extension object did nothing or added additional behavior. Microsoft Exchange will continue to call extension objects or complete the work itself.

Remarks

The IExchExtSessionEvents::OnDelivery method is used to replace or enhance the behavior of Microsoft Exchange when a new message arrives. If an error occurs, OnDelivery should display an error message and return an error value. Microsoft Exchange will not notify the user about the new message, nor will it display an error message or continue to call extension objects in response to the new message.

When a new message arrives, the extension object obtains its message identifier by calling the IExchExtCallback::GetObject method.

See Also

IExchExtCallback::GetObject