What's going on with the RadPanes collection when clicking the Close (x) button from the pane header? RadPanes are being added through code. The RadPaneGroup.Items.Count property is incremented and decremented as panes are added and closed (x). However, the RadDocking.Panes.Count property only increments as new RadPanes are added programmatically and so I don't understand the relationship here. Shouldn't the RadDocking.Panes.Count property sum the total of all panes in the RadPaneGroups?
I've tried removing closed RadPanes in the RadDocking_Close event by clearing the RadDocking.ActivePane.Content, .Header, and .DataContext properties as previous forum posts suggest, but an "object not set to a reference" error is thrown when the RadDocking.ActivePane.RemoveFromParent method is called. Hence, I can't free up resources by clearing out closed panes when a pane is closed.
Further, the RadPaneGroup.Items.Count value is decremented by 1 for each RadPane that has its pinned stated changed to "unpinned," then incremented by 1 for each RadPane that becomes "pinned." This too is strange since the RadPane's are still in the group; just unpinned.
I've tried removing closed RadPanes in the RadDocking_Close event by clearing the RadDocking.ActivePane.Content, .Header, and .DataContext properties as previous forum posts suggest, but an "object not set to a reference" error is thrown when the RadDocking.ActivePane.RemoveFromParent method is called. Hence, I can't free up resources by clearing out closed panes when a pane is closed.
Further, the RadPaneGroup.Items.Count value is decremented by 1 for each RadPane that has its pinned stated changed to "unpinned," then incremented by 1 for each RadPane that becomes "pinned." This too is strange since the RadPane's are still in the group; just unpinned.