G
Guest
I have a piece of code that's acting funny. The variable is set as a string,
not a Boolean. The variable could be: Yes, No, Unk or INC. yet, if it's one
of the last two, it throws an error because it believes it's a Boolean. Is
there anyway to get around this? Code is below.
Thanks in Advance!
Elena
If strStat = "Yes" Then
intGreen = intGreen + 1
intSec = intSec + 1
End If
If strStat = "No" Then
intRed = intRed + 1
intSec = intSec + 1
End If
If strStat = "UNK" Or "INC" Then
intYellow = intYellow + 1
End If
not a Boolean. The variable could be: Yes, No, Unk or INC. yet, if it's one
of the last two, it throws an error because it believes it's a Boolean. Is
there anyway to get around this? Code is below.
Thanks in Advance!
Elena
If strStat = "Yes" Then
intGreen = intGreen + 1
intSec = intSec + 1
End If
If strStat = "No" Then
intRed = intRed + 1
intSec = intSec + 1
End If
If strStat = "UNK" Or "INC" Then
intYellow = intYellow + 1
End If