非模式对话框[求助]
请问,我用MFC create方法建立了以非模式对话框,但是如何显示应用呢?因为对话框刚以形成就析构了,请问谁有使用经验。I have presented all details in a previous topic. Please search.
建议使用ObjectARX开发环境的MFC类系统来生成AutoCAD风格的对话框。
用MFC类库生成
void dialogCreate(){
// Modal
//CMySectionDlg dlg(CWnd::FromHandle(adsw_acadMainWnd()));
//int nReturnValue = dlg.DoModal();
// Modallless
CMySectionDlg *dlg = new CMySectionDlg(CWnd::FromHandle(adsw_acadMainWnd()));
dlg->Create(IDD_SECTION_DIALOG,CWnd::FromHandle(adsw_acadMainWnd()));
dlg->ShowWindow(SW_SHOW);
dlg->CenterWindow(NULL);
}
用MFC类库生成AutoCAD风格对话框后调用,调用代码如下:
void dialogCreate(){
// Modal
//CMySectionDlg dlg(CWnd::FromHandle(adsw_acadMainWnd()));
//int nReturnValue = dlg.DoModal();
// Modallless
CMySectionDlg *dlg = new CMySectionDlg(CWnd::FromHandle(adsw_acadMainWnd()));
dlg->Create(IDD_SECTION_DIALOG,CWnd::FromHandle(adsw_acadMainWnd()));
dlg->ShowWindow(SW_SHOW);
dlg->CenterWindow(NULL);
}
页:
[1]