1. The header file cannot be referenced in C++ Visual Studio

C++ Programming Questions - Table of Contents

1. The header file cannot be referenced in C++ Visual Studio

The problem is as shown in the figure below: The system prompts that the source file cannot be opened The
cannot open source file
project directory is as follows: The header file contains circle.h and point.h
Include circle.h and point.h in the header file
Solution: Right-click the project name, click "Properties" and
insert image description here
select "C/C++" drop-down in "Configuration Properties" List, then open the "General" tab, add the "Additional Include Directory"
insert image description here
path and select the folder where the header file to be imported is located, and click OK.
insert image description here
After the above operations are completed, the header file can be imported normally.
insert image description here

Guess you like

Origin blog.csdn.net/Sebastian_M/article/details/121333363