GetWindowText(str); ofsGetWindowText"/> GetWindowText(str); ofsGetWindowText"/>
VC++ MFC保存编辑框中的内容 弹出另存为对话框VC++ MFC保存编辑框中的内容 弹出另存为对话框 向文本文件写入内容应该不难,学C++时专门讲过。 #include ofstream ofs("test.txt"); 现在关键是如何获取指定编辑框中的内容。 全部代码如下: CString str; ofstream ofs("test.txt"); CStatic *pst=(CStatic*)GetDlgItem(IDC_EDIT1); //你的控件ID pst->GetWindowText(str); ofsGetWindowText...