Answer the question
In order to leave comments, you need to log in
How should header files work with cpp files in another directory?
1. IDE: Visual Studio 2019
2. Project: Dynamic Link Library (DLL)
3. Brief description of the issue: created a new folder in the source directory, created files there, created a filter in the project and included the files. In "new folder" the header file does not see the definition in the cpp file. "New folder" connected as well to the project through the "Additional directories include files". I read information on the Internet about connecting header files, why they are needed, but I did not find information about my question (perhaps I formulated it incorrectly). I hope that someone can help, or explain to me what I'm doing wrong (maybe just a link to some resource where you can read about it in detail will be enough)
Answer the question
In order to leave comments, you need to log in
Header files by themselves don't do anything at all.
They are simply pieces of code that the compiler inserts at the point where #include "thisfile" is specified in the code.
Thus, the problem as it is formulated does not make sense at all.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question