Click or drag to resize

LogEventInfoCreate Method (LogLevel, String, Exception, IFormatProvider, String, Object)

Creates the log event.

Namespace:  NLog
Assembly:  NLog (in NLog.dll) Version: 6.0.0+cfb73701cda54e2410b006f649f072e90daef707
Syntax
public static LogEventInfo Create(
	LogLevel logLevel,
	string? loggerName,
	Exception? exception,
	IFormatProvider? formatProvider,
	string message,
	Object?[]? parameters
)

Parameters

logLevel
Type: NLogLogLevel
The log level.
loggerName
Type: SystemString
Override default Logger name. Default Name is used when null
exception
Type: SystemException
The exception.
formatProvider
Type: SystemIFormatProvider
The format provider.
message
Type: SystemString
The message.
parameters
Type: SystemObject
The parameters.

Return Value

Type: LogEventInfo
Instance of LogEventInfo.
See Also