Cancels the editing.
The following example demonstrates how to shift the update and cancel buttons to the editor's toolbar:
- To hide the standard Update / Cancel buttons, set the ShowSubmitCancelButtons property to "false".
- After that open the ~/RadControls/Editor/ToolsFile.xml file and declare the Update and Cancel toolbar buttons
<tool name="Save" />
<tool name="Cancel" />
- The last step is to add their javascript commands under the editor's declaration:
| ASPX/ASCX |
Copy Code |
|
<rad:RadEditor ID="RadEditor1" SaveInFile="true" ShowSubmitCancelButtons="false" runat="server"></rad:RadEditor> <script type="text/javascript"> if (typeof(RadEditorCommandList) != "undefined") { RadEditorCommandList["Save"] = function(commandName, editor, oTool) { editor.Submit(); } RadEditorCommandList["Cancel"] = function(commandName, editor, oTool) { editor.CancelEdit(); } } </script> |