[error]fatal error C1083: Cannot open include file: ‘~~’: No such file or directory

Error Detail

Cannot open include file: ‘<FILE_NAME>’: No such file or directory

Cause

Visual Studio can’t find the include file named FILE_NAME.

Checklist

File name

There is truly no file with such a name because of misspelling, mistake for file extension or missing in file path. Compare the name and path of the include file to your code.

Additional Include Directories

Visual Studio can’t read the directory where FILE_NAME is in. Check the include file. Open properties of the project and check “Additional Include Directories”.

Right click the project name on Solution explorer and open Properties.

Add the directory that contains the include file into C/C++ >Additional Include Directories”.

Configuration

If the target directory already exists in Additional Include Directories list, check Configuration and the build environment. If they are different, change the configuration and add the include folder to Additional Include Directories again.