Strange VB
This is so strange
"Can't have else without if" in the code between the bold
Private Sub cmdRemove_Click()
Dim i As Integer
If Check1.Value = 1 And Check2.Value = 0 Then
For i = lstLeft.ListCount - 1 To 0 Step -1
' Delete this item.
If lstLeft.Selected(i) Then
lstLeft.RemoveItem i
End If
Next i
ElseIf Check2.Value = 1 And Check1.Value = 0 Then
For i = lstRight.ListCount - 1 To 0 Step -1
' Remove this item.
If lstRight.Selected(i) Then
lstRight.RemoveItem i
End If
Next i
End If
ElseIf Check2.Value = 0 And Check1.Value = 0 Or Check2.Value = 1
And Check1.Value = 1 Then
cmdRemove.Enabled = True
End If
End Sub
How wierd
Can anyone help?
------------------------------------------------
Apocolypse2005
Always ready and waiting to help!
__________________
Apocolypse2005, I'm a programmer - of sorts.
|