View Full Version : Alternate If-Then Statement Help
pdegior
- 15th August 2007, 15:57
I was wondering if anyone could tell me if the structure of this statement is valid
if 130 < ch1_input < 170 then
xxx
endif
Or, do I need to break it up into 2 conditional statements?
Jerson
- 15th August 2007, 18:16
I was wondering if anyone could tell me if the structure of this statement is valid
if 130 < ch1_input < 170 then
xxx
endif
Or, do I need to break it up into 2 conditional statements?
Your statement should throw an error. You could try the following code instead
if (ch1_input > 130) and (ch1_input < 170) then
xxx
endif
Jerson
pdegior
- 16th August 2007, 00:07
Thanks for the response.
PBP did not throw an error, that is why I was wondering. I tried it in a simple program, but it resulted in unpredictable behavior.
Thanks again!
Powered by vBulletin® Version 4.1.7 Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.