brodaddy2002
Board Regular
- Joined
- Jan 21, 2013
- Messages
- 67
I am trying to understand the code below. Can anyone hep me understand line 3?
This came from a Userform with ListBox1 Click event.
Private Sub ListBox1_Click()
If ListBox1.ListIndex <> -1 Then
Range(Cells(ListBox1.ListIndex + 2, 1), Cells(ListBox1.ListIndex + 2, _ 3)).Select
End If
End Sub
The code adds items to a listbox if the listindex equals -1. I am just trying to figure out what range the code selects.
This came from a Userform with ListBox1 Click event.
Private Sub ListBox1_Click()
If ListBox1.ListIndex <> -1 Then
Range(Cells(ListBox1.ListIndex + 2, 1), Cells(ListBox1.ListIndex + 2, _ 3)).Select
End If
End Sub
The code adds items to a listbox if the listindex equals -1. I am just trying to figure out what range the code selects.