I have a combobox class which uses an array ROWSOURCE. The way my code currently works, the array is populated via a SQL SELECT statement. If no records are retrieved by the SQL, the array has 1 row, with all elements being .F. Conceptually, this is a zero-row array, and therefore a zero-option combobox.
Is there any way to make the combobox NOT drop down in this situation? I tried putting the following code in the DROPDOWN() event:
IF VARTYPE(MyArray[1]) = "F"
NODEFAULT
ENDIF
but to no avail.
If I can't suppress the drop down, I can instead populate that one row with dummy values -- but then I have to make all of my code handle the possibility that the user has selected the "dummy" row.
Am I missing the obvious solution here?