We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Customizing menus

I have an MDI form with, among other things, a docking manager, a file menu and a few tool bars. These are added and built at run-time using the Essential Tools package. One of the things I have noticed when running the application, is that the placements of the tool bars are not always saved when exiting. If I only start the application, move the menus around, and then close it again, the placements are not saved. If I, however, push one of the buttons on the tool bars after moving them, the placements are saved. Any idea on why it is so? My second problem arises when I right-click one of the menus, open the BarCustomizationDialog, and then close it again. If I then try to open a new panel with the docking manager, the panel will not be shown. The only thing shown is the right edge of the panel. The only thing done is this: DockingManager.SetDockVisibility(Panel, DockVisible) It works just fine if I do not open the BarCustomizationDialog first. Am I doing something wrong here, or is this a bug? Regards, Atle Bjelland

6 Replies

AD Administrator Syncfusion Team October 2, 2002 11:19 AM UTC

Atel, Could you tell us how to reproduce this issue (toolbar state not getting saved) in our XPMenus sample? We are not able to. Or you could attach a small sample where this happens. I will get back to you shortly regarding this second issue... the one to do with the customization dialog. Regards, Praveen Ramesh Syncfusion, Inc.

AD Administrator Syncfusion Team October 2, 2002 01:04 PM UTC

Atel, Yes, I can see the problem regarding the Panel and customization dialog. Not quite the behavior you describe, but I see that things get broken when the customization dialog gets shown first. We are looking into this right now. We will fix this before our next patch goes out. Regards, Praveen Ramesh

AB Atle Bjelland October 3, 2002 04:22 AM UTC

I've tested quite a bit now in order to find out when the tool bar fails to save its state. What I discovered is that the state is saved if I quit the program using Alt+F4 or the X in the upper right corner. If I, however, use the exit button on the file menu, the state is not saved. The only thing the exit button does, is to call the Application.Exit() function. When I added Me.Close() before the Application.Exit(), the state was saved when pressing the Exit button as well. However, I've discovered that even when the state is saved, the tool bars are not always shown the way they should when restarting the program. This seems to happen when I have different sizes on the tool bars residing on one barmanager. It works this way: I use the barmanager imagelist for all the tool bars when in "small icon" mode. When in "large icon" mode, I use the largeimagelist for only some of the tool bars. The other ones continue using the small icons from the barmanager imagelist. I hope this is enaugh information for you to reproduce this issue. Regards, Atle Bjelland

AD Administrator Syncfusion Team October 4, 2002 11:12 AM UTC

Atle, Yes, you should call Form.Close rather than Application.Exit. The framework performs persistance in Form.Close event handler. Regarding the different toolbar sizes resulting in improper persistence, I am having trouble reproducing this issue. Could you please attach a sample here? Thanks Praveen Ramesh

AB Atle Bjelland October 7, 2002 06:00 AM UTC

Praveen, I've made this very quick and dirty example to show you how to reproduce the problem. Try moving the bar with "Text-Only" buttons under the other bar when in "Large icon" mode, close the app, and then restart. The bars are not where you placed them (at least not on my computer...) - Atle Bjelland

AD Administrator Syncfusion Team October 7, 2002 03:39 PM UTC

Atle, I can see the problem now. We will fix this issue in the next patch release. Thanks for the sample. Regards, Praveen Ramesh

Live Chat Icon For mobile
Up arrow icon