Glossary Item Box
Editor has some client-side events:
| Client-side event | Description |
| onChange | Occurs when Editor contents changed. |
| onChangeMode | Occurs when the user moves the mouse pointer into a tab in the TabConrol. |
| onSpellCheck | Occurs when SpellCheck command in Editor called. |
| onCommand | Occurs when any command in Editor called. |
| onCustomCommand | Occurs when custom command in Editor called. |
This provides full support for server-side events and allow for extended programmatic access to the editor's event model. API commands allows users to insert, modify, get or set text into editor.
Editor API functions:
| Function name | Description |
| al_Editor_InsertHtml(clientID, html) | Inserts HTML at the current cursor position. |
| al_Editor_SurroundHtml(clientID, before, after) | Surrounds the currently selected text (and HTML) with the given strings. |
| al_Editor_GetHtml(clientID) | Returns the HTML currently in the editor. |
| al_Editor_SetHtml(clientID, html) | Sets the HTML in the editor. |
| al_Editor_SetVisible(clientID, isVisible) | Shows or hides the control with identifier clientID, new state depends on isVisible attribute |
middle, commandValue) |
Executes commands based on the MSHTML (for IE) and Midas (for Firefox) specifications |
| Queres the state of the current cursor position | |
| al_Editor_Focus(clientID) | Sets the focus on the current editor clientID - identifier of the Editor (use args.ClientID field) |
| al_Editor_ChangeMode(clientID, mode) | Changes the mode of the Editor control with identifier clientID. Use mode attribute to define new mode type: 0 - Design mode; 1 - HTML mode; 2 - Preview mode |
| See Also |
Controls: Editor