Cancels the last edit in an edit control, restoring the text to the content before the last change.
DataWindow, MultiLineEdit, RichTextEdit, and SingleLineEdit controls
editname.Undo ( )
Argument |
Description |
---|---|
editname |
The name of the DataWindow control, MultiLineEdit, RichTextEdit, or SingleLineEdit in which you want to cancel (reverse) the last edit. For a DataWindow control, reverses the last edit in the edit control over the current row and column. |
Integer. Returns 1 when it succeeds and -1 if an error occurs. If editname is null, Undo returns null.
To determine whether the last action can be canceled, call the CanUndo function.
This statement reverses the last edit in MultiLineEdit mle_Contact:
mle_Contact.Undo()
The following statement checks to see if the last edit in the MultiLineEdit mle_Contact can be reversed, and if so reverse it:
IF mle_Contact.CanUndo() THEN mle_Contact.Undo()