Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Recent
    • Tags
    • Users
    • Login

    Adding New Menus

    Scheduled Pinned Locked Moved SDK Help
    2 Posts 0 Posters 219 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 27/09/2011 at 10:17, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   12 
      Platform:   Windows  ;   
      Language(s) :     C++  ;

      ---------
      Hi,

      I figured out how to create new menus. But the problem is I don't know how to refresh the menu bar to reflect the addition of my new menu.
      It shows up if I switch to another layout. But that's not good.

          BaseContainer *bc = GetMenuResource(String("M_EDITOR"));    //Gets the items under the M_EDITOR section   
       if (!bc) return TRUE;  
       GeData *last = SearchPluginMenuResource();      
       BaseContainer sc;  
       sc.InsData(MENURESOURCE_SUBTITLE,String("MyNewMenu"));       //Adds a new menu entry to the UI in memory only      
       if (last) bc->InsDataAfter(MENURESOURCE_STRING,sc,last);   //Adds the new menu to the UI
      

      How do I get the menu bar to update?

      -ScottA

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 27/09/2011 at 13:59, xxxxxxxx wrote:

        Doh!

        The answer was lying right under my nose in the docs: UpdateMenus();
        If it was a snake it would have bitten me.

        -ScottA

        1 Reply Last reply Reply Quote 0
        • First post
          Last post