.NET Framework Class Library
Controller.OnException Method
Called when an unhandled exception occurs in the action.
Assembly: System.Web.Mvc (in System.Web.Mvc.dll)
Syntax
Visual Basic
Protected Overridable Sub OnException ( _ filterContext As ExceptionContext _ )
C#
protected virtual void OnException( ExceptionContext filterContext )
Visual C++
protected: virtual void OnException( ExceptionContext^ filterContext )
Parameters
- filterContext
- Type: System.Web.Mvc.ExceptionContext
Information about the current request and action.
See Also