Dotnet 4 - Writing to event log

  • Thread starter Thread starter stainless
  • Start date Start date
S

stainless

Hi,
I'm trying to write to the event log but I can't use net4log or nlog because they're open source and so aren't supported software. Has anyone written their own event logger? It only needs to be simple, I want to write a basic message to the application log.
 
Hi, I'm trying to write to the event log but I can't use net4log or
nlog because they're open source and so aren't supported software.
Has anyone written their own event logger? It only needs to be
simple, I want to write a basic message to the application log.

Many open source projects has better support than even very
expensive commercial closed source projects - and if you are
willing to pay for support, then there should be plenty of
consultants that could support a specific piece of open source.

But company policy may be as it is, so let us assume that is
a no go.

Writing to the event log is very simple.

Minimal example:

EventLog.WriteEntry("Application", "This is a test",
EventLogEntryType.Information);

See docs for more options.

Arne
 
I'm trying to write to the event log but I can't use net4log or nlog
because they're open source
and so aren't supported software. Has anyone written their own event
logger? It only needs
to be simple, I want to write a basic message to the application log.

A) Tell your corporate big-wigs that their prejudice is outdated.

B) Microsoft created a set of libraries called "Application Blocks," and
logging was one of them. Is Microsoft considered a trusted company in the
eyes of those corporate big-wigs?
 
Back
Top