public class MeasurementPoint : ModelBase
{
private double _value;
public double Value
{
get { return _value; }
set
{
_value = value;
NotifyPropertyChanged();
}
}
}
private void RefreshDataGridTolerance()
{
foreach (var measurementPoint in DataSet)
{
//TODO: Change this into a real way to raiseproperty changed without actually changing the value
var temp = measurementPoint.Value;
measurementPoint.Value = temp;
// something like this doesnt work?
// RaisePropertyChanged(nameof(measurementPoint.Value));
}
}
public class MeasurementPoint : ModelBase
{
//...
public void RefreshAllProperties()
{
foreach(var prop in this.GetType().GetProperties())
this.OnPropertyChanged(prop.Name);
}
}
var element = DataSet.First();
element.RefreshAllProperties();