Alternative to IValueConvert, QuickConverter
https://quickconverter.codeplex.com/
Quick Setup Steps
- Add the assembly reference to your project. This can also easily be done using the NuGet package.
- Add the namespaces to Quick Converter that it will need to know about (before any xaml that uses it is loaded).
e.g. In your WPF application's App.xaml.cs file:
- Add the Quick Converter namespace to your xaml files so you can reference it.
Now you can
<Rectangle Width="100" Height="100" Fill="Red" Visibility="{qc:Binding '$P ? Visibility.Visible : Visibility.Collapsed', P={Binding IsShow}}">
댓글
댓글 쓰기