If statement question.

Tami

New Member
Joined
Oct 24, 2002
Messages
2
I need to run a formula that will look and see if data is greater then, equal to or lesser then a condition and if it is then multiply a cell by another cell but I'm having problems with it.

Here is the forumla that I've written, can anyone please assist.

=IF(H27<=4,D27*0%,IF(H27>=5<=9,D27*3%,IF(H27>=10<=14,D27*4%,IF(H27>=15<=19,D27*6%,IF(H27>=20<=24,D27*7%,IF(H27>=25,D27*8%))))))

This forumla is returning FALSE into the cell.

Info for the cells

H27=15, D27=$28,912.00 - so the calculation should be calculating that H27 being 15, should take the $28,912.00 and multiply that figure by 6%.

I hope I've been clear enough on my example.


Thanks in advance for any help.
Tami
 

Excel Facts

Why are there 1,048,576 rows in Excel?
The Excel team increased the size of the grid in 2007. There are 2^20 rows and 2^14 columns for a total of 17 billion cells.

Asala42

Well-known Member
Joined
Feb 26, 2002
Messages
2,318
=IF(H27<=4,D27*0%,IF(H27>=5<=9,D27*3%,IF(H27>=10<=14,D27*4%,IF(H27>=15<=19,D27*6%,IF(H27>=20<=24,D27*7%,IF(H27>=25,D27*8%))))))

This should work.

=IF(H27<=4,D27*0%,IF(H27<=9,D27*3%,IF(H27<=14,D27*4%,IF(H27<=19,D27*6%,IF(H27<=24,D27*7%,IF(H27,D27*8%))))))

I think it was choking on statements like:
H27>=20<=24

You could have also replaced statements like that to:
AND(H27>=20,H27<=24)

HTH
 

Barrie Davidson

MrExcel MVP
Joined
Feb 10, 2002
Messages
2,330
Or you could try:

=IF(H27<=4,D27*0%,IF(H27<=9,D27*3%,IF(H27<=14,D27*4%,IF(H27<=19,D27*6%,IF(H27<=24,D27*7%,D27*8%)))))

Regards,
 

Tami

New Member
Joined
Oct 24, 2002
Messages
2
Thanks!!! It worked great, I was thinking it would accept the <=,>= as two separate statements, not realizing I had to separate them. Friday afternoon, I should have expected that.

Thanks again!!!
 

Chas17

Well-known Member
Joined
Oct 16, 2002
Messages
657
Aladin's is the one to use, use the Vlookup, the others work fine but you could place the Percents in cells and reference the cells, then if the percents change you only have to change one cell, not all the formulas.
 

Forum statistics

Threads
1,144,272
Messages
5,723,433
Members
422,497
Latest member
dougy99

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
Top