Microsoft Foundation Classes (mfc.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
CMenu::LoadMenuIndirect
CMenu                                       Up Contents Index Back
──Microsoft Foundation Classes──────────────────────────────────────────────
 
  BOOL LoadMenuIndirect( const BYTE FAR* lpMenuTemplate );
 
  Parameter        Description
 
  <lpMenuTemplate> Points to a menu template (which is a single
                   MENUITEMTEMPLATEHEADER structure and a collection of
                   one or more MENUITEMTEMPLATE structures).
 
  Remarks
 
  Loads a resource from a menu template in memory and attaches it to the
  CMenu object. A menu template is a header followed by a collection of
  one or more MENUITEMTEMPLATE structures, each of which may contain one
  or more menu items and pop-up menus.
 
  The version number should be 0.
 
  The <mtOption> flags should include MF_END for the last item in a pop-up
  list and for the last item in the main list. See AppendMenu for other
  flags. The <mtId> member must be omitted from the MENUITEMTEMPLATE
  structure when MF_POPUP is specified in <mtOption>.
 
  The space allocated for the MENUITEMTEMPLATE structure must be large
  enough for <mtString> to contain the name of the menu item as a
  null-terminated string.
 
  Return Value
 
  TRUE if the menu resource was loaded successfully; otherwise FALSE.
 
  See Also
 
  CMenu::DestroyMenu, CMenu::LoadMenu, ::LoadMenuIndirect,
  CMenu::AppendMenu
 
 
                                     -♦-