hi!
Is there a chance to find out which columns in a grid have been loaded with the DisplayLayout.Load(MemoryStream ms) method and which columns have not?
Imagine the following situation:
Version 1 of the program:
select a,b from table
Columns in the Grid: A, B
The user saves this DisplayLayout
-------
Version 2 of the program:
select a,b,c from table
The user loads the existing DisplayLayout from the database.
Now, only columns A and B should be displayed and C should be hidden.
By default, all three columns are displayed in the grid - i want to hide column C. How can i find out that only A and B have a stored DisplayLayout?
Thank you in advance!
Regards,
Andi
Maybe you could save the layout in xml format using DisplayLayout.SaveAsXml. Then you can parse the xml file. just a workaround. :-)
thank you for the suggestion - i thought about that, too.
but with xml i am worried about the size it takes and the performance of parsing the xml... the layouts are retrieved over a webservice, so i have to take care of network traffic a lot.
i thought that i might maybe be possible to perform a DisplayLayout.Load() and then access the loaded Columns through some kind of property or something....