List Box Values as Query parm for a Report (1 Viewer)

Opengrave

Registered User.
Local time
Today, 04:13
Joined
Sep 6, 2001
Messages
70
Searched the forums and couldn't find a similar question...

I have a form with two list boxes and a command button. List Box A contains a list of values pulled froma table. Double clicking something in List Box A copies the value to List Box B. The Command Button launches report whose record source is a query using the values in List Box B as criteria.

I want the query to return all records like ANY of the values in List Box B. Problem is I keep getting no records returned. I am basically looking for direction / info on how to use a list box with multiple items as a query criteria.

(Access 2000 Database attached - 146KB .ZIP file)
Right now I don't have the List Box A -> List Box B functionality completed yet so I just 'hard coded' the values into List Box B but the problem is the same. Any help is appreciated.
 

Attachments

  • smallreports.zip
    96.9 KB · Views: 456

David R

I know a few things...
Local time
Today, 04:13
Joined
Oct 23, 2001
Messages
2,633
Search the archives for 'varitem'

Your method is a little different from the usual (for example, you could just have a multi-select listbox and do away with the second one altogether), but there are numerous examples of how to build a query by stepping through a listbox.
 

Opengrave

Registered User.
Local time
Today, 04:13
Joined
Sep 6, 2001
Messages
70
Re: Search the archives for 'varitem'

David R said:
Search the archives for 'varitem'
That did it - Thanks!
 

Users who are viewing this thread

Top Bottom