Hi
I bound a RadPanelBar to a object structure like this:
it seems now, that empty PanelBarItems does not expand out of the box. so if I click on the header of the item "MyObject1.2" it does not expand nor the currently expanded one does collapse. I already figured out that i can catch the event "Selected" of the RadPanelBar to expand the item by myself:
this works quite well, except that I am not able to collapse the last selected item. So my questions are:
- is there a better way to expand empty items?
- how can i collapse the items manually?
thanks
Simon
I bound a RadPanelBar to a object structure like this:
| - MyObject1.1 |
| - MyObject2.1 |
| - MyObject2.2 |
| - MyObject1.2 |
| - MyObject1.3 |
| - MyObject2.3 |
| - MyObject2.4 |
it seems now, that empty PanelBarItems does not expand out of the box. so if I click on the header of the item "MyObject1.2" it does not expand nor the currently expanded one does collapse. I already figured out that i can catch the event "Selected" of the RadPanelBar to expand the item by myself:
| private void RadPanelBar_Selected(object sender, RadRoutedEventArgs e) { |
| RadPanelBarItem selItem = e.OriginalSource as RadPanelBarItem; |
| if (selItem.Items.Count == 0) |
| selItem.IsExpanded = true; |
| } |
this works quite well, except that I am not able to collapse the last selected item. So my questions are:
- is there a better way to expand empty items?
- how can i collapse the items manually?
thanks
Simon