title: ASP.NET Image control not displaying an image
body: <p>I am trying to display an image from "C:\temp". Here's the code:</p>
  
  <pre><code>string root = "C:\temp\";
  
  string[] files = Directory.GetFiles(root);
  
  foreach (string f in files)
  {
      if (Path.GetFileName(f).Contains(user.WorkEmail))
      {
          img1.ImageUrl = root + Path.GetFileName(f);
      }
  }
  </code></pre>
  
  <p>If an image is not found, I get a thumbnail with a red "X" - fine, as expected.</p>
  
  <p>If an image is found, I get a thumbnail but no image gets loaded/displayed. When I right click the thumbnail and go 'Properties' it shows the correct filename.</p>