• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 152
  • Last Modified:

Newbie Question!

Hi,

I am new to MFC and VC.

Just playing around with the Class Wizzard and resource editor.

What i want is to be able to responsd to a button press changing a piece of static text.

I have seup a member varible for DDX with the static text.

When the dialog is show the Static text is initially blank?

And when i set the member varible in reponse to a button been clicked there is no change.

Anyone know where i am going wrong??

Thanks

Rich

0
RichJackson
Asked:
RichJackson
1 Solution
 
aponcealbuerneCommented:
call UpdateData(FALSE);
hope helps...
0
 
GlennDeanCommented:
UpdateData(FALSE) is right.  
Your handler for the button should look something like

void CMyDlg::OnButton1()
{
  m_Text="Hi World";  //Added m_Text DDX variable for static text
  UpdateData(FALSE);
}
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now