I want to select (goto) various areas of a worksheet by using a List Box.
I want to select (goto) various areas of a worksheet by using a List Box.
Demo: Add a commandbutton1 and a Listbox1 to your sheet. Put this in the
sheet module:
'*************************************
Private Sub CommandButton1_Click()
Dim i As Long
'this code will fill demo listbox with addresses:
Me.ListBox1.Clear
Randomize
For i = 1 To 60
ListBox1.AddItem Chr(Int(Rnd * 26) + 65) & Int(Rnd * 40)
Next
End Sub
Private Sub ListBox1_Click()
'the real thing:
Range(ListBox1.Text).Select
End Sub
'*************************************
Click first the button and then something in the listbox.
HTH. Best wishes Harald
"Marlowe" <Marlowe @discussions.microsoft.com> skrev i melding
news:69A9B67A-0739-46AD-B569-CF98F6005D53@microsoft.com...
> I want to select (goto) various areas of a worksheet by using a List Box.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks