title: Adding Images to FlipView from Code
body: <p>I am trying to add some images to a <code>FlipView</code> using the following code:</p>
  
  <pre><code>for (int N = 1; N &lt; 30; N++)
  {
      string name = String.Format(@"ms-appx:/Gallery/{0:00}.jpg", N);
      Uri uri = new Uri(name);
      BitmapImage img = new BitmapImage(uri);
      MainFlipView.Items.Add(img);
  }
  </code></pre>
  
  <p>but it only displays some texts. I defined the <code>FlipView</code> in my XAML:</p>
  
  <pre><code>    &lt;FlipView x:Name="MainFlipView"&gt;
      &lt;/FlipView&gt;
  </code></pre>
  
  <p>What should I do? </p>