Hi,
I have a combobox populated with a view. In some situations, one item should not be selected. I have two options :
1) Disable this item in the combox list.
2) Check the value entered and give an error message.
In the first case I don't know how to do it.
In the second, I'm checking for the value entered in the valid event and returning .F. if it's the wrong choice. But when the valid returns .F. the value is changed anyway. Let me give an example : I have 3 kinds of clients, a person, a firm and a foreign client. In the first 2 types the country in the combobox is automatically changed to BR (Brasil) and in the latter, the user can select all the countries except Brasil. When the country is US and the user select BR, I return an error message and .F. from the valid event, but I want to change the value back to US. How to do it since OldVal() is BR ?
Regards,