Nimrod667 Posted September 27, 2007 Share Posted September 27, 2007 Hi, I need to compare a variable with two criterias. For example: I have to check if $i is between 5 and 10, so i have to check if $i is greater than 5 and smaller then 10. If I use : case $i >= 5 and $i <= 10 its also true if $i is 20...I need something like case $i >=5 and <=10 How can I do this? //Nimrod Link to comment Share on other sites More sharing options...
smashly Posted September 27, 2007 Share Posted September 27, 2007 hi, If I use : case $i >= 5 and $i <= 10 its also true if $i is 20...Example why I think it's not correct in what your saying... For $i = 1 To 100 Select Case $i >= 5 And $i <= 10 MsgBox(0, "", $i) EndSelect Next Cheers Link to comment Share on other sites More sharing options...
weaponx Posted September 27, 2007 Share Posted September 27, 2007 if ($i >= 5 And $i <= 10) OR $i = 20 Link to comment Share on other sites More sharing options...
Nimrod667 Posted September 28, 2007 Author Share Posted September 28, 2007 Thanks for your help guys! Got it to work! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now