>>I have a textbox on a form, bound to a data field. I want to know, when the user exits the field, whether or not they changed the value of the textbox. I want to compare the new value to the previous value, NOT to the value of the field in the table, because the user may change the textbox several times while still in the screen.
>>
>>What's the best way to do this?
>>
>>Thanks!
>
>Hi Elyse,
>
>Look at the InteractiveChange event in the help file.
Hi George,
What about using GotFocus / LostFocus. Add a custom property to the textbox called OldVal. In GotFocus you could do
this.OldVal = this.value
. Then in LostFocus do:
if this.value == this.OldVal
else
endif
That way you're not testing on every keystroke.
hth
Roi
'MCP' Visual FoxPro
In Rome, there was a poem.
About a dog, who found two bone.
He lick the one, he lick the other.
He went pyscho, he drop dead!