System.Reflection.ExceptionHandlingClause Class

Represents a clause in a structured exception-handling block.

See Also: ExceptionHandlingClause Members

Syntax

[System.Runtime.InteropServices.ComVisible(true)]
public class ExceptionHandlingClause

Remarks

The System.Reflection.ExceptionHandlingClause class provides information about the clauses in a try…catch…finally block (Try…Catch…Finally in Visual Basic). To get a list of exception-handling clauses in a method, obtain a System.Reflection.MethodInfo that represents the method. Use the MethodBase.GetMethodBody method to obtain a System.Reflection.MethodBody object, and then use the MethodBody.ExceptionHandlingClauses property to get the list of clauses.

Note:

Working with exception-handling clauses requires a thorough understanding of metadata and Microsoft intermediate language (MSIL) instruction formats. Information can be found in the Common Language Infrastructure (CLI) documentation, especially "Partition II: Metadata Definition and Semantics" and "Partition III: CIL Instruction Set". The documentation is available online; see tp://go.microsoft.com/fwlink/?LinkID=99212 on MSDN and tp://go.microsoft.com/fwlink/?LinkID=65552 on the Ecma International Web site.

Requirements

Namespace: System.Reflection
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 2.0.0.0, 4.0.0.0
Since: .NET 2.0