Menu item loop
Tech-Archive recommends: Fix windows errors by optimizing your registry
I'm looking at a way to loop throught all menuitem object of a form,
including sub menu. From the form it self sub items doesn't matter
because i can access them directly without having to pass by parent
(i.e Open under File menu, i can call mnuOpen and don'y have to do
mnuFile.MnuOpen) ok you get the point.
I don't find any collection of these item. I have class that loop in
all form controls and check my Language XML file find the control and
check the text value for the current selected language. I manage to do
it for all controls and even special made controls. But i can't get
the menuitem to work. Form.Controls doesn't contain menuitem in there
so i guess there must be another way. I can make a special function
just for looping tru menuitem i have only 2-3 forms that need that
.
Relevant Pages
- Re: Menu item loop
... From the form it self sub items doesn't matter ... it for all controls and even special made controls. ... Form.Controls doesn't contain menuitem in there ... A ToolStripMenuItem is contained not by the Form instance, but instead by a MenuStrip that is itself contained by the Form. ... (microsoft.public.dotnet.languages.csharp) - Re: In C#, how do I code this = that?
... ClickableMenuItem instances to your menus, ... The VS 2005 Designer gets in a state where it will no longer display the custom control. ... Are your custom controls and the containing controls in the same project? ... (microsoft.public.dotnet.languages.csharp) - Re: Get all existing object of a form...
... I'm using exactly the same algorithm and I still don't see all the ... I noticed that I have this problem espacially with MenuItem ... The reason for this is that MenuItems aren't contained within the Controls ... (microsoft.public.dotnet.languages.csharp) - Re: Bind multiple control properties together
... > In a Windows Form, I have a MenuItem, TollbarButton, and a context ... > MenuItem that all represent the same user action. ... > there are about a dozen controls in the same situation. ... > way I can bind the .Enabled property of the second two controls to the ... (microsoft.public.dotnet.framework.windowsforms.controls) - Bind multiple control properties together
... MenuItem that all represent the same user action. ... Enabled property of all these at run-time. ... there are about a dozen controls in the same situation. ... (microsoft.public.dotnet.framework.windowsforms.controls) |
|