Errors c2065: "idd_dialog1": Undeclared identifiers often occur during project compilation in VC. (⊙ O ⊙ )..., Clearly defined but not defined.
Sometimes there may be a lot
Error c2065: "idd_dialog1 ":
Error c2065: "idd_dialog2 ":
Error c2065: "idd_dialog3 ":
Error c2065: "idd_dialog4 ":
Error :.................................
Annoying. Clearly defined, all resources. H files can be found. What is the reason for this?
Some solutions on the Internet will not be mentioned here. In another case, the analysis is as follows:
Maybe you have defined a new class in the project: for example, cauthority is not derived from the MFC framework, it is a completely independent New Class (it has the header file: authority. H and implementation file: authority. CPP ).
Then the problem may occur. You may need to use the class associated with idd_dialog1 in this new class. Here it is called cmydilalog (it has the header file: mydialog. h and the implementation file: mydialog. cpp)
The header file of authority. cpp includes the following:
# Include "stdafx. H" # include "authority. H" # include "mydialog. H"
The error is as follows:
Error c2065: "idd_dialog1 ":
The error occurs because the header file of the project file is not included.
If the project name is: XXX
It should be changed to the following:
# Include "stdafx. H" # include "XXX. H" # include "authority. H" # include "mydialog. H"
Now the compilation is successful.
I don't know the specific reason. Which of the following experts can tell me ......