IPersistMessage::HandsOffMessage
Applies to: Outlook 2013 | Outlook 2016
Causes the form to release its current message.
HRESULT HandsOffMessage( void );
Parameters
None
Return value
S_OK
The message was successfully released.
Remarks
Forms transition into two HandsOff states:
When a form is in either of these states, it is in the process of being stored permanently.
Notes to implementers
When a form viewer calls the IPersistMessage::HandsOffMessage method while your form is in the Normal or NoScribble state, recursively call HandsOffMessage on each message embedded in the current message and the IPersistStorage::HandsOffStorage method on each OLE object embedded in the current message. Then release the current message and all embedded messages and OLE objects. If your form was in the Normal state, transition to the HandsOffFromNormal state. If your form was in the NoScribble state, transition to the HandsOffAfterSave state. After a successful transition, call the message's IUnknown::Release method and return S_OK.
When a form viewer calls HandsOffMessage while your form is in either of the HandsOff states, return E_UNEXPECTED.
For more information about the different states of a form, see Form States. For more information about how to work with the HandsOff state of storage objects, see the IPersistStorage::HandsOffStorage method.