title: WebClient Load JPG & GIF to Image
body: <p>In my XAML, I have:</p>
  
  <pre><code>&lt;Image Height="150" HorizontalAlignment="Left" Margin="0,4,0,0" Name="imgLogo" Stretch="Fill" VerticalAlignment="Top" Width="417" /&gt;
  &lt;Image Height="343" HorizontalAlignment="Left" Margin="0,155,0,0" Name="imgPhoto" Stretch="Fill" VerticalAlignment="Top" Width="417" /&gt;
  </code></pre>
  
  <p>In the C# code behind, I have:</p>
  
  <pre><code>WebClient wcForLogo = new WebClient();
  wcForLogo.DownloadStringCompleted += new DownloadStringCompletedEventHandler(wcForLogo_DownloadStringCompleted);
  wcForLogo.DownloadStringAsync(new Uri("http://mySite/logo.gif"));
  
  WebClient wcForPhoto = new WebClient();
  wcForPhoto.DownloadStringCompleted += new DownloadStringCompletedEventHandler(wcForPhoto_DownloadStringCompleted);
  wcForPhoto.DownloadStringAsync(new Uri("http://mySite/photo.jpg"));
  </code></pre>
  
  <p>But now I don't know how to catch the image and post it in the XAML controls I built.</p>
  
  <p>2 questions:</p>
  
  <ol>
  <li>Is there a way to copy the e.Result directly to the Image controls, or should I cache the image and use the cache as the source, or should I save the image to the isolated storage and then use that as the source, then delete the image when I'm done with it? Whichever case, could you please show me how with code?</li>
  <li>Are GIF's and JPG's dealt with differently? If so, can you show me the 2 different ways?</li>
  </ol>