Hello all.I have a WPF application with a XamDockManager on it and a XamRibbon.The ContentPane headers of the XamDockManager are templated.The two options from the XamRibbon will add in the XamDockManager two user controls (in the code are View and View2), each on a separate ContentPane.Each of this UserControls contains a StackPanel. In the View userConteolr (method A), the IsEnabled property of the StackPanel it's bounded to the property IsBusy from the UserControl view model (the class ViewModel).In the View2 userConteolr (method B), the IsEnabled property of the Button in the StackPanel it's bounded to the property IsBusy from the UserControl view model (the class
ViewModel).On each StackPanel there is also a checkbox and the IsChecked property of this checkbox is bounded to the same IsBusy property of the view model from the user control.So that when the checkbox is true, the IsBusy property of the user control view model is true.When the IsBusy property is true, an animation in the ContentPane header template will start.For the method A the StackPanel will be disabled and for the method B only the button will be disabled.The problem is that when the IsBusy is true (method A), I am not able to switch between the ContentPanes.Can you please help me with this problem? If you need more details about it, please let me know and I will try to explain better.I also attached a sample.
Thanks.Nico
Thanks for the sample. What are the steps that I need to follow to reproduce the issue? I tried selecting Methods->Method A and then Methods->Method B, unchecking Enabled on method B, clicking on the header for method A, unchecking enabled so that both are disabled/animating. I then clicked on the tabs (Title1 & Title2) and was able to switch back and forth between the two while they were disabled.
I'm guessing that you're encountering an issue that was recently reported whereby if the last focused element within the contentpane was disabled that activating the pane (e.g. clicking on the tab item) was not activating the pane. This issue is fixed in the 9.2 and the fix will also be part of the next hotfix (8.1 and forward). One thing you could do in the interim is to clear the FocusManager.FocusedElement of the containing ContentPane (e.g. get the Parent of the UserControl/View which in your case should be the ContentPane and then call FocusManager.SetFocusedElement(cp, null)).
Hello Andrew.
Thanks very much for the answer.
Can you please try to uncheck the checkbox in the method A and than try to switch. This is the case when the problem with the switch appears.
Nico
I tried both orders - unchecking the checkbox in method A then activating method B then unchecking its checkbox and I could still activate back and forth and also by first unchecking the checkbox in method B then activatng method A and unchecking its checkbox and I could still activate back and forth. I'm reasonably sure this is the same issue that I mentioned was reported earlier and addressed in 9.2 and the upcoming hotfix.
I got the hotfix and it's working fine now.
Thanks very much for help.
I will try with the upcoming hotfix and let you know if I still have this problem.
Thanks very much.