We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

How can I edit in a RichText cell?

By default, the RichText cell control in the library allows you to edit richtext via a dropdown panel. It does not allow you to edit the text in place. You can derive the GridRichTextBoxCellModel and GridRichTextBoxCellRenderer classes to use an embedded RichTextBox in the cell to do active editing.

 

Creating CellModel:

Refer to the following code to create the CustomCellModel.

C#

 

VB

 

Creating CellRenderer:

The following code is used to create the custom CellRenderer.

C#

 

VB

 

Context Menu Handlers:

C#

 

VB

 

Helper methods for the renderer class:

The following code is used to create helper method.

C#

 

VB

 

C#

 

VB

 

Event overrides OnDraw:

To handle drawing on cell.

C#

 

VB

 

OnInitialize:

To set value into the cell control and initialize it.

C#

 

VB

 

OnClick:

C#

 

VB

 

Copy Paste overrides:

C#

 

VB

 

Adding CellModel:

C#

 

VB

 

Assigning CellType

C#

 

VB

 

Screenshot

Figure 1: In place editing in RichText cell

Sample Links:

InplaceRichTextBox-C#

InplaceRichTextBox-VB

 

Article ID: Published Date: Last Revised Date: Platform: Control:
453 04/30/2011 02/08/2017 Windows Forms GridControl
Did you find this information helpful?
Add Comment
You must log in to leave a comment

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.