I am trying to disable all my menus during a computation by code like this:
foreach(BarItem barItem in this.childFrameBarManager.Items)
barItem.Enabled = false;
When the computation is finished I enable all the menus similarly.
For the menus on my main MDI form this works fine. However, for the menus of the child MDI forms (which are merged with the menus from the main form) the ParentBarItems are not painted as disabled. This seems to be an update problem though, because if I try to click the menu, they will immediately be painted as disabled as they should. Similarly, after I enable all the menus again, the menus of the child form are not painted as enabled before I click them. Any ideas what is the problem here? Is there a way I can force the menus to repaint, so that the enabled/disabled state is shown properly? (I do call DoEvents, so this is not the problem.)
ADAdministrator Syncfusion Team July 14, 2005 10:47 AM
What version are you using? As far as I can tell, this is working correctly in our latest internal version.
ADAdministrator Syncfusion Team July 14, 2005 02:44 PM
I am using version 188.8.131.52
ADAdministrator Syncfusion Team July 14, 2005 03:26 PM
You might be able to force the bar control to refresh with the following code snippet. However, please be warned that I haven''t tried this as I wasn''t able to reproduce the problem.
foreach (Bar bar in this.mainFrameBarManager1.Bars)
You might just want to try waiting for our next release, which will include these fixes.
ADAdministrator Syncfusion Team July 15, 2005 01:50 AM
Your suggested code solved the problem. Thanks a lot, Gregory!