Visual C++ Question:

Download Job Interview Questions and Answers PDF

How to change the Text of a CButton at Runtime?

Visual C++ Interview Question
Visual C++ Interview Question

Answer:

CButton *btnsample= (CButton *)GetDlgItem(IDC_BUTTON1); //suppose IDC_BUTTON1 is the ID of CButton
btnsample->SetWindowText(_T("Lahore"));

Download Visual C++ Interview Questions And Answers PDF

Previous QuestionNext Question
What is command routing in VC++?How to load an Icon on a CButton at Runtime?