Problem in setting the include path - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Problem in setting the include path

karangkarang Posts: 2Member

I have opened a project

When I compile the project I am getting an error.

fatal error C1083: Cannot open include file: 'Test/Testnamespaces.h': No such file or directory

Now I have created a folder 'Test' and add a header file 'Testnamespaces.h'.

But still I am getting the same error.

Can anyone please help me in resolving this matter.



  • LundinLundin Posts: 3,711Member
    Whether #include paths use or / is poorly specified in the C standard, and this will vary on different compilers.
    Unix uses slashes for paths while Windows uses backslashes etc.

    This is why you should never write a path in the #include string, it will make your code non-portable. Instead, use the plain #include "myfile.h" syntax together with the project functionality of the IDE. Let the IDE find the files for you.
Sign In or Register to comment.