在文件一开始:
[assembly: log4net.Config.DOMConfigurator(ConfigFile="betAomen.exe.log4net.xml", Watch=true)]
指定配置文件为:betAomen.exe.log4net.xml类里:
private readonly int limit = Int32.Parse(ConfigurationSettings.AppSettings["15Seconds"]);中的:
ConfigurationSettings.AppSettings["15Seconds"] 从配置文件中读取值,这跟WEB。CONFIG文件类似!!
[assembly: log4net.Config.DOMConfigurator(ConfigFile="betAomen.exe.log4net.xml", Watch=true)]
指定配置文件为:betAomen.exe.log4net.xml类里:
private readonly int limit = Int32.Parse(ConfigurationSettings.AppSettings["15Seconds"]);中的:
ConfigurationSettings.AppSettings["15Seconds"] 从配置文件中读取值,这跟WEB。CONFIG文件类似!!
assembly表示对整个程序集作用,Watch=true表示监视配置的改动
读配置文件重标记为“15Seconds”的值吗?