Illusion Posted April 13, 2008 Share Posted April 13, 2008 If Time is 12:00:00PM Or Time is 1:00:00PM Or Time is 2:00:00PM And Status 'Bathroom Sink Heater' is On Then Set 'Bathroom Sink Heater' Off Else - No Actions - (To add one, press 'Action') If it is not clear, what I am trying to do is turn off the IR Sink Heater if it has been left on. I have the ISY looking at this three times a day. If it has been left on at any of these times I want the ISY to turn it off. Do I need Parentheses around the 'OR' arguments? I know that it will work with them there, but will it work without them there? Link to comment
Chris Jahn Posted April 14, 2008 Share Posted April 14, 2008 Illusion, Yes, you need parenthesis, basically 'ANDs' are grouped together A or B or C and D is the same as A or B or (C and D) What I think you want is (A or B or C) and D Link to comment
Illusion Posted April 14, 2008 Author Share Posted April 14, 2008 Thanks Chris. That is what I thought after sleeping on it. Thanks for the confirming this. Link to comment
brobin Posted April 15, 2008 Share Posted April 15, 2008 Hmmm, I had a program that was IF A and B or C or D and it apparently worked as I wanted it to which is IF A and (B or C or D) not (A and or C or D, but after reading this I went back and added the parenthesis around (B or C or D). I'm wondering why it worked correctly without the parens. Link to comment
Chris Jahn Posted April 15, 2008 Share Posted April 15, 2008 brobin, Not sure why it would have worked, unless maybe your C and D conditions where never True, or it just so happened that A was always True when C and/or D were True. Link to comment
brobin Posted April 16, 2008 Share Posted April 16, 2008 I think you're right about that. I didn't exercise it through all conditions. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.