Export (0) Print
Expand All

HttpApplication.LogRequest Event

Occurs just before ASP.NET performs any logging for the current request.

Namespace: System.Web
Assembly: System.Web (in system.web.dll)

public event EventHandler LogRequest
/** @event */
public void add_LogRequest (EventHandler value)

/** @event */
public void remove_LogRequest (EventHandler value)

In JScript, you can handle the events defined by a class, but you cannot define your own.
Not applicable.

The LogRequest event is raised even if an error occurs. You can provide an event handler for the LogRequest event to provide custom logging for the request.

For more information about how to handle events, see Consuming Events.

LogRequest is introduced in the .NET Framework version 3.5. For more information, see The .NET Framework 3.5 Architecture.

The following example demonstrates how to provide an event handler for the LogRequest event. The event handler also handles several other events. Therefore, the CurrentNotification and IsPostNotification properties are used to determine what code to run.

Windows 98, Windows Server 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0

Community Additions

ADD
Show:
© 2014 Microsoft