How to open c ++ project folder in visual studio?

I have a C ++ project with many folders and compilations for a large number of different executables, I want to open all this in visual studio and keep the folder structure of my project.

Right now, when you try to create a new VS project and import my project other than VS, it automatically puts all the header files in one folder and the source files in another, completely ignoring my folder structure. How to get a visual studio to preserve the folder structure when opening a C ++ project that is not created using visual studio?

+4
source share
2 answers

Suppose you can select a project, and then select Show All Files from the Solution Explorer toolbar. Then you can include and exclude files / folders from the project directory.

0
source

Right-click the folder in which you want it to be in Solution Explorer , select Add-> Existing Item ...

This overlooks a lot of the nice update / check performed when creating a new VS project from existing files, but is one way to structure a large number of files.

I would prefer to manage them in Solution Explorer , but I feel that it is so obvious that you either approve or have an excessively large number of files to search and sort them with the small Explorer solution .

0
source

Source: https://habr.com/ru/post/1386015/


All Articles