SysUtilsReportErrorMessageToEventLog Method (String, String, Exception, EventLogEntryType) |
Reports the exception with a prefix message to the windows event log.
Namespace:
MFiles.VAF.Common
Assembly:
MFiles.VAF (in MFiles.VAF.dll) Version: 2.3.623.2
Syntaxpublic static void ReportErrorMessageToEventLog(
string eventSource,
string addedMessage,
Exception exception,
EventLogEntryType type = EventLogEntryType.Error
)
Public Shared Sub ReportErrorMessageToEventLog (
eventSource As String,
addedMessage As String,
exception As Exception,
Optional type As EventLogEntryType = EventLogEntryType.Error
)
public:
static void ReportErrorMessageToEventLog(
String^ eventSource,
String^ addedMessage,
Exception^ exception,
EventLogEntryType type = EventLogEntryType::Error
)
Parameters
- eventSource
- Type: SystemString
The event source string. Needs to exist in order to successfully write to the event log. - addedMessage
- Type: SystemString
The additional text that will prefix the error message. - exception
- Type: SystemException
The exception object from which the error message is generated. - type (Optional)
- Type: System.DiagnosticsEventLogEntryType
The event log entry type.
See Also