For more information, including specific details about the search order used to find a file, see #include Directive (C/C++) and #import Directive. The compiler follows a search path that is defined by the build environment, the /I compiler option, the /X compiler option, and the INCLUDE environment variable. If the name is enclosed by angle brackets, If the quotation marks contain a relative path, the compiler looks for the file in the directory relative to the source directory. If the quotation marks contain an absolute path, the compiler only looks for the file at that location. This tells the compiler to look for the file in the same directory that contains the source file first, and then look in other locations specified by the build environment. For example, when a header file name is enclosed by quotation marks, The compiler cannot find the file by using the search rules that are indicated by an #include or #import directive. #include The file is not included in the include search path For example, to include sys/types.h, you must include the sys subdirectory name in the #include directive: To fix this issue, verify that the correct file name is entered, as in this example:Ĭertain C Runtime Library headers are located in a subdirectory of the standard include directory. The header would not be found by this #include directive. Most C++ Standard Library header files do not have a. Here are some of the common reasons why the compiler generates this error. An incorrect include search path or missing or misnamed header files are the most common causes, but other file types and issues can also cause C1083.
There are many possible causes for this error. The compiler generates a C1083 error when it can’t find a file it requires. Cannot open filetype file: ' file': message