Freigeben über


VCCLCompilerTool.ExceptionHandling-Eigenschaft

Ruft einen Wert ab oder legt einen Wert fest, der für Aufrufe von Destruktoren für automatische Objekte während einer Stapelentladung, die von einer ausgelösten Ausnahme verursacht wurde, verwendet wird. ExceptionHandling macht die Funktionalität der Compileroption /EH (Ausnahmebehandlungsmodell) verfügbar.

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

Syntax

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

Eigenschaftswert

Typ: Microsoft.VisualStudio.VCProjectEngine.cppExceptionHandling
Ein cppExceptionHandling-Wert.

Beispiele

Siehe Gewusst wie: Kompilieren von Beispielcode für die Erweiterbarkeit von Projektmodellen zu Informationen darüber, wie dieses Beispiel kompiliert und ausgeführt wird.

Im folgenden Beispiel wird die Eigenschaft ExceptionHandling in der integrierten Entwicklungsumgebung (IDE):

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

Public Module Module1
    Sub Test()
        Dim prj As VCProject
        Dim cfgs, tools As IVCCollection
        Dim cfg As VCConfiguration
        Dim tool As VCCLCompilerTool
        prj = DTE.Solution.Projects.Item(1).Object
        cfgs = prj.Configurations
        cfg = cfgs.Item(1)
        tool = cfg.Tools("VCCLCompilerTool")
        tool.ExceptionHandling = True
    End Sub
End Module

.NET Framework-Sicherheit

Siehe auch

Referenz

VCCLCompilerTool Schnittstelle

Microsoft.VisualStudio.VCProjectEngine-Namespace