The originally selected cell(s) are stored in rngStart
to be re-selected at the end, so the user won't be transported away by the macro. However, the range stored in rngStart
changes. Seemingly by itself. It ends up being the range where the paste operation happens.
Sub Macro2()
Application.ScreenUpdating = False
Dim rngStart 'The variable I'm struggling with
Dim ws As Worksheet
Set rngStart = Selection 'Store original selection
Set ws = ActiveSheet
Selection.Cut
'Find an empty cell in column B
For Each cell In ws.Columns(2).Cells
If IsEmpty(cell) = True Then cell.Select: Exit For
Next cell
ActiveSheet.Paste 'Upon executing this line, rngStart changes to the cell being pasted to
rngStart.Select 'Supposed to return to the originally selected range
Application.ScreenUpdating = True
End Sub