Click or drag to resize
EventLogProviderLogException Method
Writes a new error to the event log.

Namespace: CMS.EventLog
Assembly: CMS.EventLog (in CMS.EventLog.dll) Version: 8.2.23
Syntax
C#
public static void LogException(
	string source,
	string eventCode,
	Exception ex,
	int siteId = 0,
	string additionalMessage = null,
	bool allowMultiple = true
)

Parameters

source
Type: SystemString
Source of the event (Content, Administration, etc.)
eventCode
Type: SystemString
Event code (UPDATEDOC, SENDEMAIL, DELETE, etc.)
ex
Type: SystemException
Exception to be logged
siteId (Optional)
Type: SystemInt32
Current site ID
additionalMessage (Optional)
Type: SystemString
Additional information to the exception message
allowMultiple (Optional)
Type: SystemBoolean
If true, it is allowed to log this exception multiple times within the application run
See Also