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. Image for the cookie policy date
close icon

Collapsing Constraints on Losing Focus

Hello, there is a problem using the GridDataBoundGrid in Version 3.2.1.0 when it loses the Focus to a RichTextBox, as it seems, and when Constraints are being used to create Hierarchy Levels to be expanded by the User. When the grid-Focus is lost to a RichTextBox, the whole Grid gets collapsed, and the focus is not being lost. When you try it a second time and the grid is collapsed, it loses the focus. Any Suggestions? Greetings, ralf

5 Replies

AD Administrator Syncfusion Team September 7, 2005 08:03 AM UTC

How do I see the probblem in this sample? http://www.syncfusion.com/Support/user/uploads/GGC_9d8f822f.zip I tried it both with version 3.2.1.0 and 3.3, and clicking the richtextbox did not seem to collapse any gird nodes for me.


RG Ralf Gnass September 7, 2005 08:18 AM UTC

Hello, >How do I see the probblem in this sample? http://www.syncfusion.com/Support/user/uploads/GGC_9d8f822f.zip Use the GridDataBoundGrid. I replaced the GroupingControl with the GridDataBoundGrid in your example with the following Extension to the code: private void Form1_Load(object sender, System.EventArgs e) { DataTable parentTable = GetParentTable(); DataTable childTable = GetChildTable(); DataTable grandChildTable = GetGrandChildTable(); DataSet ds = new DataSet(); ds.Tables.AddRange(new DataTable[]{parentTable, childTable, grandChildTable}); //add the datatables in their nested order tableLevelList.Add(parentTable.TableName); tableLevelList.Add(childTable.TableName); tableLevelList.Add(grandChildTable.TableName); DataRelation parentToChild = new DataRelation("ParentToChild", parentTable.Columns["parentID"], childTable.Columns["ParentID"]); DataRelation childToGrandChild = new DataRelation("ChildToGrandChild", childTable.Columns["childID"], grandChildTable.Columns["ChildID"]); ds.Relations.AddRange(new DataRelation[]{parentToChild, childToGrandChild }); this.gridDataBoundGrid1.DataSource = parentTable; GridHierarchyLevel level1= gridDataBoundGrid1.Binder.AddRelation("ParentToChild"); GridHierarchyLevel level0= gridDataBoundGrid1.Binder.RootHierarchyLevel; if(level0!=null) { level0.RowStyle.Font.Size = level0.RowStyle.Font.Size+1; level0.RowStyle.BackColor = Color.WhiteSmoke; } if(level1!=null) level1.ShowHeaders = false; gridDataBoundGrid1.ExpandAll(); } Greetings, ralf


AD Administrator Syncfusion Team September 7, 2005 08:53 AM UTC

Sorry about the wrong grid. I put your form.Load into the sample. http://www.syncfusion.com/Support/user/uploads/GGC_653be602.zip Exactly what steps do I take to see the problem. The form comes up with the RichtextBox having focus. I can click back and forth between the RTB and the grid without any node collapsing in the grid.


RG Ralf Gnass September 7, 2005 09:13 AM UTC

Hello, >Exactly what steps do I take to see the problem. The form comes up with the RichtextBox having focus. I can click back and forth between the RTB and the grid without any node collapsing in the grid. Comment out the line this.gridDataBoundGrid1.UseListChangedEvent = true; in the Generator Code. Greetings, ralf


AD Administrator Syncfusion Team September 7, 2005 01:41 PM UTC

This has been corrected in version 3.3.

Loader.
Live Chat Icon For mobile
Up arrow icon