![]() |
xlCellTypeLastCell
Hi, I've been using the following code to ascertain the last typed cell, but
I have the problem of that when there is a data filter selected it doesn't include the hidden rows, so it just returns the last visible cell, therefore is there another function that will return the actual last cell even if there is a data filter selected. TIA KM |
xlCellTypeLastCell
Depends on your data, but perhaps
set rng = range("A1").currentRegion lastRow = rng.rows(rng.rows.count).Row -- Regards, Tom Ogilvy "Kevin McCartney" wrote in message ... Hi, I've been using the following code to ascertain the last typed cell, but I have the problem of that when there is a data filter selected it doesn't include the hidden rows, so it just returns the last visible cell, therefore is there another function that will return the actual last cell even if there is a data filter selected. TIA KM |
All times are GMT +1. The time now is 12:30 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com