CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Guest

    RE: Control to show Variable(s)


    GetDlgItem(IDC_MYSTATIC)->SetWidnowText("Test");
    Would '("Test")' be replaced with ("Value") ???? ..
    ex... Dialog based program.. click this button and it increasses value X
    by value Y... show the new varriable called Value...
    ??



  2. #2
    Join Date
    Apr 1999
    Posts
    3

    Re: RE: Control to show Variable(s)

    If I understand your question correctly, I think you are trying to display the value of a variable in a static text control. If so, you can do like this:

    int x;
    CString sVal;
    // manipulate the value of x
    sVal.Format("%d",x);

    GetDlgItem(IDC_MYSTATIC)->SetWidnowText(sVal);

    ...



  3. #3
    Guest

    Re: RE: Control to show Variable(s)

    Yes, that is what I am trying do.. thank you!


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured