Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21243

And operator not working correctly in VB 6.0

$
0
0
The "AND" operator is not behaving correctly in VB 6.0

If (13 And 15) Then
MsgBox "TRUE - 13 and 15"
Else
MsgBox "FALSE - 13 and 15"
End If

If (13 And 16) Then
MsgBox "TRUE - 13 and 16"
Else
MsgBox "FALSE - 13 and 16"
End If

For the second if condition the value will be false. Wanted to know whether the above one is correct? Why its behaving like this?

Viewing all articles
Browse latest Browse all 21243

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>