Go4Expert

Go4Expert (http://www.go4expert.com/)
-   MFC (http://www.go4expert.com/forums/mfc/)
-   -   Mfc Class Error (http://www.go4expert.com/forums/mfc-class-error-t7052/)

codeguardian 26Oct2007 11:35

Mfc Class Error
 
I am trying to use MFC classes to build a program. This is my fist time using the MFC classes and they dont seem to be working. I try to add CBitmap and get errors.

CBitmap bm;

and get errors:
error C2065: 'CBitmap' : undeclared identifier
error C2065: 'bm' : undeclared identifier

I am including "afxwin.h", but this dose not seem to help. What am i doing wrong? :confused:
I have tried on .NET and Visual C++ Express Edition.

shabbir 26Oct2007 17:51

Re: Mfc Class Error
 
Are all the path to the include path correct in the project.

codeguardian 27Oct2007 15:26

Re: Mfc Class Error
 
It seems that you can not use MFC in Generic C++ Classes. You must choose MFC project from the start, at least on Visual Studio .NET.

shabbir 27Oct2007 16:31

Re: Mfc Class Error
 
Quote:

Originally Posted by codeguardian
It seems that you can not use MFC in Generic C++ Classes. You must choose MFC project from the start, at least on Visual Studio .NET.

That way its easier or else you need to be providing all the path related information.


All times are GMT +5.5. The time now is 01:53.