ApplicationExtensionMethodsLogException Method |
Logs an error and writes it to the request log
Namespace:
NetQuarry
Assembly:
EAP.Core (in EAP.Core.dll) Version: 2.0.0.0 (4.6.8.0)
Syntax public static void LogException(
this IAppContext appCxt,
string source,
string errorName,
Exception ex,
bool writeToRequestLog = true
)
<ExtensionAttribute>
Public Shared Sub LogException (
appCxt As IAppContext,
source As String,
errorName As String,
ex As Exception,
Optional writeToRequestLog As Boolean = true
)
Parameters
- appCxt
- Type: NetQuarryIAppContext
The application context. - source
- Type: SystemString
The source code where the error was detected. - errorName
- Type: SystemString
The name of the error. - ex
- Type: SystemException
The exception. - writeToRequestLog (Optional)
- Type: SystemBoolean
Specifies whether or not the error should also be writted to the xot_request_log.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
IAppContext. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also