Greetings,
I am using the following code to access an Userform listbox. I am needing to disable the first row from being accessed.
Private Sub ListBox1_DblClick(ByVal Cancel As MSForms.ReturnBoolean)
Dim c As Control
If IsNull(Me.ListBox1.Value) Then
tName.SetFocus
Exit Sub
Else
REP_SetUp_2.tName = REP_SetUp.ListBox1.List(REP_SetUp.ListBox1.ListIndex, 0)
REP_SetUp_2.tCell = REP_SetUp.ListBox1.List(REP_SetUp.ListBox1.ListIndex, 1)
REP_SetUp_2.tEmail = REP_SetUp.ListBox1.List(REP_SetUp.ListBox1.ListIndex, 2)
For Each c In Me.Controls
If TypeName(c) = "TextBox" Then '''
c.Value = ""
End If
Next c
End If
Unload Me
REP_SetUp_2.Show
End Sub
Bookmarks