Assistance with function / formula to replace multiple nested if statement.

Hootywho

Board Regular
Joined
Oct 11, 2010
Messages
90
Hello,

I have a formula with muliple nested "If" statements that works perfect in 2010. However, the file will also be used with 2003 and thats a problem. Apparently 2003 does not allow the count that 2010 does. I'm sure there is something much better but I'm not sure what it is. Thanks so much for your help. Below is the actual formula I use.

=IF(B519=Inv!$A$31,Inv!$B$31,IF(B519=Inv!$A$32,Inv!$B$32,IF(B519=Inv!$A$33,Inv!$B$33,IF(B519=Inv!$A$34,Inv!$B$34,IF(B519=Inv!$A$35,Inv!$B$35,IF(B519=Inv!$A$36,Inv!$B$36,IF(B519=Inv!$A$37,Inv!$B$37,IF(B519=Inv!$A$38,Inv!$B$38,IF(B519=Inv!$A$39,Inv!$B$39,IF(B519=Inv!$A$40,Inv!$B$40,IF(B519=Inv!$A$41,Inv!$B$41,IF(B519=Inv!$A$42,Inv!$B$42,IF(B519=Inv!$A$43,Inv!$B$43,IF(B519=Inv!$A$44,Inv!$B$44,IF(B519=Inv!$A$45,Inv!$B$45,IF(B519=Inv!$A$46,Inv!$B$46,IF(B519=Inv!$A$47,Inv!$B$47,IF(B519=Inv!$A$48,Inv!$B$48,IF(B519=Inv!$A$49,Inv!$B$49,IF(B519=Inv!$A$50,Inv!$B$50,IF(B519=Inv!$A$51,Inv!$B$51,IF(B519=Inv!$A$52,Inv!$B$52,IF(B519=Inv!$A$53,Inv!$B$53,IF(B519=Inv!$A$54,Inv!$B$54,IF(B519=Inv!$A$55,Inv!$B$55,"")))))))))))))))))))))))))

<colgroup><col style="width: 48pt;" width="64"> <tbody>
</tbody>
 

Some videos you may like

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".

taurean

Well-known Member
Joined
Jun 17, 2011
Messages
2,179
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Your life in 2010 and 2003 would be much easier with VLOOKUP:
=VLOOKUP(B519,Inv!$A$31:$B$55,2,0)
 

Hootywho

Board Regular
Joined
Oct 11, 2010
Messages
90
Thanks so much, I will give it a try. Any procedure for copying this down to other cells, I have never used Vlookup.
 

taurean

Well-known Member
Joined
Jun 17, 2011
Messages
2,179
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
It will be good if you read some information on VLOOKUP like here. You can copy down any of the formula posted!
 

Watch MrExcel Video

Forum statistics

Threads
1,122,482
Messages
5,596,402
Members
414,063
Latest member
N_Bates

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