Once I multiple select on the listbox created from Forms tool box - how do I
use it ... where do I have the results of multiple selection
Once I multiple select on the listbox created from Forms tool box - how do I
use it ... where do I have the results of multiple selection
You'll need a macro to extract the values.
I'd put a button from that same Forms toolbar right next to the listbox. Then
the user can click that button when they want to extract the values.
Then assign this kind of code to that button:
Option Explicit
Sub testme()
Dim myLB As ListBox
Dim DestCell As Range
Dim iCtr As Long
With ActiveSheet
Set DestCell = .Range("B1")
Set myLB = .ListBoxes("List box 1")
End With
With myLB
'clear out previous entries?
DestCell.Resize(.ListCount, 1).ClearContents
For iCtr = 1 To .ListCount
If .Selected(iCtr) Then
DestCell.Value = .List(iCtr)
Set DestCell = DestCell.Offset(1, 0)
End If
Next iCtr
End With
End Sub
RKS wrote:
>
> Once I multiple select on the listbox created from Forms tool box - how do I
> use it ... where do I have the results of multiple selection
--
Dave Peterson
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks