How to get image files in c# using relative path?
<p>I've checked this thread <a href="http://stackoverflow.com/questions/3259583/how-to-get-files-in-a-relative-path-in-c-sharp">How to get files in a relative path in C#</a>, the directory is in IDE, which is not correct for me. I have a website application, needs to get image files from the same level folder <code>img</code>. I can use following code to get them:</p>

<pre><code>DirectoryInfo path=new DirectoryInfo(@"c:\WebsiteSolution\wwwroot\Chat\img");
FileInfo[] images = path.GetFiles("*");
</code></pre>

<p>But I want to use something like <code>.\img</code> to replace the parameter in the first line code, is that possible?</p>
