Hello,
I am developing a VisualBasic 6 application using CommandBars and DockingPane. I want to use CommandBars within the main application window as well as within each docking pane. Additionally, I want the end user to be able to use the 'Customize' feature to apply any pre-configured control to any instance of the CommandBars.
The problem I encountered is that I have to have a CommandBars control on each form where I want to use command bars (i.e. the main form and each form used in a docking pane). To enable the customization feature, I create the XCB file and loaded it for each form. At this point, everything works well.
The problem comes when the use tries to customize the CommandBars. Specifically, using custom accelerators. Since all CommandBars are loaded from the XCB file, each one starts with the same pre-defined accelerators. When the user changes an accelerator, it is only changed for that instance of the CommandBars control (i.e. changed in the docking pane but not the main window).
Ideally, it would be nice to create a single instance of the CommandBars control and allow CommandBars from it to be docked in the other panes. If that's not a feasible option, using some form of Global Properties would allow each instance of the CommandBars control to share certain information (i.e. Accelerators). At the very least, is there an event (or could you expose one) that indicates when the user has customized a CommandBar so that I can programatically update the other instances?
I appreciate your feedback.
|