What is the difference between using a Converter (IValueConverter) and passing in other values as parameters (ConverterParameter) vs using a MultiConverter (IMultiValueConverter) and just passing in multiple converter values?
What is the difference between using a Converter (IValueConverter) and passing in other values
Share
There are two main differences. One is that ConverterParameter is not a Binding and does not listen for property changes, so the Binding won’t refresh automatically if the value changes.
The other difference is that the ConverterParameter is an input to both Convert and ConvertBack, while all of the Bindings in a MultiBinding are inputs to Convert and outputs of ConvertBack. For example, if you are converting from DateTime to string, you might have the ConverterParameter be a format string, since that affects the conversion in both directions:
On the other hand, if you want to convert from two doubles to a Size, then you would want to return two doubles when converting back: