Gokula Krishna

Gokula Krishna

  • NA
  • 59
  • 6.6k

log4net in trace level

Nov 11 2018 1:48 AM
how to add a Trace level in log4net
 as i tried below code not working
public static class ILogExtentions { public static void Trace(this ILog log, string message, Exception exception) {         log.Logger.Log(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType,              log4net.Core.Level.Trace, message, exception); } public static void Trace(this ILog log, string message) {         log.Trace(message, null); } public static void Verbose(this ILog log, string message, Exception exception) {         log.Logger.Log(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType,              log4net.Core.Level.Verbose, message, exception); } public static void Verbose(this ILog log, string message) {         log.Verbose(message, null); }  }
 

Answers (1)