Free Trial Buy Now

Client-Side API - Client-Side Selection

Undo (Ctrl+Z)
Redo (Ctrl+Y)
Align Left
Align Center
Align Right
Justify
v
Design
HTML
Preview

Description

This demo shows how to interact with the editor's selection using the client-side API.

The ASPxHtmlEditor provides a comprehensive API, allowing you to access and modify the currently selected content at the client side. To access the selection, use the editor's GetSelection client function, which returns an ASPxClientHtmlEditorSelection class instance. With methods of this class, you can perform your tasks on the selection. In this demo, the ASPxClientHtmlEditorSelection.GetElements client function is used to access the selection's HTML elements (XML DOM nodes). These elements are used then to retrieve references to text nodes and modify their values based on the case update method (see the demo's ChangeCase JavaScript function). You can select the case update method via the corresponding toolbar dropdown menu.

Note that the selection API is available only in the Design View.

Version: v2012 vol 2.8
Experience the DevExpress Difference Today
Demos with source code are included with an installation of DevExpress controls for ASP.NET. Refer to the Demos and Sample Applications topic to learn more.
To download your free evaluation copy of our award-winning ASP.NET libraries, visit the Downloads page
All DevExpress ASP.NET Controls ship as part of DXperience ASP.NET, Enterprise, and Universal.
To obtain pricing information, visit the Pricing Options page or contact us via Email at info@devexpress.com
or by telephone at +1 (818) 844-3383 between 8:30am and 5pm Pacific Time.