Forum Discussion
Tito1995
Mar 09, 2020Copper Contributor
If Statement Problem
Hello, I am having some difficulty trying to figure out the right Excel formula and I was hoping to get some help from somebody. Basically, I have a Start Time column, an End Time column and then I...
Mel_G
Mar 10, 2020Copper Contributor
Hello,
I am not a fan of "AND" personally. I prefer to tackle my 'If's' one at a time.
Try this; =IF((S$1>MIN($Q2:$R2)),IF((S$1<MAX($Q2:$R2)),"1","0"),"0")
But, I'm not sure of the outcome you wanted for Q3:R3? The block is less than an hour, so there is no "1". If you do want the "1" in the 6 am hour, then you should check the start time, then use the length of time to determine whether or not you compare the end time to the current hour value, or the next hour value.