title: FlipView SelectionChange C#
body: <p>I am making a simple metro app to display an image and some content relevant to the image.</p>
  
  <p>Ex :
  image : data
  img1 : "Image of a butterfly"
  img2 : "Hello sky"
  img3 : "Picture of a Golden Retriever"</p>
  
  <p>I have loaded images into a flipview.And relevent data into an array.</p>
  
  <pre><code>&lt;FlipView HorizontalAlignment="Left" Margin="102,147,0,0" VerticalAlignment="Top" Width="627" Height="429" Name="fiImage" SelectionChanged="fiImage_SelectionChanged"&gt;
        &lt;Image Source="Assets/image1.png"  Name="Img1" /&gt;
        &lt;Image Source="Assets/image2.png"  Name="Img2" /&gt;
  &lt;/FlipView&gt;
  </code></pre>
  
  <p>I have a TextBlock in the xaml named as "tbN". What I want to do is when I change the image using pointer, relevant data should display in the textblock.</p>
  
  <p>I tried following code at selection change event</p>
  
  <pre><code>private void fiImage_SelectionChanged(object sender, SelectionChangedEventArgs e)
  {
      int i = ((FlipView)sender).SelectedIndex;
      tbN.Text = a[i];  //error line
  }
  </code></pre>
  
  <p>But when I execute the program, I get an error saying "NullReferenceException was unhandled by the user code: Object reference not set to an instance of an object."</p>
  
  <p>What am I missing?</p>