The Hands Off After Save state is part of the process of saving the contents of a form to permanent storage. When in this state, the form object should refrain from making changes to the in-memory copies of values of the message's properties, since there may not be another opportunity to save those changes. Legal transitions from the Hands Off After Save state are described in the following table.
IPersistMessage method |
Action |
New State |
SaveCompleted( pMessage != NULL) |
Open any embedded objects. The data in the message stored in pMessage is guaranteed to be the same as the message in the previous Save call. If the SaveCompleted call succeeds, enter the Normal state. Otherwise, set the last error to E_OUTOFMEMORY and stay in the Hands Off After Save state. |
Normal or Hands Off After Save |
SaveCompleted( pMessage == NULL) |
Set the last error to E_INVALIDARG or E_UNEXPECTED |
Hands Off After Save |
HandsOffMessage, Save, or InitNew |
Set the last error to and return E_UNEXPECTED |
Hands Off After Save |
Load |
Load the form object with data from the target message. This call can occur when the form object is going to the next or previous message in a folder. |
Normal |
GetLastError |
Return the last error. |
Hands Off After Save |
Other IPersistMessage methods or methods from other interfaces |
Set the last error to and return E_UNEXPECTED |
Hands Off After Save |