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. to track changing the selection of combobox

to track changing the selection of combobox

Scheduled Pinned Locked Moved C / C++ / MFC
c++linuxtutorialquestion
4 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.
  • B Offline
    B Offline
    Bash
    wrote on last edited by
    #1

    Dear MFC Gurus! I'm writting SDI-based application that has DialogBar with combobox control. This DialogBar is initialized as the follows: int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) { ... if (!m_Bar.Create(this,IDD_BARDLG,CBRS_TOP,ID_MYBARDLG)) { AfxMessageBox(_T("Failed to create dialog bar!"),MB_ICONSTOP); return -1; }; }; where m_Bar is CDialogBar. IDD_BARDLG doesn't have its class derived from CDialog! How to capture ON_CBN_SELCHANGE message in CMainFrame class from combobox control belonging m_Bar? In other words, I need to track changing the selection of combobox. What should I do? Yours sincerely, Alex Bash

    RaviBeeR 1 Reply Last reply
    0
    • B Bash

      Dear MFC Gurus! I'm writting SDI-based application that has DialogBar with combobox control. This DialogBar is initialized as the follows: int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) { ... if (!m_Bar.Create(this,IDD_BARDLG,CBRS_TOP,ID_MYBARDLG)) { AfxMessageBox(_T("Failed to create dialog bar!"),MB_ICONSTOP); return -1; }; }; where m_Bar is CDialogBar. IDD_BARDLG doesn't have its class derived from CDialog! How to capture ON_CBN_SELCHANGE message in CMainFrame class from combobox control belonging m_Bar? In other words, I need to track changing the selection of combobox. What should I do? Yours sincerely, Alex Bash

      RaviBeeR Offline
      RaviBeeR Offline
      RaviBee
      wrote on last edited by
      #2

      Trap it in your dialog bar. Then, post a command (eg: CMD_CHECK_COMBO) to the mainframe that causes it (the mainframe) to check the selection of the combo. /ravi My new year's resolution: 2048 x 1536 Home | Articles | Freeware | Music ravib@ravib.com

      B 1 Reply Last reply
      0
      • RaviBeeR RaviBee

        Trap it in your dialog bar. Then, post a command (eg: CMD_CHECK_COMBO) to the mainframe that causes it (the mainframe) to check the selection of the combo. /ravi My new year's resolution: 2048 x 1536 Home | Articles | Freeware | Music ravib@ravib.com

        B Offline
        B Offline
        Bash
        wrote on last edited by
        #3

        What is "trap"? I'm not sure about terminology... Yours sincerely, Alex Bash

        RaviBeeR 1 Reply Last reply
        0
        • B Bash

          What is "trap"? I'm not sure about terminology... Yours sincerely, Alex Bash

          RaviBeeR Offline
          RaviBeeR Offline
          RaviBee
          wrote on last edited by
          #4

          What I meant was write a handler for the CBN_SELCHANGE notification. /ravi My new year's resolution: 2048 x 1536 Home | Articles | Freeware | Music ravib@ravib.com

          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