select

Editor / Client-side Events

Rate this demo: Feedback
Run example in: C# VB.NET Change Skin:
Vista
  • BlackBlack
  • DefaultDefault
  • ForestForest
  • HayHay
  • Office2007Office2007
  • OutlookOutlook
  • SimpleSimple
  • SitefinitySitefinity
  • SunsetSunset
  • TelerikTelerik
  • VistaVista
  • Web20Web20
  • WebBlueWebBlue
  • Windows7Windows7
The current selection is:
The executed event is:
Simple symbol counter:
   
  
 
 
   

Example Source Code & Description

Instructions
Open in new window
  • Client-Side Events

    RadEditor provides a rich client-side event model. You can attach custom client-script code (JavaScript) to a number of client-side events fired by the editor. All client-side events are exposed as string properties to the RadEditor instance with the value being the name of the JavaScript function to be called. 
    Below is a list of all client-side events and methods that are currently supported by RadEditor:

    Events

    1. OnClientInit - fired before RadEditor initialization
    2. OnClientLoad  - fired after the RadEditor is loaded on the client
    3. OnClientCommandExecuting - fired just before a command is executed
    4. OnClientCommandExecuted - fired after a command is executed 
    5. OnClientSelectionChange - fired when the selection within the editor content area has changed
    6. OnClientModeChange - fired when the editor's mode is changed
    7. OnClientSubmit - fired when the editor saves its content just before a postback/ajax request 

    The example above demonstrates some of the most useful editor Client-side Events for loading, editor command execution and content area selection. The OnClientSelection Changed event is very important and shown in action above, where the current editor content area selection is captured and displayed in a DIV element.

Compatible with ASP.NET 2.0, 3.5 AJAX enabled Accessibility Verified!Valid XHTML 1.1! Optimized for Visual Studio 2005, 2008
Copyright 2002-2010 © Telerik. All right reserved  | 
Telerik Inc., 460 Totten Pond Rd, Suite 640, Waltham, MA 02451

www.telerik.com  |  Terms of Use  |  Contact Us