Ok, I'll try to be as detailed as possible.
These are the cells and values:
A1 - 120
A2 - 340
A3 - 110
A4 - 110
A5 - 110
A6 - 110
Ok I've taken cell B1 to calculate A2-A1, and then B2 to calculate A3-A2. I'll skip cell B3 because I've taken care of that formula.
Now, here is my problem. I'm looking for a formula for my cell B4 that can say: if my A4 value is equal to A3 and A5, then display cero in this celI. If A4 is not equal to A3 or A5, then I can continue to subtract A4-A3. But if A4 is ONLY equal to A5 then subtract A1-A4
I hope that helps.
Last edited by yekom; 09-01-2011 at 02:00 PM.
So, in B4:
=IF(AND(A4=A3,A4=A5), 0, IF(A4=A5, A1-A4, A4-A3))
_________________
Microsoft MVP 2010 - Excel
Visit: Jerry Beaucaire's Excel Files & Macros
If you've been given good help, use theicon below to give reputation feedback, it is appreciated.
Always put your code between code tags. [CODE] your code here [/CODE]
“None of us is as good as all of us” - Ray Kroc
“Actually, I *am* a rocket scientist.” - JB (little ones count!)
@JBeaucaire
Thanks a lot for your help, it worked perfectly! You saved my life :D
If that takes care of your need, please click EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED.
_________________
Microsoft MVP 2010 - Excel
Visit: Jerry Beaucaire's Excel Files & Macros
If you've been given good help, use theicon below to give reputation feedback, it is appreciated.
Always put your code between code tags. [CODE] your code here [/CODE]
“None of us is as good as all of us” - Ray Kroc
“Actually, I *am* a rocket scientist.” - JB (little ones count!)
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks