TextBoxBase.UndoLimit 属性

定义

获取或设置存储在撤消队列中的操作的数目。Gets or sets the number of actions stored in the undo queue.

public:
 property int UndoLimit { int get(); void set(int value); };
public int UndoLimit { get; set; }
member this.UndoLimit : int with get, set
Public Property UndoLimit As Integer

属性值

存储在撤消队列中的操作的数目。The number of actions stored in the undo queue. 默认值为-1, 表示撤消队列限制为可用的内存。The default is -1, which means the undo queue is limited to the memory that is available.

异常

UndoLimit 是在调用 BeginChange() 之后且在调用 EndChange() 之前设置的。UndoLimit is set after calling BeginChange() and before calling EndChange().

注解

设置UndoLimit将清除撤消队列。Setting UndoLimit clears the undo queue. 如果UndoLimit设置为-1, 则撤消队列仅受可用内存的限制。When UndoLimit is set to -1, the undo queue is limited only by the memory that is available. 如果UndoLimit设置为 0, 则将TextBoxBase在上禁用撤消。When UndoLimit is set to 0, undo is disabled on the TextBoxBase.

UndoLimit.NET Framework 版本3.5 中引入。UndoLimit is introduced in the .NET Framework version 3.5. 有关详细信息,请参见版本和依赖关系For more information, see Versions and Dependencies.

适用于