Hi all,
In my program I use some combobox's. If have a button "search" that executes a sql statement that gets data from an AS400 system database. The values I selected with the sql statement show up in the combobox's (so that works fine). But sometimes there's a wrong value in my database (it's one with 2000 records and 40 fields...).
Now I also have a save button. I want to check it the value that my combobox shows is in the collection of the combobox (where I have put all data that can be used). When I click the save button I execute an update sql statement with the value of the combobox in it. But this sometimes fails because there is a wrong data in the combobox.
My question is how to check if the combobox.value() is in the collection list for that combobox?
Any help is welcome.
Many thanks in advance.
FatEric
In my program I use some combobox's. If have a button "search" that executes a sql statement that gets data from an AS400 system database. The values I selected with the sql statement show up in the combobox's (so that works fine). But sometimes there's a wrong value in my database (it's one with 2000 records and 40 fields...).
Now I also have a save button. I want to check it the value that my combobox shows is in the collection of the combobox (where I have put all data that can be used). When I click the save button I execute an update sql statement with the value of the combobox in it. But this sometimes fails because there is a wrong data in the combobox.
My question is how to check if the combobox.value() is in the collection list for that combobox?
Any help is welcome.
Many thanks in advance.
FatEric