How to paste till last row using Macro

Chandrakanth K

Hello Team,


I have two columns "System" and "CC". I need to past dolphin after the last row till i have values in "CC".

How do i code this. when i record i am getting a range but range always changes. Need help


Attached Macro File.




1 Reply


How about the below?     Cells(Rows.Count, 2).End(xlUp).Row     finds the last used row in Column 2. 



Sub FillDolphin()

Dim lRow As Long

lRow = Cells(Rows.Count, 2).End(xlUp).Row

Range("A4:A" & lRow).Formula = "Dolphin"

End Sub


Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
22 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
flashing a white screen while open new tab
cntvertex in Discussions on
13 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
28 Replies