Aracılığıyla paylaş


Configuration.Type Özellik

Nesne türünü gösteren bir sabit alır.

Ad alanı:  EnvDTE
Derleme:  EnvDTE (EnvDTE.dll içinde)

Sözdizimi

'Bildirim
ReadOnly Property Type As vsConfigurationType
vsConfigurationType Type { get; }
property vsConfigurationType Type {
    vsConfigurationType get ();
}
abstract Type : vsConfigurationType with get
function get Type () : vsConfigurationType

Özellik Değeri

Tür: EnvDTE.vsConfigurationType
A vsConfigurationType sabiti, yapılandırma türü belirtme.

Notlar

Yapılandırmaları, Type yapılandırmaları koleksiyonu yapılandırmalarının belirli yapılandırma adı için bir satır veya sütun yapılandırmalarını belirli bir platform için etkin olup olmadığını gösteren bir sabit değer verir.Pencere ortam aracına sonra ait olup Type aracı tanımlar.Pencereyi bir paket tarafından sağlanan aracı veya belge penceresi ise, Type ya vsWindowTypeToolWindow veya vsWindowTypeDocumentve ObjectKind özelliği, özel paket türü gibi bilgileri gösterir.

Örnekler

public void CodeExample(DTE2 dte, AddIn addin)
{   // Make sure you have a solution loaded into Visual Studio
    // before running the following example.
    try
    {
        Project prj;
        Configuration config; 
        ConfigurationManager configmgr;
        if (dte.Solution.Projects.Count > 0)
        {
            prj = dte.Solution.Projects.Item(1);
            config = prj.ConfigurationManager.ActiveConfiguration;
            // Returning the Configuration type constant.
            MessageBox.Show(config.Type.ToString());
            // Returns the ConfigurationManager containing the active configuration.
            configmgr = config.Collection;
            // Returns the application containing this active configuration.
            MessageBox.Show(config.DTE.Name);
        }
    }
    catch(Exception ex)
    {
        MessageBox.Show(ex.Message);
    }
}

.NET Framework Güvenliği

Ayrıca bkz.

Başvuru

Configuration Arabirim

EnvDTE Ad Alanı

Diğer Kaynaklar

Nasıl yapılır: Otomasyon Nesne Modeli Kod Örnekleri Derleme ve Çalıştırma