How to change menubar wile application running RRS feed

  • Question

  • Hello,

    I've wm5 application .
    I want to change the manubar according to some variable.
    I use this code in  dialod initialization.
    The g_Counter is updated when I switch between dialogs.
    However the menubar got updated only once when I enter the dialog.
    What is the right way to switch between menubar while application running

    (g_Counter > 0)


         mbi.nToolBarId = IDM_DIAL_MENU;




        mbi.nToolBarId = IDM_NUM_MENU;

    Monday, February 15, 2010 8:55 AM


  • Your code is not quite complete. I think you should be able to change the menu on the fly using the menu functions: LoadMenu/RemoveMenu/AppendMenu.

    Please mark the post that helps you, and unmark that does not. This benefits our community.
    • Marked as answer by warrentang Friday, February 19, 2010 3:29 AM
    Wednesday, February 17, 2010 8:36 AM