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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can you select several lines in a listbox, if yes how??? 1

Status
Not open for further replies.

marlun

Programmer
Feb 7, 2003
70
SE
I have a query that selects products and shows them in listbox. I would like to if there is a way to select specific lines or all lines from the listbox that I want to use for other purposes e.g. deliveries or spmething like that. Does anyone know. I would really like to know.

Thanks
 
Yes you can.. Right click the listbox and select properties, click the 'Other' tab and set the "Multi Select" control to:

None = only 1 item may be selected
Simple = You can select numerous noncontiguous values
Extended = Allows use of Ctrl+Click or Shift+Click function.
 
Can I connect the marked lines to a query or to a form???
Lats say I have a deliveryform and I want to select some of the products in the list that I want to deliver, and then have an actionbutton that opens a new form with the selected lines, or something like that.
How does the query know which lines I've selected. If I mark line one and four and then click the button it knows that it should pick line one and four!!??

Thanks
 
Normally you would have a hidden column for this kind of functionality (you hide the column by setting the width to 0cm)

the column would contain an ID number for the selection and you would populate the 2nd form with a combination of the 2 ID's
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top