This is a migrated thread and some comments may be shown as answers.

Subclass GridViewTextboxColumn

1 Answer 96 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Lasse
Top achievements
Rank 1
Lasse asked on 09 Nov 2011, 02:19 PM
Hi, 

Need some special behavior on a textbox column. 
Like doing something in the textchanging event, keypress event and validation event.
And i want to be able to set a fixed length on the  text box. 
I need to do for several grids and several columns.
I know that i can do this by subscribing to events on the activeeditor -> textboxitem. But i want to subclass the GridViewTextboxColumn and do it directly, so i dont need to write the same code over and over again.

Can you please help me?

Regards
Svein Thomas

1 Answer, 1 is accepted

Sort by
0
Ivan Petrov
Telerik team
answered on 14 Nov 2011, 07:19 PM
Hi Svein Thomas,

Thank you for writing.

It seems you will need a custom column with a custom cell. You can see what you can achieve with a custom cell by going to this article in our product documentation - RadGridView - Custom cell. Also, you might want to extend the behavior of the editor. You can do that by creating your own editor which would be specific to your custom column. You can take a look at this help article on Using custom editors.

I hope this will help you. If you need further assistance I would be glad to provide it.

All the best,
Ivan Petrov
the Telerik team

Q2’11 SP1 of RadControls for WinForms is available for download (see what's new); also available is the Q3'11 Roadmap for Telerik Windows Forms controls.

Tags
GridView
Asked by
Lasse
Top achievements
Rank 1
Answers by
Ivan Petrov
Telerik team
Share this question
or