Article ID: 141692
Article Last Modified on 1/19/2007
Sub Get_Last_Cell_Value()
' Dimension the variable.
Dim LastCellValue As Variant
' Set the value of the last cell to the variable.
LastCellValue = ActiveCell.SpecialCells(xlLastCell).Value
' Display the variable in a message box.
MsgBox LastCellValue
End Sub
Sub Get_Last_Cell_Address()
Dim LastCellAddress As String
' Return the address of the last cell to the variable.
LastCellAddress = ActiveCell.SpecialCells(xlLastCell).Address
' Display the variable in a message box.
MsgBox LastCellAddress
End Sub
244435 How to reset the last cell in Excel
Tell Me About The Last Cell
SpecialCells
Additional query words: 5.00a 5.00c 8.00 XL97 XL98 XL7 XL5 XL
Keywords: kbdtacode kbhowto kbprogramming KB141692