Odd question, probably easy answer

dowcraig

New Member
Joined
Jan 14, 2009
Messages
36
I'm trying to work on something that will allow me to do something if two results equal something...
so

If cell C4>499999 AND Cell C7=1, then multiply contents of cell C5 by .45
If cell C4>499999 and cell C7=2, then multiply contents of cell C5 by .55
If cell C4>499999 and cell C7=3, then multiply contents of cell C5 by .65
If cell C4>499999 and cell C7=4, then multiply contents of cell C5 by .85
If cell C4>499999 and cell C7=5, then multiply contents of cell C5 by 1.00
If cell C4<500000 and cell C7>1, then multiply contents of cell C5 by .70
If cell C4<500000 and cell C7=1, then multiply contents of cell C5 by .50

and i just can't seem to get that into a forumla that works.

Thoughts?

Thanks,
Craig
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
Untested but Try:
=if(and(C4>499999,or(C7=1,C7=2,C7=3,C7=5,C7=5)), C5*lookup(C7,{1;2;3;4;5),{0.45;0.55;0.65,0.85,1.00}),if(C4<500000,if(C7>1,C5*0.70,if(C7=1,C5*0.5,""))))
 
Last edited:
Upvote 0
Thanks, but it gives me a "The formula you typed contains an error.
Try:
=IF(AND(C4>499999,OR(C7=1,C7=2,C7=3,C7=4,C7=5)), C5*LOOKUP(C7,{1,2,3,4,5},{0.45,0.55,0.65,0.85,1}),IF(C4<500000,IF(C7>1,C5*0.7,IF(C7=1,C5*0.5,""))))
 
Upvote 0
What if C4 = 499999.5 and C7 = 3, what would the desired answer be? Conditions 3 and 6 are both valid here.
 
Upvote 0
What if C4 = 499999.5 and C7 = 3, what would the desired answer be? Conditions 3 and 6 are both valid here.

Good eye... ultimately, I don't know if that'll ever happen, but thanks for pointing that out.

Thanks.
 
Upvote 0

Forum statistics

Threads
1,213,543
Messages
6,114,240
Members
448,555
Latest member
RobertJones1986

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top