Hello list,
there is a need to pass a contextual parameter to nlog config file
just before logmanager initialisation.
in log4net i did through the following trick:
// code
log4net.ThreadContext.Properties["LogFilePath"] = @"\\server\share\log.txt";
XmlConfigurator.Configure(new System.IO.FileInfo("config.xml"));
// config.xml file
<appender name="RollingLogFileAppender" type="log4netTest.RollingFileAppender">
<encoding value="Unicode" />
<file type="log4net.Util.PatternString" value="%property{LogFilePath}" />
.........
.........
--
Sincerely,
Alexander N.
------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at:
http://p.sf.net/sfu/Challenge_______________________________________________
Nlog-list mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/nlog-list