Unanswered: Selecting more than one or all options from a droplist
I have a list box who's source is a range of values of patient sizes from a table: Adult (Medium), Adult (Large), Adult (Small), Paediatric (Large) etc.
I would like to add an option for "ALL" or a means of using 'Ctrl' to allow the user to select more than one. Currently the values from the table are linked to criteria within queries from a form. When the user makes a selection on the form, that selection specifies the criteria within the query which runs once the user clicks on a button.
How would i go about implementing the option for all or allow the user to select more than one option in the droplist?
Listboxes do work wonderfully to display the data and make multiple selections but i realize they now screw up how my query ran before....
Initially i had set the criteria for a query based on refering to the selection from the form with "[forms]![GenRADForm]![cboSize]", now with the specification of "[forms]![GenRADForm]![lstSize]" i get no results, any idea as to why and how i can overcome this?
But it might as well have been written in brail...my visual basic in access is non-existent.
The rowsource of values come from a table known as 'RESULTS' using "SELECT DISTINCT [RESULTS.Patient Size] FROM RESULTS ORDER BY [RESULTS.Patient Size]; "
I want to use the selected sizes from 'lstSize' to specify the parameter/criteria of patient size to perform another query called 'PercentGenResults'. Figured there would be some fancy code to do this....but i don't even know how to execute any code even if i did write it. HELP
Second link provided what looks like a better application, but i tried modifying the program for a 'btnOK' buttom and it did not even run my 'PercentGenResults' query....HELP ME :'(
It just sounds like you need to amend the SQL along the lines of
I'm not sure how this would work if you were selecting multiple lines in a list box but I'm sure there would be around it. this would at least be a starting point.
Same effect as specifying the criteria as '[Forms]![GenRADForm]![lstSize]', has something to do with how it notes the selections made from the list...having a warm time trying to make sense of it. If push comes to shove i'm going to have to go back to a combo box which would only allow one selection.