Appendix E. Solution and Project File Formats

You will usually edit your solutions’ and projects’ properties with the IDE. However, at times you may want to look inside these files or write a tool that processes the contents of solution and project files. Fortunately, most of the properties of a solution and its projects are kept in simple text files, enabling you to edit these files directly if you so desire. Make sure you close the solution before editing any of these files, to avoid VS.NET overwriting your changes the next time it saves the solution.

Warning

The structure of these files is not documented, and manual editing is not supported. We describe them here because it provides a useful insight into the inner workings of VS.NET projects and solutions. You will not normally need to edit these files and should exercise caution if you attempt to do so.

Solution Files

For every solution, VS.NET creates two files: <solutionname>.sln and <solutionname>.suo . The .sln file is a text file that contains all of the project and solution item information, as well as all of the properties that apply to all the projects in a solution.

The .suo file is a binary file that contains per-user information that has no effect on how projects are built. It keeps track of IDE settings such as the list of windows you currently have open, the locations of your breakpoints, and the project that will be launched when you start debugging the solution. Information in the .suo file is essentially dispensable, ...

Get Mastering Visual Studio .NET now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.