Binding a Window Form with a (GridDataBoundGrid / GridGroupingControl) in Master-Details

Hi, Please, I have a windows form. On that form I have some TextBoxAdv controls bound to a Master Table. I would like to bind a (GridDataBoundGrid / GridGroupingControl) on the same form to Details Table. Best regards, Jamâl-Dine DISSOU

8 Replies

AD Administrator Syncfusion Team April 5, 2005 04:04 PM UTC

For a GroupingGrid, see this sample. \Syncfusion\Essential Suite\3.0.1.0\Windows\Grid.Windows\Samples\Grouping\MasterDetailForm For a GridDataBoundGrid, see this entry in the grid user guide. ms-help://MS.VSCC/Syncfusion.Essential_Suite/Syncfusion.EssentialSuiteUsersGuide/syncfusion.ug.grid/syncfusion.ug.grid/UsingAMasterdetailsRelation.html


PD Prof DISSOU Jamâl-Dine April 5, 2005 04:38 PM UTC

Thanks a loat. Additional question : How to make a GridGroupingControls Column to ResizeToFit all the Grid ? Jamâl-Dine DISSOU


AD Administrator Syncfusion Team April 5, 2005 05:44 PM UTC

You can try calling this.gridGroupingControl1.TableModel.ColWidths.ResizeToFit(GridRangeInfo.Table());.


PD Prof DISSOU Jamâl-Dine April 7, 2005 12:12 PM UTC

Hi Clay, It doesn''t work Jamâl-Dine DISSOU


AD Administrator Syncfusion Team April 7, 2005 12:55 PM UTC

On the initial Display, you can use this setting to force the grid to check all the values to size the column. this.gridGroupingControl1.TableDescriptor.AllowCalculateMaxColumnWidth = true; After that, say in a button handler, I saw the above code enlarge (but not shrink) columns if necessary to display the full text. Are you trying this is a nested table or something?


PD Prof DISSOU Jamâl-Dine April 7, 2005 05:04 PM UTC

OK How to make the ggc shrink ? Jamâl-Dine DISSOU


AD Administrator Syncfusion Team April 7, 2005 06:33 PM UTC

Right now, the only way I would know to do it is to first make the with small, and then call ResizeToFit. You set the width of a column using grid.TableDescriptor.Columns["SomeCol"].Width.


PD Prof DISSOU Jamâl-Dine April 8, 2005 04:29 PM UTC

Thanks a lot Jamâl-Dine DISSOU

Loader.
Up arrow icon