Partilhar via


Projects.Kind Property

Definition

Gets a GUID String indicating the kind or type of the object.

public:
 property System::String ^ Kind { System::String ^ get(); };
public:
 property Platform::String ^ Kind { Platform::String ^ get(); };
[System.Runtime.InteropServices.DispId(202)]
public string Kind { [System.Runtime.InteropServices.DispId(202)] get; }
[<System.Runtime.InteropServices.DispId(202)>]
[<get: System.Runtime.InteropServices.DispId(202)>]
member this.Kind : string
Public ReadOnly Property Kind As String

Property Value

A GUID string representing the type of object.

Attributes

Examples

public void CodeExample(DTE2 dte)  
{    
    try  
    {   // Open a project before running this sample  
        Projects prjs = dte.Solution.Projects;  
        string msg = "There are " + prjs.Count.ToString() + " projects in this collection.";  
        msg += "\nThe application containing this Projects collection: " + prjs.DTE.Name;  
        msg += "\nThe parent object of the Projects collection: " + prjs.Parent.Name;  
        msg += "\nThe GUID representing the Projects type: " + prjs.Kind;  
        if (prjs.Properties != null)  
        {  
            msg += "\nProperties:";  
            foreach (Property prop in prjs.Properties)  
            {  
                msg += "\n   " + prop.Name;  
            }  
        }  
        MessageBox.Show(msg, "Projects Collection");  
    }  
    catch(Exception ex)  
    {  
        MessageBox.Show(ex.Message);  
    }  
}  

Remarks

Environment extensions must provide uniquely defined type strings. This information should be available in each tool or language's type library or documentation.

Applies to