UndoEnabled property

Microsoft Visio Developer Reference

UndoEnabled property

       

Determines whether undo information is maintained in memory.

Version added

2000

Syntax

boolVal = object.UndoEnabled
object.UndoEnabled = boolExpression

boolVal

Boolean. True if the property is enabled; False if it is not.

object

Required. An expression that returns an Application object.

boolExpression

Required Boolean. True to enable undo; otherwise, False.

Remarks

When Visio starts, the value of the UndoEnabled property is True. Setting the value of the UndoEnabled property to False discontinues the collection of undo information in memory and purges the existing undo information.

An attempt should be made to maintain the property at its current value across the complete operation that you perform. In other words, use code structured like this:

bPrev = Application.UndoEnabled
Application.UndoEnabled = False
'large operation here
Application.UndoEnabled = bPrev