I am using the following code to create a custom event log in my windows service application:
public ServiceConstructor() {
Try the following:
EventLog.CreateEventSource("WinService", "Application"); and eventLog1.Log = "Application";
EventLog.CreateEventSource("WinService", "Application");
eventLog1.Log = "Application";
Also put the following in OnStart:
eventLog1.Log="Application" eventLog1.Source = "WinService";
eventLog1.Log="Application"
eventLog1.Source = "WinService";