_Solution.Properties Property

Gets a collection of all properties that pertain to the _Solution.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Properties Properties { get; }

Property Value

Type: EnvDTE.Properties
A Properties collection.

Some properties are exposed as automation properties on the _Solution or from objects you get to through the solution, such as SolutionBuild object for build dependencies.

public void PropertiesExample(DTE2 dte)
{
    // NOTE: This example requires a reference to the
    //       System.IO namespace.

    // Before running this example, open a solution.

    Properties props = dte.Solution.Properties;
    string msg = 
        Path.GetFileNameWithoutExtension(dte.Solution.FullName) + 
        " has the following properties:\n\n";

    foreach (Property prop in props)
    {
        msg += prop.Name + " = ";
        try
        {
            msg += prop.Value.ToString() + "\n";
        }
        catch
        {
            msg += "(Nothing)\n";
        }
    }

    MessageBox.Show(msg);
}

Community Additions

ADD
Show: