急求!!!!!!!!!mfc中 修改button,radio button的可见性,还有radio button 的选择问题 vs2010

2025-04-24 10:03:59
推荐回答(1个)
回答1:

void CListDemoDlg::OnAddbutton()
{
CButton* bt1 = (CButton *)GetDlgItem(IDC_BUTTON1);

bt1->EnableWindow(!(bt1->IsWindowEnabled()));
//bt1->ShowWindow(!(bt1->IsWindowVisible()));

UpdateData(TRUE);
CString str;
str.Format("Radio is %d",m_radio1);
AfxMessageBox(str);
UpdateData(FALSE);
}
很简单吧,示例三个都实现了