D
Dave
Userform1 contains listbox1 and listbox2
Listbox1 contains the values: 1 2 3 4 5 in A1:A5
Listbox2 contains the values: a b c d e in B1:B5
Userform1 is called from a macro, the macro prompts a
user to select one of the options in listbox1. But
opposed to returning the value 1-5, I need it to return
the value from the adjacent cell. So if the user enters
3, it returns c.
The user needs to key in 3, not a mouse click.
Private Sub ListBox1_Click()
ActiveCell.Value = ListBox1
Unload Me
End Sub
I know I have seen this here before, but cannot find it.
Thanks,
Dave
Listbox1 contains the values: 1 2 3 4 5 in A1:A5
Listbox2 contains the values: a b c d e in B1:B5
Userform1 is called from a macro, the macro prompts a
user to select one of the options in listbox1. But
opposed to returning the value 1-5, I need it to return
the value from the adjacent cell. So if the user enters
3, it returns c.
The user needs to key in 3, not a mouse click.
Private Sub ListBox1_Click()
ActiveCell.Value = ListBox1
Unload Me
End Sub
I know I have seen this here before, but cannot find it.
Thanks,
Dave