I have two combo boxes:
cboCategory
cboSearchEngines
I want to load a different list of search engines for each category, and I want each item in the list to have a hidden value for the app's use.
I think a DB can help.
Any ideas?
Printable View
I have two combo boxes:
cboCategory
cboSearchEngines
I want to load a different list of search engines for each category, and I want each item in the list to have a hidden value for the app's use.
I think a DB can help.
Any ideas?
This should be pretty straitforward:
Create a database (an Access DB should work nicely) with 2 tables. One having the categories you want. This table should have an autonumber ID.
The second table has all the search engines and a field with the CategoryID that it belongs to.
When you fill up the cboCategory combo set the ItemData property to the ID from the database.
Now when a user clicks on an item in the cboCategory combo just look up the ID from the ItemData and use it to make a SELECT statement in the SearchEnginge table to get a recordset containing all the search engines that belong to that category.
Now just loop through the recodset and fill the cboSearchEngines combo box.
Good luck!