TraceContextRecord(String, String, Boolean, Exception) Constructor
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Initializes a new instance of the TraceContextRecord class.
public:
TraceContextRecord(System::String ^ category, System::String ^ msg, bool isWarning, Exception ^ errorInfo);
public TraceContextRecord(string category, string msg, bool isWarning, Exception errorInfo);
new System.Web.TraceContextRecord : string * string * bool * Exception -> System.Web.TraceContextRecord
Public Sub New (category As String, msg As String, isWarning As Boolean, errorInfo As Exception)
- category
- String
The trace category that receives the message.
- msg
- String
The trace message.
- isWarning
- Boolean
true
if the method associated with the TraceContextRecord is the Warn method; false
if the tracing method is the Write method.
Every call to the TraceContext.Write and 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
.
Product | Versies |
---|---|
.NET Framework | 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET-feedback
.NET is een open source project. Selecteer een koppeling om feedback te geven: