Hello,
I am running into an issue with the XamRibbon. We have a WPF Page which has a ribbon it. This page gets used many times, meaning, Unloaded and Loaded will be called on this page and ribbon after each use. (The page is getting put into and removed from a Frame). The issue occurs when we have quickaccess toolbars. If we set the IsEnabled state of the original button the quick access toolbar is pointing at, then we get the following exception during the second use of the ribbon.
An unhandled exception of type 'System.StackOverflowException' occurred in PresentationFramework.dll
The exception is thrown from this line:
btnRecordNext.IsEnabled = true;
Here is the QuickQccessToolbar definition:
<igRibbon:QuickAccessToolbar>
<igRibbon:QatPlaceholderTool TargetId="btnRecordPrevious" />
<igRibbon:QatPlaceholderTool TargetId="btnRecordNext"/>
</igRibbon:QuickAccessToolbar>
Here are the button defintions:
<igRibbon:ButtonTool x:Name="btnRecordPrevious" Caption="{x:Static SunGard_PS_Finance_Resources:MenuResources.RecordPrevious}" Id="btnRecordPrevious" Command="{SunGard_PS_WPF_Finance:FPSCommandBinder SunGard_PS_WPF_Finance:FPSRecordViewCommands.MovePrevious}" igRibbon:RibbonGroup.MaximumSize="ImageAndTextLarge" igRibbon:RibbonGroup.MinimumSize="ImageOnly" LargeImage="{DynamicResource L_ArrowLeft}" ToolTip="{x:Static SunGard_PS_Finance_Resources:TooltipResources.ButtonRecordPrevious}" />
<igRibbon:ButtonTool x:Name="btnRecordNext" Caption="{x:Static SunGard_PS_Finance_Resources:MenuResources .RecordNext}" Id="btnRecordNext" Command="{SunGard_PS_WPF_Finance:FPSCommandBinder SunGard_PS_WPF_Finance:FPSRecordViewCommands.MoveNext}" igRibbon:RibbonGroup.MaximumSize="ImageAndTextLarge" igRibbon:RibbonGroup.MinimumSize="ImageOnly" LargeImage="{DynamicResource L_ArrowRight}" ToolTip="{x:Static SunGard_PS_Finance_Resources:TooltipResources.ButtonRecordNext}" />
Nothing else is hooked up to the buttons. It also only seems to occure when you have more than one item in the quick access toolbar. In this case, we have two items. If i remove either one of them, it will not happen, but as soon as i add a second, then the use starts happening again.
Any help on the matter would be much appreciated.
Thanks in advanced.
-Mike
I struggled to find any 2008 Vol 2 Service updates, so I installed 2009 Vol 1 and tested with that instead. The issue definitely seems to be resolved in the 2009 Vol 1 update. Now to figure out why we are not using it... Thanks!
Thanks for the sample. I tried to reproduce it but was unable to. I tried it a number of times. I noticed that you are using the original release version of 8.2 (bld 1002) so there have been a number of fixes applied since then. Would it be possible to test with the latest hotfix version and see if you still get the issue?
I created a very simple test application that works similar to how our application works. Granted, the ribbon buttons are not hooked up but I am able to produce the stack overflow with it. The fastest way for me to reproduce it in this test app can be done in the following way:
Run the application.
Click Load.
Click the ribbon quick access toolbar Customize Quick Access Toolbar button.
Click UnLoad.
Now click on one of the items in the ListBox (Test 1 -4 ).
You should now have a Stack overflow exception.
Now in our application, U don't even need to click the Customize Quick Access Toolbar button. Simply using the ribbon to navigate, then unloading and reloading the page and then navigating again will cause it to do the stack overflow. I was able to get this similar behavior to happen in the test application but it did not happen very often. In our application it happens every time we re-load it.
Thanks,
Would it be possible to obtain a sample that demonstrates the problem?