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

Me.gridDataBoundGrid1.ExpandAll() giving error?

Hi I am getting following error when i used the above statment "Relation is not parented to table to which this DataView points" I am using two tables,master & detail in a DataSet what i wants is to 1) set the grid properties when the form is loaded so not everytime i have to set properties 2) just refresh the grid pulling out records from database whenever a new record is added i have used the following code a) its not giving me any error at form load b) but when i again call this code when a new records is added and i am pulling again the records from database its giving me the above error any one can help me out Thanks Nouman

2 Replies

AD Administrator Syncfusion Team July 9, 2003 10:37 PM UTC

To reset an hierarchical grid, you need to do 2 things. Me.GridDataBoundGrid1.DataSource = Nothing Me.GridDataBoundGrid1.Binder.ResetHierarchyLevels() To use ResetHierarchyLevels, you must have version 1.6.1 as it was not in 1.5.2. The current eval download is 1.6.1. Here is a sample.


JF jfchim August 12, 2003 05:25 AM UTC

Nouman; I am facing the same problem. Have you manage to solve it. If yes, can you email me the solution? Thanks > Hi > I am getting following error when i used the above statment > "Relation is not parented to table to which this DataView points" > I am using two tables,master & detail in a DataSet what i wants is to > 1) set the grid properties when the form is loaded so not everytime i have to set properties > 2) just refresh the grid pulling out records from database whenever a new record is added > i have used the following code > a) its not giving me any error at form load > b) but when i again call this code when a new records is added and i am pulling again the records from database its giving me the above error > any one can help me out > Thanks > Nouman >

Loader.
Live Chat Icon For mobile
Up arrow icon