edit编辑框相关
从Edit Control获取值,然后通过MessageBox输出出来
void CNowaMagic_MFCDlg::OnBnClickedOk() { // TODO: 在此添加控件通知处理程序代码 //CDialogEx::OnOK(); //获得EDIT CEdit* pBoxOne; pBoxOne = (CEdit*) GetDlgItem(IDC_EDIT1); //赋值 //pBoxOne-> SetWindowText( _T("FOO ") ); //取值 CString str; pBoxOne-> GetWindowText(str); MessageBox(str,_T("程序运行结果"),MB_OK); str.ReleaseBuffer(); }