WinJS.UI.Menu dynamic add commands problem RRS feed

  • Question

  • Hi I have a problem,

    When I add dynamiclly commands like this:

    var commands = [];           
    var command = new WinJS.UI.MenuCommand(null, { id: counter, label: "label" });
    var menuHeader = element.querySelector("#menuHeader").winControl;
    menuHeader.commands = commands;

    ofcourse the html control of the menu look like this:

    <div id="menuHeader" data-win-control="WinJS.UI.Menu" />

    On the first time I arrive to this page I get the menu works perfectlly but when  go to anthoer page and then coem back the items sudanlly disappear
    and not show as needed the command by the way follow the debug are there...

    Any Ideas?

    Sunday, June 17, 2012 12:53 PM

All replies

  • Hi Biecher,

    Can you share your project on SkyDrive or dropbox and give the repro steps?


    Jeff Sanders (MSFT)

    Tuesday, June 19, 2012 6:01 PM