title: How to get the file relative path in c# service project?
body: <p>I have this code:</p>
  
  <pre><code>Stream stream = new StreamReader("~/quartz.xml").BaseStream;
  </code></pre>
  
  <p>Q1:What is the "~" symbol specify path in C#?</p>
  
  <p>Q2:How to get the "~" directory in C# service project? </p>
  
  <p>Q3:Does it mean the bin exe directory or project name directory?</p>
  
  <p>The <code>quartz.xml</code> file in my Windows service project located in two position:</p>
  
  <pre><code>D:\jsptpd\Code\jsptpdJobScheduler\jsptpdJobScheduler\bin\Debug
  
  D:\jsptpd\Code\jsptpdJobScheduler\jsptpdJobScheduler
  </code></pre>
  
  <p>Sure the path will change everytime!So get the relative path is better. </p>