I'm trying to get a formula to work:
What it's intended to do is, if the values of G8 and G7 are the same, and the value of I9 is less than I7, then to calculate the difference of I7 from I9 and to add the value of I6. If the values of G8 and G7 are the same and the value of I9 is greater than I7, to subtract 4000 from I9 and add I6. The last condition is to simply put the value 0 as the result. I can't seem to get this to work... I tried to put the code in the message text but the system is stripping out half of it! It seems that the system doesn't like the "greater than" or "less than" symbols... I'll try it this way:
Thanks in advance.
What it's intended to do is, if the values of G8 and G7 are the same, and the value of I9 is less than I7, then to calculate the difference of I7 from I9 and to add the value of I6. If the values of G8 and G7 are the same and the value of I9 is greater than I7, to subtract 4000 from I9 and add I6. The last condition is to simply put the value 0 as the result. I can't seem to get this to work... I tried to put the code in the message text but the system is stripping out half of it! It seems that the system doesn't like the "greater than" or "less than" symbols... I'll try it this way:
Code:
=IF(OR(AND(G8=G7,I9"less than"I7)),I7-I9+I6,IF(OR(AND(G8=G7,I9"greater than"I7)),4000-I9+I6,0))