By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,325 Members | 1,886 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,325 IT Pros & Developers. It's quick & easy.

Search a choicelist

P: 48
Hello,

I've got a table containing customerspecific records (names, adresses, ID's, etc). I want to search this table using a form with a choicelist on it. This choicelist displays several columns (Name, adress, zipcode, customerno and several others).

Now comes the tricky part, what I want is:
- a textbox where a value is entered
- all the data in the columns must be searched simultaneously on every entry of a character
- the choicelist should only display the records that contain the same value as the search-textbox

For example:
I'm entering zipcode 42563 in the textbox, typing the 4 updates the records in the choicelist with all records containing a 4 in one of the fields. Entering the 2 (so the textbox contains 42) should again requery the choicelist so only the records with a field containing 42 will be displayed.

This would leave me the ultimate searchfunction.

Can anyone help me?
Sander
Aug 31 '07 #1
Share this Question
Share on Google+
3 Replies


Scott Price
Expert 100+
P: 1,384
Hello,

I've got a table containing customerspecific records (names, adresses, ID's, etc). I want to search this table using a form with a choicelist on it. This choicelist displays several columns (Name, adress, zipcode, customerno and several others).

Now comes the tricky part, what I want is:
- a textbox where a value is entered
- all the data in the columns must be searched simultaneously on every entry of a character
- the choicelist should only display the records that contain the same value as the search-textbox

For example:
I'm entering zipcode 42563 in the textbox, typing the 4 updates the records in the choicelist with all records containing a 4 in one of the fields. Entering the 2 (so the textbox contains 42) should again requery the choicelist so only the records with a field containing 42 will be displayed.

This would leave me the ultimate searchfunction.

Can anyone help me?
Sander

Have a look at these two sample databases created by Allen Browne. http://allenbrowne.com/ser-62.html and http://allenbrowne.com/AppFindAsUType.html.

I'm not sure about the first one, since I've not tried it out, but the second one searches on one field only.

To get your 'ultimate search function' will take some re-working of the code.

Regards,
Scott
Aug 31 '07 #2

Jim Doherty
Expert 100+
P: 897
Hello,

I've got a table containing customerspecific records (names, adresses, ID's, etc). I want to search this table using a form with a choicelist on it. This choicelist displays several columns (Name, adress, zipcode, customerno and several others).

Now comes the tricky part, what I want is:
- a textbox where a value is entered
- all the data in the columns must be searched simultaneously on every entry of a character
- the choicelist should only display the records that contain the same value as the search-textbox

For example:
I'm entering zipcode 42563 in the textbox, typing the 4 updates the records in the choicelist with all records containing a 4 in one of the fields. Entering the 2 (so the textbox contains 42) should again requery the choicelist so only the records with a field containing 42 will be displayed.

This would leave me the ultimate searchfunction.

Can anyone help me?
Sander
I created a one screen sample demo db a couple of days ago encapsulating a multi field in combination 'and', 'and','and' searching facility that builds SQL on the fly painting it to a textbox control on screen. The search use the asterisk wildcard. The screen has an 'output the current dataset' to excel facility on it that formats the excel spreadsheet headers, turns the excel auto filtration mechanism on and within the 'same' screen adds to the database if a record doesnt exist using existing search criteria fields for additional data input all controlled by whichever tab page you are on at any one time.

Its pretty much a functional thing for grabbing ideas. You're welcome to it if you want. I'm not always on the forum unfortunately.

Regards

Jim
Aug 31 '07 #3

P: 48
Thanks for the input guys! That Allen Browne has some bright ideas!

Jim, would you mind sending the database in a zip-file to my hotmail (piekedasse@hotmail.com)?

Thanks again!
Sander
Sep 11 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.