I presume you are referring to the example here:
Header files (C++)
https://learn.microsoft.com/en-us/cpp/cpp/header-files-cpp?view=vs-2019
It sounds like you didn't create the header file or add it to the project:
- Wayne
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I built the example program from the "Header files (C++)" guide, and when I compile the solution I get a number of errors because the class 'my_class' is not recognized by 'my_class.cpp' nor 'my_program.cpp' (codes C2065, C2653, etc).
I presume you are referring to the example here:
Header files (C++)
https://learn.microsoft.com/en-us/cpp/cpp/header-files-cpp?view=vs-2019
It sounds like you didn't create the header file or add it to the project:
My guess is you didn't copy the code from that page exactly. You have some kind of typo. Double check that your my_class.h has "namespace N" and "class my_class", spelled exactly like that.