kazooie21
November 14th, 1999, 04:26 PM
I don't understand why all but one of the incorrects come out correct! Here is my code.
[vbcode]
Private Sub cmdCheck_Click()
If optCal.Value = optSac.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optCol.Value = optDen.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optIll.Value = optSpr.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optOre.Value = optSal.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optWis.Value = optMad.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optSac.Value = optCal.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optDen.Value = optCol.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optIll.Value = optSpr.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optOre.Value = optSal.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optWis.Value = optMad.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
End Sub
Private Sub optCal_Click()
'assign correct capital to strCapital variable
strCapital = optSac
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optCol_Click()
'assign correct capital to strCapital variable
strCapital = optDen
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optDen_Click()
'assign capital choice to strChoice variable
strChoice = optCol.Value
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optIll_Click()
'assign correct capital to strCapital variable
strCapital = optSpr
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optMad_Click()
'assign capital choice to strChoice variable
strChoice = optWis.Value
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optOre_Click()
'assign correct capital to strCapital variable
strCapital = optSal
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optSac_Click()
'assign capital choice to strChoice variable
strChoice = optCal
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optSal_Click()
'assign capital choice to strChoice variable
strChoice = optOre
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optSpr_Click()
'assign capital choice to strChoice variable
strChoice = optIll
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optWis_Click()
'assign correct capital to strCapital variable
strCapital = optMad
'clear label control
lblMsg.Caption = " "
End Sub
kazooie21
[vbcode]
Private Sub cmdCheck_Click()
If optCal.Value = optSac.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optCol.Value = optDen.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optIll.Value = optSpr.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optOre.Value = optSal.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optWis.Value = optMad.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optSac.Value = optCal.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optDen.Value = optCol.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optIll.Value = optSpr.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optOre.Value = optSal.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
If optWis.Value = optMad.Value Then
lblMsg.Caption = "Correct"
Else
lblMsg.Caption = "Incorrect"
End If
End Sub
Private Sub optCal_Click()
'assign correct capital to strCapital variable
strCapital = optSac
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optCol_Click()
'assign correct capital to strCapital variable
strCapital = optDen
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optDen_Click()
'assign capital choice to strChoice variable
strChoice = optCol.Value
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optIll_Click()
'assign correct capital to strCapital variable
strCapital = optSpr
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optMad_Click()
'assign capital choice to strChoice variable
strChoice = optWis.Value
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optOre_Click()
'assign correct capital to strCapital variable
strCapital = optSal
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optSac_Click()
'assign capital choice to strChoice variable
strChoice = optCal
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optSal_Click()
'assign capital choice to strChoice variable
strChoice = optOre
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optSpr_Click()
'assign capital choice to strChoice variable
strChoice = optIll
'clear label control
lblMsg.Caption = " "
End Sub
Private Sub optWis_Click()
'assign correct capital to strCapital variable
strCapital = optMad
'clear label control
lblMsg.Caption = " "
End Sub
kazooie21