If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Multiple Selections in Combo Boxes
Hey,
I was wondering if there is a way to select multiple items in combo boxes. For example, I have a combo box of county names, am I able to select multiple counties from that combo box to run my query and report with? Thanks, Matt |
#2
|
|||
|
|||
Multiple Selections in Combo Boxes
No, you will have to select them one at a time and build the list somewhere
else, concatenating in the latest selection. A listbox will do what you're asking. -- Wayne Morgan MS Access MVP "Matt" wrote in message ... Hey, I was wondering if there is a way to select multiple items in combo boxes. For example, I have a combo box of county names, am I able to select multiple counties from that combo box to run my query and report with? |
#3
|
|||
|
|||
Multiple Selections in Combo Boxes
Wayne,
Thanks for your help. How would I send the selections somewhere else? -Matt |
#4
|
|||
|
|||
Multiple Selections in Combo Boxes
You could concatenate in a static variable or use a textbox (hidden if you
like). You may want a "clear" button to start a new string. Use the AfterUpdate event of the combobox to concatenate the string. Using a textbox to hold the string it would look similar to: Me.txtMyTextbox = Me.txtMyTextbox & ", " & Me.cboMyCombobox If Right(Nz(Me.txtMyTextbox, ""), 1) = "," Then 'remove the trailing comma Me.txtMyTextbox = Left(Me.txtMyTextbox, Len(Me.txtMyTextbox) -1) End If If the text you want to concatenate is not the bound column of the combobox, you would need to specify the column to get the data from. -- Wayne Morgan Microsoft Access MVP "Matt" wrote in message news Wayne, Thanks for your help. How would I send the selections somewhere else? -Matt |
Thread Tools | |
Display Modes | |
|
|