<PackageReference Include="System.Diagnostics.EventLog" Version="5.0.0-preview.1.20120.5" />

EventLogTraceListener

public sealed class EventLogTraceListener : TraceListener
Provides a simple listener that directs tracing or debugging output to an EventLog.
public EventLog EventLog { get; set; }

Gets or sets the event log to write to.

Initializes a new instance of the EventLogTraceListener class without a trace listener.

Initializes a new instance of the EventLogTraceListener class using the specified event log.

public EventLogTraceListener(string source)

Initializes a new instance of the EventLogTraceListener class using the specified source.