Confused with the resource using
-
I am using VC++6.0 and trying to run a demo project about the dialog resources using from <>. I copyed its .cpp file, resource.h file into my project, and pasted its .rc file into my .rc file using notepad and add into the project also. But it didn't work,and pop out these errors: --------------------Configuration: mymenu - Win32 Debug-------------------- Compiling... mymenu.cpp E:\work\project\mymenu\mymenu.cpp(20) : error C2065: 'IDC_BLACK' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(22) : error C2065: 'IDC_RECT' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(195) : error C2065: 'IDM_APP_ABOUT' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(195) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(203) : warning C4060: switch statement contains no 'case' or 'default' labels E:\work\project\mymenu\mymenu.cpp(257) : error C2065: 'IDC_WHITE' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(259) : error C2065: 'IDC_ELLIPSE' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(263) : error C2065: 'IDC_PAINT' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(299) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(301) : error C2065: 'IDC_RED' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(301) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(303) : error C2065: 'IDC_GREEN' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(303) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(305) : error C2065: 'IDC_YELLOW' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(305) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(307) : error C2065: 'IDC_BLUE' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(307) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(309) : error C2065: 'IDC_MAGENTA' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(309) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(311) : error C2065: 'IDC_CYAN' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(311) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(313) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(325) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(327) : error C2051: case expression not constant Error executing c
-
I am using VC++6.0 and trying to run a demo project about the dialog resources using from <>. I copyed its .cpp file, resource.h file into my project, and pasted its .rc file into my .rc file using notepad and add into the project also. But it didn't work,and pop out these errors: --------------------Configuration: mymenu - Win32 Debug-------------------- Compiling... mymenu.cpp E:\work\project\mymenu\mymenu.cpp(20) : error C2065: 'IDC_BLACK' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(22) : error C2065: 'IDC_RECT' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(195) : error C2065: 'IDM_APP_ABOUT' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(195) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(203) : warning C4060: switch statement contains no 'case' or 'default' labels E:\work\project\mymenu\mymenu.cpp(257) : error C2065: 'IDC_WHITE' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(259) : error C2065: 'IDC_ELLIPSE' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(263) : error C2065: 'IDC_PAINT' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(299) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(301) : error C2065: 'IDC_RED' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(301) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(303) : error C2065: 'IDC_GREEN' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(303) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(305) : error C2065: 'IDC_YELLOW' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(305) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(307) : error C2065: 'IDC_BLUE' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(307) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(309) : error C2065: 'IDC_MAGENTA' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(309) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(311) : error C2065: 'IDC_CYAN' : undeclared identifier E:\work\project\mymenu\mymenu.cpp(311) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(313) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(325) : error C2051: case expression not constant E:\work\project\mymenu\mymenu.cpp(327) : error C2051: case expression not constant Error executing c
"undeclared identifier" it seems you need to include a header file to
mymenu.cpp
did you include this file?:)_**
**_
WhiteSky
-
"undeclared identifier" it seems you need to include a header file to
mymenu.cpp
did you include this file?:)_**
**_
WhiteSky
yes, as you can see in .cpp file, I had #include #include "resource.h"
-
yes, as you can see in .cpp file, I had #include #include "resource.h"
check the Ignore HTML tags in this message (good for code snippets) check box :(
TOXCCT >>> GEII power
[VisualCalc 3.0 updated ][Flags Beginner's Guide new! ]
-
yes, as you can see in .cpp file, I had #include #include "resource.h"
sure you include but i cant see header file in previous your thread i saw only
#include:)
anyway these erros are only a thing a include:)_**
**_
WhiteSky