Re: Turn off logging for a specific event only

2006-09-26 Thread Ron Grabowski
Will this work? private int calculateBigNumber(bool loggingEnabled) { if (loggingEnabled && log.IsDebugEnabled) { log.Debug("Entering method"); } int result = 0; for (int i=0;i<100;i++) { result += i; } if (loggingEnabled && log.IsDebugEnabled) { log.Debug("Leaving meth

RE: Turn off logging for a specific event only

2006-09-26 Thread Pelton, Brian
One option would be to use a separate logger for that method. You could then control the logging for it. This would mean you would have to modify the source code to use a new logger. Is that possible? --Brian From: Ramaa Davanagere [mailto:[EMAIL PROTECTED]

Log user on thread

2006-09-26 Thread chrisb
How can I have the current user from System.Threading.Thread.CurrentPrincipal.Identity.Name automatically written to my log file? -- View this message in context: http://www.nabble.com/Log-user-on-thread-tf2341410.html#a6516582 Sent from the Log4net - Users mailing list archive at Nabble.com.

RE: Turn off logging for a specific event only

2006-09-26 Thread Ramaa Davanagere
Title: RE: Turn off logging for a specific event only   can somebody help me with this issue? Thanks. -Original Message- From: Ramaa Davanagere To: 'log4net-user@logging.apache.org' Sent: 9/26/06 2:28 PM Subject: Turn off logging for a specific event only   Is it possible to tu

Turn off logging for a specific event only

2006-09-26 Thread Ramaa Davanagere
  Is it possible to turn off the logging for a specific event? I would like to turn of the logging when the code hits a particular method and reset the logging to its original value which is "DEBUG" while exiting that method. Is it possible to accomplish this? If so, please provide me some

AdoNetAppender Multiple Columns

2006-09-26 Thread ebergemann
I am wanting to log the date, a message as well as the username to the database with log4net. However, it appears that the only value that I can explicitly indicate to log for log4net is the message. I do not want to have to place the username as well as other information all within the messa

RE: AdoNetAppender Multiple Columns

2006-09-26 Thread Dean Fiala
I believe you'll find the answer here. http://mail-archives.apache.org/mod_mbox/logging-log4net-user/200609.mbox/%3 [EMAIL PROTECTED] You'll want to use a Thread context property to store the user name. -Original Message- From: ebergemann [mailto:[EMAIL PROTECTED] Sent: Tuesday, Sep