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.

Custom In-Cell editor

Thread ID:

Created:

Updated:

Platform:

Replies:

27354 Apr 11,2005 09:09 AM Apr 11,2005 12:27 PM Windows Forms 1
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On April 11, 2005 09:09 AM

When the user double clicks to enter in-cell editing, I do not want to use the "textbox" control to perform the edit. I want to choose the control to use at the time of the action. Is there an example of how to hook this custom in-cell editor to the grid model? If not, can you give a little sample of how to do this? Steve

Administrator [Syncfusion]
Replied On April 11, 2005 12:27 PM

If it is a single cell in a GridControl where you want to use a special control, you can set the style.CellType = "Control" and set style.Control to be an instance of your special control. MyControl myControl1 = new MyControl(); //.... gridControl1.Controls.Add(myControl1); //... gridControl1[2,2].CellType = "Control"; gridControl1[2,2].Control = myControl1; But if you want to do control sharing across multiple cells, then you need to derive your own CellModel class and CellRenderer class. Take a look at either this sample, \Essential Suite\3.0.1.0\Windows\Grid.Windows\Samples\CellTypes\CalendarCells or the SliderCells sample in the same folder. They derive cell type classes.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

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.

;