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
1485
Control in DocumentControlHost not being instantiated-sometimes
posted

Hi,

I'm having a weird problem in the dock manager, using the latest version (2009.2).  I've been using it for over a year and never experienced this before:

I have a user control which contains a dock manager.  Its panes and the DocumentControlHost all contain user controls (all WPF controls - no WinForms stuff.)  *Sometimes* when I open the control, the DocumentControlHost is not displayed: No tab, no content.  Start the application again, and then it shows up.  It might work a few times in a row, then stop again(!)

Thinking the control in the DocumentControlHost could be the problem, I created a test user control with only a textbox in it, and experienced the same kind of behaviour.

The only difference between this one and the others (which do not seem to be exhibiting this behaviour so far) is that this control is instantiated in code-behind, on demand.  The others are instantiated at application startup.  This one here is not used on a regular basis, so I only instantiate it on demand to save memory.

The dock manager declaration in XAML is basically the same as with my other controls (the ones that work fine), save of course for the actual controls displayed within the panes.

I've been running in circles for a couple of days now and I'm running out of ideas of what to try.  The intermittent nature of the problem makes it even harder to debug (I thought I had resolved it a couple of times, only for it to reappear later...)

Suggestions?

Thanks,
MIchel

Parents Reply Children
No Data