Link to home
Start Free TrialLog in
Avatar of ADITYA RAO
ADITYA RAOFlag for India

asked on

CDialogEx undefined class

I  am  creating MDI project with CFormView.
On Views Form dialog I  placed a  button.
And  inserted one more dialog  in project  (IDD_DIALOG1)
Created One class(CDia) derived from CDialogEx which is using (IDD_DIALOG1) using "AddClass"
On Button click  I  written  following code
CDia  dia;
dia.DoModal();

And added appropriate header file "Dia.h"
On compiling  it gives error CDialogEx  undefined.
I  am using Visual Studio 2010 Professional
Please help me to solve thia issue
Avatar of jkr
jkr
Flag of Germany image

Can you post the relevant code?
Avatar of ADITYA RAO

ASKER

class CDia : public CDialogEx
{
	DECLARE_DYNAMIC(CDia)

public:
	CDia(CWnd* pParent = NULL);   // standard constructor
	virtual ~CDia();

// Dialog Data
	enum { IDD = IDD_DIALOG1 };

protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support

	DECLARE_MESSAGE_MAP()
};

void CMerilisaRView::OnBnClickedButton1()
{
	CDia cd;
	cd.DoModal();
	
} 

Open in new window


Error    1    error C2504: 'CDialogEx' : base class undefined  e:\aditya
practice\merilisar\merilisar\dia.h    7    1  MerilisaRHandlers
Error    2    error C2039: 'DoModal' : is not a member of 'CDia'
 e:\aditya practice\merilisar\merilisar\merilisarview.cpp    118  1  
 MerilisaRHandlers
ASKER CERTIFIED SOLUTION
Avatar of sarabande
sarabande
Flag of Luxembourg image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial