Thread: Static Text

  1. #1

    Static Text


    I am using MSVC++. I am making An MFC App. I have a static text which currently says: "none". I was wondering how would i make it say what is inside an edit box after i press ok.

    Thank You In Advance

  2. #2
    Registered User sean345's Avatar
    Join Date
    Mar 2002
    What you need to do is in the window procedure function wait until the button is pushed. You usually do this with the switch statement and the button is part of the WM_COMMAND. Then capture what is inside the Edit box with GetDlgItemText or a SendMessage and then place the text in the static text with SetDlgItemText or SendMessage.

    - Sean
    If cities were built like software is built, the first woodpecker to come along would level civilization.
    Black Frog Studios

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. bold static text
    By Bleech in forum Windows Programming
    Replies: 10
    Last Post: 08-22-2007, 05:43 PM
  2. Unknown Memory Leak in Init() Function
    By CodeHacker in forum Windows Programming
    Replies: 3
    Last Post: 07-09-2004, 09:54 AM
  3. How to specify "path ellipsis" for static text in the code
    By BrianK in forum Windows Programming
    Replies: 2
    Last Post: 06-18-2004, 07:59 PM
  4. Problem with static text in dialog boxes
    By Clyde in forum Windows Programming
    Replies: 11
    Last Post: 05-28-2002, 12:51 PM
  5. Static Text In MFC
    By Unregistered in forum Windows Programming
    Replies: 0
    Last Post: 05-25-2002, 02:41 PM