Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

IExceptionFilter.OnException Method (ExceptionContext)

 

Called when an exception occurs.

Namespace:   System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)

void OnException(
	ExceptionContext filterContext
)

Parameters

filterContext
Type: System.Web.Mvc.ExceptionContext

The filter context.

System_CAPS_noteNote

In ASP.NET MVC versions 1 and 2, the OnException filters ran in forward order. In ASP.NET MVC version 3 and higher, the order is reversed. Exception filters in ASP.NET MVC have a similar behavior to exception handlers in the .NET Framework, which unwind from the inside out.

Return to top
Show:
© 2015 Microsoft