Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Queries from multiselect listbox

Status
Not open for further replies.

zahadhum

Programmer
Feb 3, 2004
2
GB
Hi,

I want to produce a query in Access 2000 based on a number of values selected in a listbox with multiselect (1)

I've tried all sorts of methods, even coding, but are unable to produce a result.
 
You need a For Each...Next structured loop.

Like below.

Dim var as variant

For Each var in YourListBoxName.ItemsSelected

'Run your query here.

Next var

Make sure the Multi Select property is set to Simple or Extended.

Hope this puts you on the right track.
 
Try this faq703-3936. If you have any questions, come on back.

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top