I have a WPF 4 application that contains a TextBlock which has a one-way binding to an integer value (in this case, a temperature in degrees Celsius). The XAML looks like t
In xaml
In ViewModel, this way setting the value also works:
ViewModel
public string CelsiusTemp { get { return string.Format("{0}°C", _CelsiusTemp); } set { value = value.Replace("°C", ""); _CelsiusTemp = value; } }