Search code examples
c#visual-studio-2010c#-4.0solution

Getting the name of a solution from external source


Is it possible to get the Visual Studio solution name from a program like notepad (outside of Visual Studio)?

I'm developing an app that reads solution and project files for various pieces of information. Projects are not an issue at all. I can grab a solution file, determine all the projects and get all the information I want on the projects. My issue is with the SOLUTION name. I can see clearly in VS where the solution name can be an independant name that has nothing to do with any project. But when I open a solution file (*.sln) to find that "name" it's nowhere to be found.

I have read that is could be in the *.suo file but that file is encrypted/compressed or something.

Is it possible to get that actual solution "name" without involving VS? If needed I can use an API with code obviously. ;) - Thanks!


Solution

  • Looks like it simply is the filename... eg YourProject.sln.

    I observe when changing the filename the solution name changes in VS after restarting