Hello,
I have two questions/issues.
I have an UltraGrid loaded with my layout information. Initially when my datasource changes from nothing to something, everything works fine. But once the datasource is reset from something to nothing and back to some other datasource using the SetDatabinding the grid loses it's Layout information. I think this is a bug. Is there an indicator in the Grid which will help us know if its layout is default or something loaded from external file?
Is there a way to manually reinitialise the Grid?
-Saravanan
Hi Saravanan,
This is not a bug. When you change the data structure of the grid's data source, the grid throws away the layout in favor of the new layout for the new data source. If the data source is null, then all layout information is lost.
What you can do is save the layout before setting the data source to null and the load it after you set the data source again. There are save and load methods on the grid's DisplayLayout, so you can save the layout to a file or a stream.