Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
40
[c#] Ultragrid - Group rows into categories
posted

hi I would like to group rows in categories like this :

http://img199.imageshack.us/img199/9152/capturegww.jpg

I know to do this with OutlookGroupBy but it is not possible to put the same row into severals categories

So is there a way to group rows while beeing possible to put the same row into several categories at the same time ?

My ultragrid is bound to a dataset

  • 69832
    Offline posted

    UltraGridColumn exposes a GroupByEvaluator property, which is of type IGroupByEvaluator. This interface gives you the ability to control which group a row ends up in; it is possible that the DoesGroupContainRow method of the interface is called on each row for each group and there fore might be possible to return true for the same row for more than one group. However, I have to recommend not doing that as I would be very surprised if the grid handled this because you would then have the same instance of an UltraGridRow manifesting itself as two different RowUIElements, which is bound to cause confusion somewhere along the line.

    In short, I think the answer is, maybe you can get away with this but probably not and it might be very difficult to know whether it worked properly.