Word) (Document.UndoClear 方法

清除指定文件的可復原動作清單。

語法

expression. UndoClear

需要 expression。 代表 Document 物件的變數。

註解

This method corresponds to the list of items that appears when you click the arrow beside the Undo button on the Standard toolbar. 您可以在巨集的結尾加入此方法,以便防止 Visual Basic 動作出現在 [復原] 方塊中 (例如 "VBA-Selection.InsertAfter")。

範例

這則範例會清除使用中文件的可復原動作清單。

ActiveDocument.UndoClear

另請參閱

Document 物件

支援和意見反應

有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應