Re: Calling Configure serveral time

2007-02-08 Thread Sergey
Thank you all! That is what I was looking for. Sergey

Re: Calling Configure serveral time

2007-02-08 Thread Strele Franz
Hi, to avoid multiple configuration, you could use code like this: if(log4net.LogManager.GetRepository().Configured == false) { log4net.Config.XmlConfigurator.ConfigureAndWatch(new System.IO.FileInfo(...)); } Hth, Franz > -Ursprüngliche Nachricht- > Von: news [mailto:[EMAIL

Re: Calling Configure serveral time

2007-02-08 Thread Peter Drier
Sergey, I had a similar problem, or desire not to configure repeatedly.. Solved it with this "helper": - public sealed class log4netHelper { private static readonly log4net.ILog log = log4net.LogManager.GetLogger( System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); pu

Re: AdoNetAppender and reconnect

2007-02-08 Thread Martin Hassman
No I didn't know this. Thank you I have tried, but during my test when I put DB offline/online it didn't change the behaviour. Is this configuration correct? type="log4net.Appender.AdoNetAppender"> . Thank you Martin Hassman http://www.met.cz/ Ron Grabowski n

Re: Calling Configure serveral time

2007-02-08 Thread Sergey
Hi, Thanks for the answer. Are your plugin class created one time only? If there are several instances of your class created then XmlConfigurator.ConfigureAndWatch method is called several times. Does it work? I wonder if log4net reloads its configuration every time ConfigureAndWatch is called

RE: utilize logging functionality in my add-in

2007-02-08 Thread wang junwei
Thank you Dean for your suggestion. Now I have figured out how to get there. Here is these steps: 1.place your separate log4net configuration whatever location take C:\config\log4netcfg.xml for example. 2.my add-in is an assembly which recursively references other assemblies, Now I can programat

RE: Calling Configure serveral time

2007-02-08 Thread wang junwei
Hi, Sergey. I met the same problem as you do. I want to use log4net in my VS2005 add-in. It's a class library assembly and hosted in devenv.exe(VS2005 IDE). Now I have figured out how to get there after I post in this mailist and got help from Dean Fiala. Thank you very much Dean Fiala. Here is