简体   繁体   中英

Include Directories Visual Studio 2010

When I attempt to #include "postgres.h" , I get this error IntelliSense: cannot open source file "postgres.h" .

I have attempted to add to the Include Directories by adding this to the end of the field: $(pathContainingHeaderFile) . The error remains when attempting to #include "postgres.h"

If I #include "pathContainingHeaderFile\\postgres.h" there are different errors because the files referenced by postgres.h cannot be found.

You should just append ; pathContainingHeaderFile ; pathContainingHeaderFile to the Include Directories ie omit the $( and ) parts. Remove giving the path in the #include line and it should work fine.

您可以尝试将头文件复制并粘贴到与放置可执行文件相同的映射中。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM