>>I have a combo control whose rowsource is a table field. It exhibits the following rude behavior.
>>
>>Suppose I use the combolist (not the editbox) to choose value x. Fine.
>>
>>Then, prior to leaving the combo, I manually type value y (a legal value) and it is accepted. The ENTER that registers value y invokes a VALID which checks for hunkydoriness, refreshes the form and then returns .T. so that focus moves to the next control in the tab order.
>>
>>Fine.
wait a minute. Look what you are soing here. Running code in the control's valid event that refreshes the form. We know that a control write's its value to its controlsource somewhere between the valid and the lostfocus events. But more importantly, we know that a control gets it's value from the controlsource during the refresh event. So if you change a value in the combobox, and call THISFORM.Refresh in the combo's valid, you are tellin the combo to get it's value from the controlsource again. Combos can be strange to deal with sometimes, because the value property can be different from the DisplayValue property, which reflects what is actually displayed, but I bet that this is the root of your problem.
Erik Moore
Clientelligence