Re: Programatically disable email

2008-01-10 Thread Ron Grabowski
; if (smtpAppender != null) { smtpAppender.Threshold = Level.Off; smtpAppender.ActivateOptions(); } } - Original Message From: Erlis Vidal <[EMAIL PROTECTED]> To: Log4NET User Sent: Monday, December 24, 2007 9:18:53 AM Subject: Programatically disable

Re: Programatically disable email

2007-12-27 Thread Karel Kral
I achieve this through direct manipulation with .log4net.config file. This sample for TraceAppender sets threshold for this appender to OFF and in effect disables this appender. public void SetAppenderThreshold(string appenderName, Level level) { XmlNode appenderNode = GetAppenderNode(appe

Programatically disable email

2007-12-24 Thread Erlis Vidal
Hi all! My current configuration use an smtpAppender with a LevelRangerFilter setted in order to send ERROR messages, but in some cases I would like to disable the email capabilities, in order to achieve something similar to the previous discussion of "Elapsed time evaluator" but in my case I w