What are .sln and .vcproj files, and what do they contain?

前端 未结 5 1996
甜味超标
甜味超标 2021-01-30 17:18

I\'m new in the world of Visual Studio. Can somebody please explain what these two files contain? I know that one of them contains info about project, but what about the other o

5条回答
  •  情书的邮戳
    2021-01-30 17:34

    A project file .vcproj / .vcxproj contains settings on how to compile your code into a DLL or a binary file, or something else that the linker can assemble into one unit. A project file is just an xml file that contains compiler settings, linker settings, and describes which files you want to compile.

    A solution file *.slnis a text file that groups together multiple project files.

    So if you think of it like a tree, then you have got a good mental picture of it like this:

    .sln
       .vcproj
          .h
          .h
          .cpp
          .cpp
       .vcxproj
          .h
          .h
          .cpp
          .cpp
       .csproj
          .cs
    

提交回复
热议问题