Static Text

This is a discussion on Static Text within the Windows Programming forums, part of the Platform Specific Boards category; Hello I am using MSVC++. I am making An MFC App. I have a static text which currently says: "none". ...

  1. #1
    Unregistered
    Guest

    Static Text

    Hello

    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
    Posts
    346
    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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21