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
175
LoadFromXML vs. InsertTool
posted

I have a form with a ribbon.  This form contains an mdi manager.  If I load another form with a ribbon and set the mdi parent of the 2nd form to be the first form the 2 ribbons merge.  This is what I expected.  I add a few tools from the second form to the QuickAccessToolbar and if I used the SaveAsXML method of the parent toolbars manager when I close my app and then use the LoadAsXML method when I re-open my app the tools that I added to the QuickAccessToolbar from my 2nd form are shown in the MergedTools collection.  This is true even before my second form has been created.  If I try to keep track of the tools that are in the QuickAccessToolbard (Index, Key, IsMergedToolKey) and I try to add them to the QuickAccessToolbar programmatically I get an error "System.ArgumentException: Cannot add the tool with key 'ButtonTool', since a tool with that key does not exist in the root tools collection.  Add the tool to the root tools collection first.  Is it possible for me to programmatically add tools to the QuickAccessToolbar when a child mdi form does not exist or is the only way to use the LoadFromXML

Parents
No Data
Reply Children
No Data