I created a Main menu that has Items I want in any new menus I create. So I created a separate Menu call mnuOrders. I Set the order screen to mnuOrders and now I don’t have access to anything in the ManiMenu.
How can I add Menus for a particular screen that actually get added to the MainMeni?
If you want to replace the main menu with your menu then you need to specify it in the Window’s properties pane (look to the bottom of the Inspector pane) or declare it when you create the window instance.
Dynamically adding menus to the existing MainMenuBar is another issue and is well documented in these forums (search for it) or in the documentation. Never having done it, I can’t help.
Dynamic menu’s are kind of a pain. What I do in a situation like that is come up with the entire menu for the window in question.
FWIW, most apps enable/disable the menus based on content and really don’t change the menu structure much. It makes the menu actions discoverable because a disabled menu command leads to the question, “what does this do and how do I enable it?” and is a cheap way for the user to discover things about the app.
But, your app might need the significantly different menus based on the Window. No judgements - just saying it’s not common.
Richard, the key here is in the first paragraph of Bob’s response. Concatenating menubars is not allowed.
What you will need to do is Right-click on the MainMenuBar and select Duplicate. This will give you MainMenuBar1 (rename it if you want). open it and add the Items to make your Menu1 + Menu2 and assign that as the menubar for screen 2. Do the same for however many screens you need different menus for.
Now, by “screens” do you mean windows? If so, then you can set the menubar to use in the Inspector pane of the IDE. If you mean pages of a pagepanel or tabpanel, then you will need to set the window’s menubar to the one you want displayed when the panel comes visible.