title: Log4Net in C# DLL can't load configuration
body: <p>I have a very basic Log4Net config file to use with my C# DLL. The logging works fine if I create an executable instead of DLL to test in standalone mode, and it has worked fine with exe's in the past as well. But when I switch to DLL mode (Class Library) to work with the other app, the DLL just won't log. Instead when it loads the config file (XmlConfigurator.Configure(file)) I see the error-
  "you have tried to set a null level to root"</p>
  
  <p><strong>Config File</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt;
  &lt;configuration&gt;
   &lt;configSections&gt;
  &lt;section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,Log4net"/&gt;
  &lt;/configSections&gt;
  &lt;log4net&gt;
  &lt;root&gt;
    &lt;level value="Full" /&gt;
    &lt;appender-ref ref="LogFileAppender" /&gt;
  &lt;/root&gt;
  &lt;appender name="LogFileAppender" type="log4net.Appender.RollingFileAppender" &gt;
    &lt;file value="log/eft.log" /&gt;
    &lt;appendToFile value="true" /&gt;
    &lt;rollingStyle value="Size" /&gt;
    &lt;maxSizeRollBackups value="3" /&gt;
    &lt;maximumFileSize value="2MB" /&gt;
    &lt;staticLogFileName value="true" /&gt;
    &lt;layout type="log4net.Layout.PatternLayout"&gt;
    &lt;conversionPattern value="[%d] %-5p (%logger{1}:%line) - %m%n" /&gt;
    &lt;/layout&gt;
  &lt;/appender&gt;
  &lt;/log4net&gt;
  &lt;/configuration&gt;
  </code></pre>
  
  <p>I have tried setting the log config through code as well, even that didn't work. I didn't get any error with that, but it still didn't log. I have all the permissions to create/write to files since I am logged in as admin.</p>
  
  <p>Using code instead of config file-</p>
  
  <pre><code>       Hierarchy hierarchy = (Hierarchy)LogManager.GetRepository();
         hierarchy.Root.RemoveAllAppenders(); 
         hierarchy.Root.Level = log4net.Core.Level.All;
         hierarchy.Configured = true;
  
         FileAppender fileAppender = new FileAppender();
         fileAppender.AppendToFile = true;
         fileAppender.LockingModel = new FileAppender.MinimalLock();
         fileAppender.File = "log.txt";
         PatternLayout pl = new PatternLayout();
         pl.ConversionPattern = "%d [%2%t] %-5p [%-10c]   %m%n%n";
         pl.ActivateOptions();
         fileAppender.Layout = pl;
         fileAppender.ActivateOptions();
         log4net.Config.BasicConfigurator.Configure(fileAppender);
  </code></pre>
  
  <p>What could be the issue?</p>