title: Convert imageUrl to byte[] for caching
body: <p>I have an image that I capture from an ip camera and post it on a webpage to an image tag. Now I would like to convert to access the picture so that I can save it to our cache blob. Here is my code:</p>
  
  <p>asp tag:</p>
  
  <pre><code>&lt;asp:Image ID="imgPhoto" runat="server" ImageAlign="Middle" /&gt;
  </code></pre>
  
  <p>code behind image assignment:</p>
  
  <pre><code>imgPhoto.ImageUrl = "http://10.10.40.35/axis-cgi/jpg/image.cgi?resolution=640x480";
  </code></pre>
  
  <p>my attempt to convert the image to byte[]:</p>
  
  <pre><code>System.Drawing.Image _newImage = System.Drawing.Image.FromFile(imgPhoto.ImageUrl);
  MemoryStream ms = new MemoryStream();
  _newImage.Save(ms, System.Drawing.Imaging.ImageFormat.Jpeg);
  byte[] _fileBytes = new byte[ms.Length];
  </code></pre>