Question about the converter:When I look at the samples, the converter is defined as:
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
return value is GraphicsLayer ? Visibility.Visible : Visibility.Collapsed;
}
Is it possible to have more than one parameter? Can I do something like:
public object Convert(object value, Type targetType, object parameter1, object parameter2, System.Globalization.CultureInfo culture)
{
// do something using the parameters which would set a visibility variable
return visibility //return the value of my variable
}
and in my XAML, I would have something like:
<CheckBox Content="{Binding Label}"
IsChecked="{Binding IsEnabled, Mode=TwoWay}"
IsEnabled="{Binding IsInScaleRange}"
Visibility="{Binding Layer, Converter={StaticResource VisConverter}, ConverterParameter=Layer, ConverterParameter='a string here'} " >
</CheckBox>