VBA Userform - Multiselect List box - Can you click an item and have it automatically appear in a list?

wmc5880

New Member
Joined
Jul 8, 2013
Messages
34
Hello all!
Question for you. I haven't had much luck searching around the internet without using yet another button. Hoping to get around it.

Is there an event where i once i select an item from a multiselect list box, i can trigger it to populate on another list?
I have a multiselect listbox on the left and i would like for it populate automatically on the right hand side in a list form.

Thanks guys!
 

Excel Facts

Quick Sum
Select a range of cells. The total appears in bottom right of Excel screen. Right-click total to add Max, Min, Count, Average.
It would be less code (and hassle) to do single item dbl-click, to add to another list.
With a source list,lstSrc, and a target list , lstTarg this is all youd need:

Code:
Private Sub lstSrc_DblClick(ByVal Cancel As MSForms.ReturnBoolean)
lstTarg.AddItem lstSrc
end sub

its a lot more code to do multi-select.
 
Upvote 0

Forum statistics

Threads
1,214,647
Messages
6,120,722
Members
448,987
Latest member
marion_davis

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top