我要创建一个DLL,然后Insert一个Dialog,如何在*.CPP(创建的DLL源代码中)编写程序?调用这个对话框!比如说,在PRO/E中生成一个按钮点击它,它会调用这个生成的DLL,然后显示对话框,怎么编写?
谢了

解决方案 »

  1.   

    use MFC Createwinzard dll createind MFC extension dll,and call AFX_MANAGE_STATE(AfxGetStaticModuleState());
    this is my example:
    dll:
    BOOL __declspec(dllexport)__stdcall selectfullnight(LPCTSTR strMsg)
    {
    AFX_MANAGE_STATE(AfxGetStaticModuleState());
             CMyDlg dlg;
             dlg.Domodal();
    }
    exe:
    Load dll and call this function
      

  2.   

    我不想创建EXE文件,只创建一个DLL文件,然后利用PRO/E中的一个注册工具进行运行工作,怎么办?
      

  3.   

    i don't know PRO/E hwo to call your dll and  function,but i think  you should implement like this.