I have a WPF window that contains a Telerik RadPaneGroup, and in it I have a RadPanes:
The ticketMapPane.IsHidden property is bound to the negation of stickyProperties.mapPaneVisible, so if mapPaneVisible is true, IsHidden is false, and the pane is displayed.
If mapPaneVisible is true on startup, ticketMapPane is visible, and ticketMap.ticketMapType is bound correctly to preferencesProperties.ticketMapType, and all is well with the world.
If I then manipulate the UI control that sets stickyProperties.mapPaneVisible to false the pane becomes invisible, if I set it to true the pane becomes visible again, and ticketMapType is bound correctly through it all.
But if stickyProperties.mapPaneVisible is false on startup, ticketMapPane is hidden, and ticketMapType doesn't seem to be bound.
I have a change handler on the ticketMapType property. It's called, when the ticketMapPane is visible on startup, and it is not, when it is not:
So what is happening is that if the pane is hidden on startup, when I make it visible the TicketMap.ticketMapType contains the default value, and not the value that it was supposed to be bound to. If the pane is visible on startup, everything binds correctly.
So, the question - how do I get this to work?
I can see two possibilities:
- I get the binding to connect even though the pane is invisible, or
- I get the binding to connect when the pane is made visible.
Any ideas as to how to do either?