title: C# bitmap uri source UI to freeze
body: <p>Here is the code I use and it freezes ui for like half second. What can I do to stop that short freeze? I tried Task.Run(() =&gt; {} ); but still can't get rid of the half second UI freeze.</p>
  <pre><code>BitmapImage bitmapImage = new BitmapImage();
  bitmapImage.BeginInit();
  bitmapImage.UriSource = new Uri(XDocument.SelectSingleNode(&quot;Launcher/News&quot;).Attributes[&quot;picture_url&quot;].Value, UriKind.Absolute);
  bitmapImage.EndInit();
  </code></pre>