I have a RadPanelBar that I create programmtically on initial load. I am able to tell it which RadPanelBarItem is expanded or not at this time, and this works as expected.
I have a requirement where I have a button and when I click on it, it will expand the last RadPanelBarItem and collapse the other RadPanelBarItems, if it is open. I can't get seem to get it to expand or collapse once it is opened.
Any help would be appreciated.
I am setting the IsExpanded Property of RadPanelBarItem and it does not chance after setting. I've tried the following:
foreach (RadPanelBarItem panelBarItem in PanelBar.Items) { panelBarItem.IsExpanded = false; } ((RadPanelBarItem )PanelBar.Items.Last()).IsExpanded = true; foreach (RadPanelBarItem panelBarItem in PanelBar.Items) { panelBarItem.SetValue(RadPanelBarItem.IsExpandedProperty, true) } ((RadPanelBarItem )PanelBar.Items.Last()).SetValue(RadPanelBarItem.IsExpandedProperty, true); |