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.

.NET Framework 3.5 版中引進了 UndoLimitUndoLimit is introduced in the .NET Framework version 3.5. 如需詳細資訊,請參閱版本和相依性For more information, see Versions and Dependencies.

適用於