title: Defining UserControl Properties and binding them in windows phone
body: <p>In my windows phone application, I made a user control that has some text blocks and images. It's something like a control to show posts like Facebook. I want to use this user control in a long list selector, but whenever I try to bind data to it I get no data. Please help me.
  This is the MainPage.xaml</p>
  
  <pre><code>&lt;Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0"&gt;
          &lt;phone:LongListSelector Name="myLLS"&gt;
              &lt;phone:LongListSelector.ItemTemplate&gt;
                  &lt;DataTemplate&gt;
                      &lt;local:Posts TitleText={Binding TitleText}&gt;
  
                      &lt;/local:Posts&gt;
                  &lt;/DataTemplate&gt;
              &lt;/phone:LongListSelector.ItemTemplate&gt;
          &lt;/phone:LongListSelector&gt;
      &lt;/Grid&gt;
  </code></pre>
  
  <p>And this is the code behind</p>
  
  <pre><code> public class TestData
  {
      private string _TitleText;
  
      public string TitleText
      {
          get { return _TitleText; }
          set { _TitleText = value; }
      }
  
      public TestData(string Text)
      {
          This.TitleText = Text; 
      }
  }
  </code></pre>
  
  <p>And this is the UserControl xaml code</p>
  
  <pre><code>&lt;UserControl x:Class="BindingUserControlTest.TestBind"
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  mc:Ignorable="d"
  FontFamily="{StaticResource PhoneFontFamilyNormal}"
  FontSize="{StaticResource PhoneFontSizeNormal}"
  Foreground="{StaticResource PhoneForegroundBrush}" Height="125.889" Width="227.974"&gt;
  
  &lt;Grid x:Name="LayoutRoot" Background="{StaticResource PhoneChromeBrush}"&gt;
      &lt;TextBlock x:Name="lblTitle" HorizontalAlignment="Left" TextWrapping="Wrap" Text="TextBlock" VerticalAlignment="Top"/&gt;
      &lt;TextBlock x:Name="lblDescription" HorizontalAlignment="Left" TextWrapping="Wrap" Text="TextBlock" VerticalAlignment="Top" Margin="0,32,0,0" Width="218" Height="84"/&gt;
  
  &lt;/Grid&gt;
  </code></pre>
  
  <p></p>
  
  <p>And this is the code behind :</p>
  
  <pre><code>   private string _ShownTitle;
     public string ShownTitle { get { return _ShownTitle; } set { _ShownTitle = value; }}
  </code></pre>