Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How to load a menu into a project (ATL/MFC)

How to load a menu into a project (ATL/MFC)

Scheduled Pinned Locked Moved C / C++ / MFC
c++helptutorialquestion
3 Posts 2 Posters 0 Views 1 Watching
  • 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.
  • S Offline
    S Offline
    sanjeev_
    wrote on last edited by
    #1

    can anyone help me in how to load a menu to a button in a toolbar project either in ATL or MFC!!? and how to assign commands to those menu items!!?? ASAP please. regards:rose:

    D 1 Reply Last reply
    0
    • S sanjeev_

      can anyone help me in how to load a menu to a button in a toolbar project either in ATL or MFC!!? and how to assign commands to those menu items!!?? ASAP please. regards:rose:

      D Offline
      D Offline
      dlhson
      wrote on last edited by
      #2

      MFC does not support that. You must handle it: -Open YourProject.rc, find the following line IDR_MAINFRAME TOOLBAR.... BEGIN BUTTON ID_FILE_NEW... BUTTON ID_FILE_SAVE... _add this line_ SEPARATOR SEPARATOR END -In OnCreate(), use m_wndToolBar.SetButtonInfo(n,IDC_COMBO,TBBS_SEPARATOR, 100) -In CMainFrame, add a variable m_combo; -In OnCreate(), use m_combo.Create(...) Hung Son A Vietnamese student i-g.hypermart.net dlhson2001@yahoo.com

      S 1 Reply Last reply
      0
      • D dlhson

        MFC does not support that. You must handle it: -Open YourProject.rc, find the following line IDR_MAINFRAME TOOLBAR.... BEGIN BUTTON ID_FILE_NEW... BUTTON ID_FILE_SAVE... _add this line_ SEPARATOR SEPARATOR END -In OnCreate(), use m_wndToolBar.SetButtonInfo(n,IDC_COMBO,TBBS_SEPARATOR, 100) -In CMainFrame, add a variable m_combo; -In OnCreate(), use m_combo.Create(...) Hung Son A Vietnamese student i-g.hypermart.net dlhson2001@yahoo.com

        S Offline
        S Offline
        sanjeev_
        wrote on last edited by
        #3

        Thanks a LOT Mr.Hung Son. But I'm sorry on my part to not to be clear first. My toolar is not for a Dialog based.... Sorry! ... I'm making an IE ToolBar, which doesn't consist of these CMainFrame, and above said functions. But what i could do is ... Thanks! .... i will certainly give it a try, as I got some idea how to proceed. Thanks Once again for taking some time. Regards Sanjeev

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups