M
Marina
Hi,
I have a text control bound to a column that is of type Decimal. I am doing
the validation myself to see if the user typed in something invalid, calling
CancelCurrentEdit and cancelling the validation event.
If the user typed in something that is not a number, such as 'abc', then
doing this works. The old value stored in the data source is popped into the
control.
However, if the user typed in something that is a legal number, but outside
the set of legal values as I have determined, and I try the exact same
thing, the data source retains the old value, but the control is not
refreshed to match the datasource. So if the user types in '11', but due to
business rules this is invalid, and I would like to cancel the edit, the
datasource retains it's previous value, but the input control on the screen
still says '11'.
What is going on here?
Any ideas on how to fix this? Other then manually changing the text of the
control, which I would like to avoid since it will mean reparsing the item,
and committing it as a change to the row - when in fact no change took
place.
I have a text control bound to a column that is of type Decimal. I am doing
the validation myself to see if the user typed in something invalid, calling
CancelCurrentEdit and cancelling the validation event.
If the user typed in something that is not a number, such as 'abc', then
doing this works. The old value stored in the data source is popped into the
control.
However, if the user typed in something that is a legal number, but outside
the set of legal values as I have determined, and I try the exact same
thing, the data source retains the old value, but the control is not
refreshed to match the datasource. So if the user types in '11', but due to
business rules this is invalid, and I would like to cancel the edit, the
datasource retains it's previous value, but the input control on the screen
still says '11'.
What is going on here?
Any ideas on how to fix this? Other then manually changing the text of the
control, which I would like to avoid since it will mean reparsing the item,
and committing it as a change to the row - when in fact no change took
place.