This method executes a command against the the text control. There is a
predefined list of commands that can be executed against the control. A list of each
command and what it does is found below.
- clear - Clears the current document.
- copy - Copies the selection to the clipboard.
- cut - Cuts the selection to the clipboard.
- delete - Deletes the selection or item at cursor.
- paste - Pastes the content of the clipboard at cursor ar selection.
- redo - Redoes the last undone action.
- selectAll - Selects the entire document.
- undo - Restores the document to the state before the last change.
function onPasteCmd()
{
var savedFocusedBox = scene.savedFocusedBox;
if (savedFocusedBox && savedFocusedBox.boxType == "nativeText")
{
savedFocusedBox.execCmd("paste", 0, null);
}
}