Stop ranges within formula from moving when a new row is added

ThomG

New Member
Joined
Feb 18, 2019
Messages
4
My array formula below works BUT, I think I need to apply maybe an INDIRECT function to stop the ranges from moving when I add a new row to my data set. Can anyone help?

{=IFERROR(INDEX('EIRF Tracker '!$N$9:$N$2000,MODE(IF('EIRF Tracker '!$G$9:$G$2000="Injury",IF('EIRF Tracker '!$B$9:$B$2000="2018-19",IF('EIRF Tracker '!$C$9:$C$2000=C54,IF('EIRF Tracker '!$N$9:$N$2000<>"0",MATCH('EIRF Tracker '!$N$9:$N$2000,'EIRF Tracker '!$N$9:$N$2000,{0,0}))))))),"None")}

Thank you in advance!
Gem
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.

Eric W

MrExcel MVP
Joined
Aug 18, 2015
Messages
12,212
My array formula below works BUT, I think I need to apply maybe an INDIRECT function to stop the ranges from moving when I add a new row to my data set. Can anyone help?

{=IFERROR(INDEX('EIRF Tracker '!$N$9:$N$2000,MODE(IF('EIRF Tracker '!$G$9:$G$2000="Injury",IF('EIRF Tracker '!$B$9:$B$2000="2018-19",IF('EIRF Tracker '!$C$9:$C$2000=C54,IF('EIRF Tracker '!$N$9:$N$2000<>"0",MATCH('EIRF Tracker '!$N$9:$N$2000,'EIRF Tracker '!$N$9:$N$2000,{0,0}))))))),"None")}

Thank you in advance!
Gem
Everywhere you have a range, just substitute an INDIRECT. For example, the part in red becomes:

INDEX(INDIRECT("'EIRF Tracker '!$N$9:$N$2000"),
 

ThomG

New Member
Joined
Feb 18, 2019
Messages
4
Thanks Eric! I have just attempted this and Excel is telling me I have too few arguments... can you spot anything obvious?

=IFERROR(INDEX(INDIRECT("'EIRF Tracker '!$N$9:$N$2000"),MODE(IF(INDIRECT("'EIRF Tracker '!$G$9:$G$2000"="Injury",IF(INDIRECT("'EIRF Tracker '!$B$9:$B$2000"="2018-19",IF(indirect("'EIRF Tracker '!$C$9:$C$2000"=C55,IF(indirect("'EIRF Tracker '!$N$9:$N$2000"<>"0",MATCH(indirect("'EIRF Tracker '!$N$9:$N$2000",(indirect("'EIRF Tracker '!$N$9:$N$2000",{0,0}))))))),"None")

Gem
 

Eric W

MrExcel MVP
Joined
Aug 18, 2015
Messages
12,212
Try:

Code:
=IFERROR(INDEX(INDIRECT("'EIRF Tracker '!$N$9:$N$2000"),MODE(IF(INDIRECT("'EIRF Tracker '!$G$9:$G$2000")="Injury",IF(INDIRECT("'EIRF Tracker '!$B$9:$B$2000")="2018-19",IF(INDIRECT("'EIRF Tracker '!$C$9:$C$2000")=C54,IF(INDIRECT("'EIRF Tracker '!$N$9:$N$2000")<>"0",MATCH(INDIRECT("'EIRF Tracker '!$N$9:$N$2000"),INDIRECT("'EIRF Tracker '!$N$9:$N$2000"),{0,0}))))))),"None")
 
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,164,297
Messages
5,836,479
Members
430,434
Latest member
whatabout

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