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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

User controls inside nested grids

Thread ID:





131412 Jul 7,2017 09:41 PM UTC Jul 12,2017 06:09 PM UTC WinForms 3
Tags: GridGroupingControl
Steve Cox
Asked On July 7, 2017 09:41 PM UTC


Is it possible to host user controls inside the GridGroupingControl in any of the main or sub groups.  I know it is possible on the normal grid, but am finding it difficult to see how to achieve the same thing in this control.

I have several user controls to use for lookups, dates and some text input, so they will need to be hosted in different columns.

Can you please provide an example that shows how to do this.

Thanks, Steve

Piruthiviraj Malaimelraj [Syncfusion]
Replied On July 10, 2017 10:10 AM UTC

Hi Steve,  
Thanks for your interest in Syncfusion products.  
We could able to understand your scenario and prepared the simple sample as per your scenario. In order to set the user controls in a column of GridGroupingControl, CellType and Control properties of GridStyleInfo of that column can be used. Please make use of the below code and refer to the attached sample,  
Code example:  
this.gridGroupingControl1.TableDescriptor.Columns[2].Appearance.AnyRecordFieldCell.CellType = GridCellTypeName.Control;  
this.gridGroupingControl1.TableDescriptor.Columns[2].Appearance.AnyRecordFieldCell.Control = new CustomControl();  
this.gridGroupingControl1.TableDescriptor.Columns[1].Appearance.AnyRecordFieldCell.CellType = GridCellTypeName.Control;  
this.gridGroupingControl1.TableDescriptor.Columns[1].Appearance.AnyRecordFieldCell.Control = new CustomCalendar();  
Sample link:  

Steve Cox
Replied On July 10, 2017 08:30 PM UTC

Thanks for your reply however we need more information.  This is from my programmer.

Ok fine. This show me how to put a control in a cell.

But it is incomplete.

Assuming my control has a Value property (which obviously it has), where and how do I move the cell value into my control, and where and how do I move the edited value from my control back into the cell and the underlining data source?

The problem that I am having with this control is that the samples seem to assume you already know how to use the grid, which I don’t, and there are a zillion often strangely named properties and methods. How am I supposed to know where to look to make it do what I want.

That’s why I need a ‘complete’ example. The one they sent you doesn’t show how to make the checkbox control or the date control that they have used interact with the data in the grid. And searching on the web or looking at the samples that I have found doesn’t help either. Once I figured out how to use their databoundgrid I thought we had cracked it. But this gridgroupcontrol is not even vaguely the same.

Expand a top group. Click on one of the Description cells (not the new row one). Then click on the new row description cell. It uses the built in editor not our one. How am I supposed to work out how to fix that!?!

Are you able to assist with a more complete example that demonstrates how to get the values into the grid and then use the values from the user defined control, then explain why the user defined control is not used in the 'New' data row


Mohanraj Gunasekaran [Syncfusion]
Replied On July 12, 2017 06:09 PM UTC

Hi Steve,  
Sorry for the inconvenience caused. 
We have created a new incident regarding your query and we have updated the response through the incident. So, please follow up with that incident using your direct-trac login. 

Mohanraj G 


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon 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.Close Icon