Forum Discussion
dhinz805
Sep 09, 2024Copper Contributor
Macros and VBA
My old macro won't work in windows 11. Specfically the command that allows you to go to the bottom of a long list no longer will compile. What is the command for this function?
HansVogelaar
Sep 09, 2024MVP
What is the code that won't work?
Code like this should still be valid:
Dim FirstCell As Range
Dim LastCell As Range
Set FirstCell = Range("A1")
Set LastCell = FirstCell.End(xlDown)
' If you want to select that cell
LastCell.Select