Forum Discussion
jsrmenke
Sep 08, 2025Copper Contributor
Excel help!
How would I capture the data from the last cell in a column when the column length is variable?
- Sep 11, 2025
Thanks to SergeiBaklan​ I may now understand what you want. To get the last displayed value in column B, use
=INDEX(B1:B100, MAX(IF(($B$14:$B$100<>"")*(($D$14:$D$100>0)+($F$14:$F$100>0)), ROW($D$14:$D$100))))
Adjust the column in B1:B100 for the last displayed value in other columns, for example for column K:
=INDEX(K1:K100, MAX(IF(($B$14:$B$100<>"")*(($D$14:$D$100>0)+($F$14:$F$100>0)), ROW($D$14:$D$100))))
HansVogelaar
Sep 08, 2025MVP
Let's say the column is column K.
If it contains numbers or dates, you can use
=LOOKUP(9.99999999999999E+307, K:K)
If it contains text values, you can use
=LOOKUP(REPT("z", 255), K:K)
If if contains a mixture of values, you can use
=INDEX(K:K, MAX(IF(K:K<>"", ROW(K:K))))