Hi everyone,
I'm trying to figure out the simplest way to keep a log file of the activity in our (VB)ASP.NET application. We'd like to log when users login or run a report or any errors they get.
I understand you can log to the Event Log with something like this:
But we'd like to write to a text file on the server instead. I've looked into using the TextWriterTraceListener class, but i'm not sure that that's neccessary.
I've also noticed a couple of .NET logging libraries like NLog and Log4Net. Are these neccessary?
Are any of you keeping text files for logs and how are you doing it?
Thanks!
Melissa
I'm trying to figure out the simplest way to keep a log file of the activity in our (VB)ASP.NET application. We'd like to log when users login or run a report or any errors they get.
I understand you can log to the Event Log with something like this:
Code:
System.Diagnostics.EventLog.WriteEntry("Source", "Message")
But we'd like to write to a text file on the server instead. I've looked into using the TextWriterTraceListener class, but i'm not sure that that's neccessary.
I've also noticed a couple of .NET logging libraries like NLog and Log4Net. Are these neccessary?
Are any of you keeping text files for logs and how are you doing it?
Thanks!
Melissa