|
Hi all,
please help me with this one.
I've got a custom entity class with 2 properties:
class SomeClass { public float TotalValue ...;
public MyCollectionBase valuesCollection ....; }
in my code SomeValue = sum (every valuesCollection). If I change any value of the collection item my TotalValue gets changed. This TotalValue is bound to a TextBox and valuesCollection is bound to a grid on the same form.
The problem is when the value of the collection item changes the TextBox does not get updated.
I already created an event PropertyChanged and it fires every time the value in the collection is changed. But what should I put into the handler? I tried:
tbValue.Refresh() - doesn't work
and
tbValue.DataBindings[0].BindingManagerBase.EndCurrentEdit() - same thing.
Please help! |