title: try to convert textbox value to int within convert method
body: <p>i trying binding textbox value to button IsEnable property but i get an exception.
  this is my convert class:</p>
  
  <pre><code>    public class BooleanToVisibilityConverter : IValueConverter
  {
  
      public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
      {
          string num = value as string;
          int n = int.Parse(num);
          if (n &gt; 10) return true;  
          return false;
      }
  
      public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
      {
          throw new NotImplementedException();
      }
  } 
  </code></pre>
  
  <p>this is my xaml code:</p>
  
  <pre><code>        &lt;Button Content="Button" Grid.Column="1" IsEnabled="{Binding ElementName=mytext,Path=Text,Converter={StaticResource convertIntToBool}}" HorizontalAlignment="Left" Margin="83,181,-156,-179" Grid.Row="1" VerticalAlignment="Top" Width="74"/&gt;
      &lt;TextBox Grid.Column="1" x:Name="mytext" HorizontalAlignment="Left" Height="23" Margin="263,163,-382,-163" Grid.Row="1" TextWrapping="Wrap" Text="TextBox" VerticalAlignment="Top" Width="120"/&gt;
  </code></pre>
  
  <p>i get FormatException: Input string was not in a correct format.</p>