IOleUndoManager::Open

Opens a new parent undo unit, which becomes part of its containing unit's undo stack.

HRESULT Open(
  IOleParentUndoUnit* pPUU   //Pointer to the parent undo unit to 
                             // open
);
 

Parameters

pPUU
[in] Pointer to the parent undo unit to be opened.

Return Values

S_OK
The parent undo unit was successfully opened or if a currently open unit is blocked. If the undo manager is currently disabled, it should return S_OK and do nothing else.

Remarks

This method is implemented the same as IOleParentUndoUnit::Open. The specified parent unit is created and remains open. The undo manager then calls the Add or Open methods on this parent unit to add new units to it. This parent unit receives any additional undo units until its Close method is called.

The parent unit specified by pPUU is not added to the undo stack until its Close method is called with the fCommit parameter set to TRUE.

The parent undo unit or undo manager must contain any undo unit given to it unless it is blocked. If it is blocked, it must return S_OK but should do nothing else.

QuickInfo

  Windows NT: Use version 4.0 or later. New for OC96.
  Windows: Use Windows 95 or later. New for OC96.
  Windows CE: Unsupported.
  Header: Declared in ocidl.h.

See Also

IOleParentUndoUnit::Open