Freigeben über


VCConfiguration.ManagedExtensions-Eigenschaft

Ruft eine Konfiguration ab, die Visual C++ verwendet, oder legt diese fest. ManagedExtensions macht die Funktionalität der C++-Compileroption /clr (Common Language Runtime-Kompilierung) verfügbar.

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

Syntax

'Declaration
Property ManagedExtensions As compileAsManagedOptions
compileAsManagedOptions ManagedExtensions { get; set; }
property compileAsManagedOptions ManagedExtensions {
    compileAsManagedOptions get ();
    void set (compileAsManagedOptions value);
}
abstract ManagedExtensions : compileAsManagedOptions with get, set
function get ManagedExtensions () : compileAsManagedOptions 
function set ManagedExtensions (value : compileAsManagedOptions)

Eigenschaftswert

Typ: Microsoft.VisualStudio.VCProjectEngine.compileAsManagedOptions
Eine compileAsManagedOptions-Enumeration.

Hinweise

Wenn Sie diese Eigenschaft festlegen anstelle der Compiler CompileAsManaged-Eigenschaft Tools, dann andere, zugehörige Eigenschaften für den Linker und VCWebServiceProxyGeneratorTool für Sie auch festgelegt werden. Die Eigenschaft CompileAsManaged des Compilers festlegen, überschreibt direkt die ManagedExtensions-Eigenschaft auf der Konfiguration.

Beispiele

Informationen zum Kompilieren und Ausführen dieses Beispiels finden Sie unter Gewusst wie: Kompilieren von Beispielcode für die Erweiterbarkeit von Projektmodellen.

Im folgenden Beispiel wird die VCConfigurationManagedExtensions-Eigenschaft des Objekts in der integrierten Entwicklungsumgebung (IDE):

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

Public Module Module1
    Sub Test()
        Dim MyString As String
        Dim prj As VCProject
        Dim cfgs As IVCCollection
        Dim cfg As VCConfiguration
        Dim MyDbg As VCDebugSettings
        prj = DTE.Solution.Projects.Item(1).Object
        cfgs = prj.Configurations
        cfg = cfgs.Item(1)
        cfg.ManagedExtensions = True
    End Sub
End Module

.NET Framework-Sicherheit

Siehe auch

Referenz

VCConfiguration Schnittstelle

Microsoft.VisualStudio.VCProjectEngine-Namespace