title: Is using a static class to facilitate access to appsettings acceptable?
body: <p>I have some keys in the app.config file of my application that house email settings. The application I am currently developing for work has several places where I need to send off an email (mostly in error checking to let us know something bad happened). To make it easier to grab that setting where I need it (instead of going back to the app.config to look up the text string to use in <code>ConfigurationManager.AppSettings["SomeKey"].ToString()</code> I created a simple static class to house a few readonly properties that return the values I need. Here's the basic structure</p>
  
  <pre><code>internal static Class myClass
  {
      internal static string setting1
      {
          get { return ConfigurationManager.AppSettings["SomeKey"].ToString(); }
      }
      internal static string setting2
      {
          get { return ConfigurationManager.AppSettings["SomeOtherKey"].ToString(); }
      }
  }
  </code></pre>
  
  <p>Is the way I am doing this acceptable? I can't find an issue with this but can't help thinking I'm missing something.</p>
  
  <p>Additional Info:</p>
  
  <p>I am aware of the method of simply using the Settings.Settings file.
  I can't use the Settings.Settings file due to the code policy in place where I work, which would make the way I'm doing this unnecessary.</p>
  
  <p>Edit: 
  By "acceptable" I mean is it commonly done or considered a good idea? I realize the community at large cannot speculate on acceptability at my job.</p>