ActiveSheet.Cells.Find(What:="*", After:=[A1], SearchOrder:=xlByRows, SearchDirection:=xlPrevious).Row
获取最后一列:
ActiveSheet.Cells.Find(What:="*", After:=[A1], SearchOrder:=xlByColumns, SearchDirection:=xlPrevious).Column
SpecialCells的方法,不能使用,因会得到空行。
ActiveSheet.Cells.SpecialCells(xlCellTypeLastCell).Row
参照:
https://blog.csdn.net/psp0001060/article/details/49643531 Excel VBA获取最后一行列 - 冬语的专栏 - CSDN博客