This documentation is archived and is not being maintained.

TraceContextRecord Constructor

Note: This constructor is new in the .NET Framework version 2.0.

Initializes a new instance of the TraceContextRecord class.

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

public TraceContextRecord (
	string category,
	string msg,
	bool isWarning,
	Exception errorInfo
public TraceContextRecord (
	String category, 
	String msg, 
	boolean isWarning, 
	Exception errorInfo
public function TraceContextRecord (
	category : String, 
	msg : String, 
	isWarning : boolean, 
	errorInfo : Exception



The trace category that receives the message.


The trace message.


true if the method associated with the TraceContextRecord is the Warn method; false if the tracing method is the Write method.


A Exception object that contains additional error information.

Every call to the System.Web.TraceContext.Write and System.Web.TraceContext.Warn methods generates a TraceContextRecord object that is added to the TraceContextEventArgs.TraceRecords messages collection. The Warn method call sets the IsWarning property to true, while the Write method calls set it to false.

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

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.

.NET Framework

Supported in: 2.0