help with if then statement

Excel Facts

Round to nearest half hour?
Use =MROUND(A2,"0:30") to round to nearest half hour. Use =CEILING(A2,"0:30") to round to next half hour.
Hi,

Change all your number requirements referencing M2 to decimals (i.e. 85 to 0.85, 90 to 0.9, etc.), since M2 is a % percentage, 90% is actually 0.9
 
Upvote 0
You're welcome, welcome to the forum.This is a simplified version of your IF formula, and a LOOKUP alternative:


Book1
MNOP
290.00%N/AYour original formula
32My shorter version
42Using LOOKUP
Sheet36
Cell Formulas
RangeFormula
O2=IF(AND(M2>85,M2<90),1,IF(AND(M2>89.99,M2<95),2,IF(AND(M2>94.99,M2<100),3,IF(AND(M2>99.99,M2<105),4.5,IF(AND(M2>104.99,M2<110),6.5,IF(AND(M2>109.99,M2<120),8.5,IF(AND(M2>119.99,M2<130),10.5,IF(M2>129.99,13.5,"N/A"))))))))
O3=IF(M2>0.85,IF(M2<0.9,1,IF(M2<0.95,2,IF(M2<1,3,IF(M2<1.05,4.5,IF(M2<1.1,6.5,IF(M2<1.2,8.5,IF(M2<1.3,10.5,13.5))))))),"N/A")
O4=LOOKUP(M2,{0,0.8501,0.9,0.95,1,1.05,1.1,1.2,1.3},{"N/A",1,2,3,4.5,6.5,8.5,10.5,13.5})
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,164
Messages
6,170,444
Members
452,326
Latest member
johnshaji

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