I'm attempting to set up basic logging to the windows event log in .net via System.Diagnostics.EventLog, but I'm failing to see any events actually getting written to the log. Consider the following code:
// Elsewhere in the class
private static readonly string EventLogName = "LogName";
private static readonly string EventLogSource = "...
Imagine I have a web application with nice components coded up with your favorite Javascript library. I make heavy use of custom events to reduce the dependencies between these components so you can easily place them in multiple contexts, repeat them on the page, and/or nest them as I see fit.
This is a lovely picture, but debugging can...
Why is the following code not working?
if(EventLog.Exists("Foo"))
{
EventLog.Delete("Foo");
}
if(EventLog.Exists("Foo") == false)
{
EventLog.CreateEventSource("Foo", "Foo");
EventLog.GetEventLogs().First(x => x.Log == "Foo").ModifyOverflowPolicy(OverflowAction.OverwriteAsNeeded, 0);
EventLog.GetEventLogs().First(x ...
I am having a huge problem with the eventlog on my server. Right let me first of all explain the setup.
I have a domain setup with 2 computers
One computer is running IIS the other is a workstation. The IIS is running Win2k3 the workstation Win XP.
The IIS computer is hosting a website which uses Windows Impersonation and tries to log ...