title: Use Connection string in app.config C#
body: <p>I am using Visual Studio 2005 C#. Designing a mobile App for handheld scanners. At the moment I'm declaring a connection string on every form I have. I do not want to do this. I know you can do it app.config file.</p>
  
  <p>I am struggling to understand how the app.config file works. I have read forums and stackoverflow posts, but I just can't find it. Can someone please help me with this?</p>
  
  <p>Example: <a href="https://stackoverflow.com/questions/3533310/app-config-file-in-c-sharp-for-sql-server-2005-in-vs-2008">app.config file in C# for SQL Server 2005 in VS 2008</a></p>
  
  <p>But where is the app.config file?</p>
  
  <p>Using:
  Visual Studio 2005
  .net 2.0 </p>
  
  <p>Screenshots:</p>
  
  <p><img src="https://i.stack.imgur.com/7Rkb1.png" alt="enter image description here"></p>
  
  <p><img src="https://i.stack.imgur.com/tA8er.png" alt="enter image description here"></p>
  
  <p>app.config file :</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt;
  &lt;configuration&gt;
    &lt;connectionStrings&gt;
      &lt;add name="MyString" 
           connectionString="User Id=christob;Password=CHRISTOB;Host=poseidon;Pooling=true;Min Pool Size=0;Max     Pool Size=100;Connection Lifetime=0;Port=1523;Sid=GLODCQA"
           providerName="CoreLab.Oracle" /&gt;
    &lt;/connectionStrings&gt;
  &lt;/configuration&gt;
  
  
  
  using System.Configuration;
  
  private void btnExit_Click_1(object sender, EventArgs e)
      {
          string sTemp = System.Configuration.ConfigurationManager.ConnectionStrings["MyString"].ConnectionString;
  etc........
      }
  </code></pre>
  
  <p>Error: </p>
  
  <p>Error   1   Deployment and/or registration failed with error: 0x8973190e. Error writing file '%csidl_program_files%\hhrcv_app\system.dll'. Error 0x80070070: There is not enough space on the disk.
      Device Connectivity Component   </p>
  
  <p>Why do I get this error? I only get it when I use systems.configuration; But i have to?</p>