Share via


VCProjectEngine.Platforms-Eigenschaft

Ruft die Auflistung von Plattformen im Projektmodul ab.

Namespace:  Microsoft.VisualStudio.VCProjectEngine
Assembly:  Microsoft.VisualStudio.VCProjectEngine (in Microsoft.VisualStudio.VCProjectEngine.dll)

Syntax

'Declaration
ReadOnly Property Platforms As Object
Object Platforms { get; }
property Object^ Platforms {
    Object^ get ();
}
abstract Platforms : Object with get
function get Platforms () : Object

Eigenschaftswert

Typ: System.Object
Die Auflistung von Plattformen im Projektmodul.

Beispiele

Weitere Informationen finden Sie unter Gewusst wie: Kompilieren von Beispielcode für die Erweiterbarkeit von Projektmodellen Informationen zum Ändern dieses Beispiel kompiliert und ausgeführt wird.

Im folgenden Beispiel wird der Name der aktuellen Projektkonfiguration von der Plattform ab oder legt diese fest.

' add reference to Microsoft.VisualStudio.VCProjectEngine
Imports EnvDTE
Imports Microsoft.VisualStudio.VCProjectEngine

Public Module Module1
    Sub Test()
        Dim prj As VCProject
        Dim cfgs, plats As IVCCollection
        Dim cfg As VCConfiguration
        Dim ProjEng As VCProjectEngine
        Dim plat As VCPlatform
        prj = DTE.Solution.Projects.Item(1).Object
        cfgs = prj.Configurations
        ProjEng = cfgs.VCProjectEngine
        plats = ProjEng.Platforms
        plat = plats.Item(1)
        MsgBox(plat.Name)
    End Sub
End Module

.NET Framework-Sicherheit

Siehe auch

Referenz

VCProjectEngine Schnittstelle

Microsoft.VisualStudio.VCProjectEngine-Namespace