Thread: Simple controls--properties, methods, values...

  1. #1
    Registered User
    Join Date
    Apr 2004

    Simple controls--properties, methods, values...

    Ok, I'm starting to get the hang of putting together MFC dialog-based applications with VC++6.0. I can put the basic controls (edit boxes, buttons, etc.) into a dialog box, and I have a vague understanding of ClassWizard. What I'm having trouble with is making it all work together.

    What I'd like to do is create a program that has only a single-line edit control and a button. When the user presses the button, I want to have a message box (AfxMessageBox()) pop up, which contains the string that was entered into the edit control. Can anybody walk me through this process?

    Also, once I've got that, how do I change the value of the edit control? Like after the user pressed the button, how would I change the value of the text box to "blah?" I know from other OOP languages that the text box is an object, and it has various properties that can be changed--but I don't know how C++ deals with that. Your help is greatly appreciated!
    // Visual C++ 6.0... newbie with many questions!

  2. #2
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Google: MFC Tutorials


Popular pages Recent additions subscribe to a feed

Similar Threads

  1. c++ a very simple program
    By amjad in forum C++ Programming
    Replies: 1
    Last Post: 05-27-2009, 12:59 PM
  2. Replies: 1
    Last Post: 12-30-2007, 10:08 AM
  3. Binary Search Trees Part III
    By Prelude in forum A Brief History of
    Replies: 16
    Last Post: 10-02-2004, 03:00 PM
  4. Request for comments
    By Prelude in forum A Brief History of
    Replies: 15
    Last Post: 01-02-2004, 10:33 AM
  5. Adding Default values to controls in Dialog boxes
    By juhigarg in forum C++ Programming
    Replies: 3
    Last Post: 11-07-2001, 12:44 AM