May 10, 2007 #1 leesanc Technical User Aug 25, 2006 10 MY I am trying to write an If statement in Excel to return an "OK" if Value 1 - Value 2 = Multiples of 2 (i.e. 2,4,6,8,10,12 ....) Is there any formula for "multiples of a specific number
I am trying to write an If statement in Excel to return an "OK" if Value 1 - Value 2 = Multiples of 2 (i.e. 2,4,6,8,10,12 ....) Is there any formula for "multiples of a specific number
May 10, 2007 #2 Molby Technical User May 15, 2003 520 GB How about: =IF(MOD((Value1-Value2),2)=0,"OK","FALSE") Where the 2 is the mutiple you want to check. Upvote 0 Downvote
May 10, 2007 Thread starter #3 leesanc Technical User Aug 25, 2006 10 MY Wow! So fast. Yes, it works! Thank you so much. Upvote 0 Downvote
May 10, 2007 #4 GlennUK MIS Apr 8, 2002 2,937 GB Or: Code: =IF(ISEVEN(Value1-Value2),"OK","FALSE") if the multiple is always 2. ( tests for an even result. See the ISODD function for comparison. ) Cheers, Glenn. Did you hear about the literalist show-jumper? He broke his nose jumping against the clock. Upvote 0 Downvote
Or: Code: =IF(ISEVEN(Value1-Value2),"OK","FALSE") if the multiple is always 2. ( tests for an even result. See the ISODD function for comparison. ) Cheers, Glenn. Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
May 10, 2007 Thread starter #5 leesanc Technical User Aug 25, 2006 10 MY The multiple can be any other number, but this would come in handy too. Thank you. Upvote 0 Downvote