After I put a field back in the list, it shows all its items


08-12-2009, 6:55 AM

Hey guys,

I attached some screenshots, which show what I mean:
1. I group the list with some headers. All lists are closed and only its main parameters are shown.

2. After I put one of the order-headers back to the list, all details are shown. But it should still just show the group-list headers.

I Hope you understand what I mean.

 

With best regards

Müller Matthias

Re: After I put a field back in the list, it shows all its items


08-13-2009, 2:55 AM
DrMueller,

SharpGrid does not offer an inherent way to keep track of all columns expand / collapse states. The way to approach this would be through the use of some custom code (which saves the expand collapse state before the adding/removing group, and applies it to the grid after).

The link below contains some information about Controlling Group Expansion/Collapse through Code.
http://www.datadynamics.com/forums/78644/ShowPost.aspx

In your particular case you can call CollapseAll method in AfterGroupChange event if operation is sgGroupRemove.

Thank you,
Andrey T.