title: can't read Keys from external appSettings file?
body: <p>Its a windows service and I can read <code>appkeys</code> from <code>app.config</code> but can't read from extnernal appSettings file which is on the same path. Below is my app.config:</p>
  
  <pre><code>  &lt;appSettings file="Scheduler.dev.AppSettings.config"&gt;
      &lt;add key="ErrorEmailTo" value="xxx@domain.com" /&gt;
    &lt;/appSettings&gt;
  </code></pre>
  
  <p>My external appSetting file is as below:</p>
  
  
  
  <pre><code>&lt;appSettings&gt;  
    &lt;add key="ErrorEmailFrom" value="test@xxxxxx.com" /&gt;
    &lt;add key="ErrorEmailhost" value="smtp.ddd.local" /&gt;
    &lt;add key="ErrorEmailPort" value="25" /&gt;
    &lt;add key="ErrorEmailEnableSsl" value="true" /&gt;
    &lt;add key="ErrorEmailUserName" value="test.user@xxxxxxxx.com" /&gt;
    &lt;add key="ErrorEmailPassword" value="password" /&gt; 
  &lt;/appSettings&gt;
  </code></pre>
  
  <p>Below is my code to read keys:</p>
  
  <pre><code> protected override void GetDetails()
   {
          try
          {
              var ErrorEmailTo = ConfigurationManager.AppSettings["ErrorEmailTo"];
              var ErrorEmailFrom = ConfigurationManager.AppSettings["ErrorEmailFrom"];
              var ErrorEmailhost = ConfigurationManager.AppSettings["ErrorEmailhost"];
              var ErrorEmailPort = ConfigurationManager.AppSettings["ErrorEmailPort"];
              var ErrorEmailEnableSsl = ConfigurationManager.AppSettings["ErrorEmailEnableSsl"];
              var ErrorEmailUserName = ConfigurationManager.AppSettings["ErrorEmailUserName"];
              var ErrorEmailPassword = ConfigurationManager.AppSettings["ErrorEmailPassword"];          
          }
          catch (Exception ex)
          {               
              throw ex;
          }
   }
  </code></pre>
  
  <p>I can code can read first key which is coming form <code>app.config</code> but others remain null. Even if I move my keys into <code>app.config</code>  I can read all keys using above code.</p>
  
  <p>What I have tried is:</p>
  
  <ul>
  <li>checked names, path </li>
  <li>deleted all temp/ bin files but no luck</li>
  </ul>
  
  <p>Please help.</p>