Grab number from column but not the last number

kdrennan

New Member
Joined
Oct 16, 2018
Messages
9
Office Version
  1. 365
Platform
  1. Windows
  2. MacOS
Hello All,

I have a workbook with multiple worksheets. I populate the main page with information from the other worksheets.
This has worked fine until I tried to grab a number (not the last number) from column that has a total at the bottom.

I want to populate cell J3 on the main page with the last entered number of column AD on sheet 8. column AD has a total at the bottom that I do not want. I just want the last number in the column above the total. there are a number of empty cells in-between but all are empty.
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

I have assumed data will not go below row 1000 in column AD. You can adjust that number up or down if you want.
See if this does what you want.

Excel Formula:
=LOOKUP(9.99E+307,AD1:INDEX(AD:AD,LOOKUP(9.99E+307,AD1:AD1000,ROW(AD1:AD1000))-1))
 
Upvote 0
If you have Microsoft 365, you could also try
Excel Formula:
=INDEX(AD1:AD1000,LARGE(FILTER(ROW(AD1:AD1000),AD1:AD1000<>""),2))
 
Upvote 0
If you have Microsoft 365, you could also try
Excel Formula:
=INDEX(AD1:AD1000,LARGE(FILTER(ROW(AD1:AD1000),AD1:AD1000<>""),2))
I do have 365, this is not pointing to the sheet8? is that why it gives me a NA error
 
Upvote 0
I would like to use the code that works on both 2019 and 365 though.. Where can I insert sheet name at?
 
Upvote 0
You're welcome. Glad you got it sorted. :)
 
Upvote 0

Forum statistics

Threads
1,214,947
Messages
6,122,413
Members
449,082
Latest member
tish101

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