) Hi Guys, I am working now in a project that is placed into my docs\visual studio proj, that need to use . h files, placesd in c:\prog files\windows sdk and c:\prog files\OpenCv. Into these directories have another subdirectories with these .h that into them are included others .h files too. I was defined in the compiler into tool-->options the paths for these files but till now don't find some of them, or give me a message that a file is twice. PLS, Can sambody tell me what is the better way to distribute the files in a project like this, to solve this inconvenient ?

2) The second question is that I see in the main cpp file #include ----.h . Some of them appear in the solution explorer window, in her tree representation and some of them not, that mean that must look for them outside, it is rigth?
I tried to put some of them that aren't and give me a message that are twice, how to solve this issue?

Thanks Guys , wait for me and I will answer your dubts too.........Thanks again !

If you want to reference header files in all your projects then select Tools -->Options --> Projects And Solutions --> C++ Directories, then add the paths in the window on the right side of the screen. After that all you have to do is something like #include <dm/something.h> if the header is in the dm subdirectory. You have to know what folder the header file is in because the compiler won't search subdirectories for you.


I don't know about your second question because I never look at those files. When I want to see an include file I just right click on the #include <...h> line and select Open Document from the popup window.

This article has been dead for over six months. Start a new discussion instead.