新建对话框IDD_DIALOG1,用ClassWizzard创建此对话框的类CDlg,基类为CDialog,在你要使用这个对话框的地方,假设你在CDIALOGDlg::OnButton1()调用它,就在DIALOGDlg.h里加入#include "Dlg.h", 然后在DIALOGDlg类里的public:处加入:CDlg dlg;现在你就可以在CDIALOGDlg::OnButton1()调用它了:
void CDIALOGDlg::OnButton1()
{
// TODO: Add your control notification handler code here
if(dlg1.DoModal()==ID_OK)
.......
}