SolutionConfiguration2.Name Özellik

Tanım

Nesnenin adını alır.

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

Özellik Değeri

String

Nesnenin adı.

Uygulamalar

Öznitelikler

Örnekler

Bu örnek, etkin çözüm yapılandırma öğesinin adını ilk öğe için görüntüler. Visual StudioBu örneği çalıştırmadan önce tümleşik geliştirme ortamında (IDE) bir proje açın.

Imports EnvDTE  
Imports EnvDTE80  
Sub SolutionConfigurationNameExample(ByVal dte As DTE2)  
    Try  
        Dim builder As SolutionBuild = _  
        _applicationObject.Solution.SolutionBuild  
        Dim config As SolutionConfiguration2  
        config = CType(builder.SolutionConfigurations.Item(1) _  
        , SolutionConfiguration2)  
        MsgBox("The name of the solution configuration is: "  _  
        & config.Name)  
    Catch ex As System.Exception  
        MsgBox(ex.ToString)  
    End Try  
End Sub  
using EnvDTE;  
using EnvDTE80;  
using System.Windows.Forms;  
public void OnConnection(object application,   
public void SolutionConfigurationNameExample(DTE2 dte)  
{  
    try  
    {  
        SolutionBuild builder =  
 _applicationObject.Solution.SolutionBuild;  
        SolutionConfiguration2 config;  
        config =  
 (SolutionConfiguration2)builder.SolutionConfigurations.Item(1);  
        MessageBox.Show("The name of the solution configuration is: "   
+ config.Name);  
    }  
    catch(SystemException ex)  
    {  
        MessageBox.Show(ex.ToString());  
    }  
}  

Şunlara uygulanır