How do you create a Dialog Box from a class with a CWnd base class?
Printable View
How do you create a Dialog Box from a class with a CWnd base class?
In VisualC++, a dialog box is derived from CDialog. You could create a modeless dialog box class, and create an instance of it in the CWnd
derived class. You would need to create a function such as GetParent() in the dialog box class, then in the CWnd, OnInitDilaog() function,
pass the address of the parent DialogBoxClass->GetParent(this); Then you can show, or not show the parent window.
Create the Dialog box, and make controll functions there. I have an example of this kind of code that works, I could EMail it to you if you
were interested. Let me know if this helps at all.
Joe Farkas
[email protected]
[email protected]