How do I configure log4net so that log.IsDebugEnabled is true?

后端 未结 6 451
伪装坚强ぢ
伪装坚强ぢ 2020-12-29 02:51

I am trying to use log4net in an ASP.NET application with Visual Studio 2005. I have declared an instance of the logger like so:

Private Shared ReadOnly log          


        
6条回答
  •  别那么骄傲
    2020-12-29 03:35

    If you are using a separate configuration file for log4net, do this: after following all the other setup instructions, make sure that u right click on the file in the visual studio solution explorer, select properties, expand the "Advanced" option group, set the "Copy To Output Directory" value as "Copy always". That will do the magic... :) cheers!!

提交回复
热议问题