The Log4Net mailing list is a great source of information about using log4Net, in this forum we collect all the messages in the log4net user list and some selected threads from the developer list.
| Author |
Messages |
|
wijitha
 |
| 12/06/2008 2:28 PM |
|
Hi First, thanks for replying me.
now that is working. but now i wanna know, Should this piece of code be written in constructor of each class i write.
FileInfo log4NetConfigFile = new FileInfo("log4net.config");
if (log4NetConfigFile == null || !log4NetConfigFile.Exists) throw new Exception("unable to find log file");
log4net.Config.XmlConfigurator.ConfigureAndWatch(log4NetConfigFile);
thank you wijitha
|
|
|
|
|
jsinnott@sftcon.com
 |
| 12/13/2008 2:37 AM |
|
At the program or service entry point.
Without a hard path, you will want it in the bin/debug and bin/release folder for your dev environment. There is the chicken and egg issue of providing a path for it in the config file - do you want to record config problems, etc.?
|
|
|
|
|
|
| You are not authorized to post a reply. |
|
|
|
ActiveForums 3.7
|