I am using a Select Case to identify day of the week limitations. Jabaco gives an error for "Case 1 to 30" and Case Is > 30
Select Case Val(temp)
Case 0
cbo_HDay.ListIndex = -1
cbo_HDay.SetFocus
Exit Sub
Case 1 To 30
cbo_HDay.ListIndex = Val(temp - 1)
Case Is > 30
cbo_HDay.ListIndex = -1
cbo_HDay_LostFocus
Exit Sub
Case Else
End Select
End If
Case Else
End Select
Also, when I use round brackets I get an end of statement missing error. When I use square brackets the program compiles. My question is when do you use round or square brackets?
This works:
If Len(cbo_AuxI.Text) > 0 Then
Select Case cbo_AuxI.ListIndex
Case 4
cup[RecordNum].PM = 1 ' Square Brackets
txt_PM.Text = txt_MPM.Text
txt_GPM.Enabled = False
.......
End Select
End If
This Does not Work:
If Len(cbo_AuxI.Text) > 0 Then
Select Case cbo_AuxI.ListIndex
Case 4
cup(RecordNum).PM = 1 ' Origional VB round brackets
txt_PM.Text = txt_MPM.Text
txt_GPM.Enabled = False
.......
End Select
End If
Thank you... Ronnie