Thread: Edit boxes

  1. #1
    Registered User
    Join Date
    Nov 2002

    Edit boxes

    Hi, I am very new to windows programming, am using straight up win32 API, and have a quick question.

    I have a dialog box that contains an edit box with the id being ID_EDIT. So when someone enters something into the edit box, it sends a WM_COMMAND message to my dialog box's procedure function. What I don't know how to do is, after the program recognizes that the window that sent the command was my edit box, how do I place what the user entered into a string?
    case WM_COMMAND:
        switch (LOWORD(wParam)) // can't remember off the top of my head if its in the LOWORD or HIWORD or even if its the lParam :)
              case ID_EDIT:
                   // need to put what the user entered into a string here

  2. #2
    C++ Developer XSquared's Avatar
    Join Date
    Jun 2002
    Ontario, Canada
    GetWindowText( ).

    Look it up on MSDN.
    Naturally I didn't feel inspired enough to read all the links for you, since I already slaved away for long hours under a blistering sun pressing the search button after typing four whole words! - Quzah

    You. Fetch me my copy of the Wall Street Journal. You two, fight to the death - Stewie

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. WS_HSCROLL in ES_READONLY edit box error
    By Homunculus in forum Windows Programming
    Replies: 4
    Last Post: 02-13-2006, 08:46 AM
  2. Edit box(es), and specialized onmouseover
    By Lurker in forum Windows Programming
    Replies: 7
    Last Post: 05-25-2003, 04:13 PM
  3. Edit Boxes
    By ColdFire in forum Windows Programming
    Replies: 2
    Last Post: 02-13-2002, 02:54 PM
  4. please help visual c++ edit control boxes
    By alcoholic in forum C++ Programming
    Replies: 3
    Last Post: 02-05-2002, 02:39 PM
  5. Password Edit Boxes
    By Unregistered in forum Windows Programming
    Replies: 1
    Last Post: 08-27-2001, 02:40 PM