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. Dialog box on Toolbar Control

Dialog box on Toolbar Control

Scheduled Pinned Locked Moved C / C++ / MFC
questionhelptutorial
1 Posts 1 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.
  • J Offline
    J Offline
    jw81
    wrote on last edited by
    #1

    I have set a dialog box on the toolbar. There is a Editbox with a Button on the dialog box. The Editbox supposed to get a value from the user and once the Button is pressed, the value will be transfered into a variable in CView. I added a CDialogBar variable m_pointDistro but since there is no class for the dialogbox, I dont know how to add this variable. Editbox ID is IDC_NPOINTS. I selected new class of the Dialogbox as CView but I was forbided to do that. So the Dialogbox ended up as no class. I chose the Button and added a function called OnDistro().

    void CProgramView::Distro() {

    CMainFrame* pMainFrame = (CMainFrame*)GetParentFrame();
    CEdit* pArray = (CEdit*)(pMainFrame->m_pointDistro.GetDlgItem(IDC_NPOINTS));
    .
    .
    }

    1. If I accidentally made the dialogbar has no class, how can i revert back? 2) The coding I used to get value from the dialogbox couldnt work. How can I fix it? Thanks,
    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