[thechat] Visual Basic: "And", "Or" operators: Help?
Syed Zeeshan Haider
szh at softhome.net
Sat Oct 19 10:42:01 CDT 2002
Hello Everybody,
Nowadays, I am learning Visual Basic 6.0 by self study. In JavaScript statements
like:
if (x==0 && (y==1 || z==0)){
//do something
}
work very well.
But I have noticed that in Visual Basic, it doesn't work.
I have a statement in VB:
If harf = "A" And (lst <> Empty Or lst <> " ") Then
'do something
It always returns true if harf="A" is true. I want it to "return true" only when
any one of statements in parenthesis is true along with harf = "A".
Is there any VB expert here to help?
Thank you,
Syed Zeeshan Haider.
http://syedzeeshanhaider.faithweb.com/
More information about the thechat
mailing list