Copy data in a macro.

J

jfaz

I have recorded a macro to copy formula from one cell to a range of cells
using end and down arrow key in the macro to pick up the last record based on
the column to the left, this has dropped into the macro the last cell
reference. How can I include in the macro to copy to the last record line
(which could be variable)
 
M

Mike H

Hi,

Copies the last used cell in column A.

Sub versive()
Cells(Rows.Count, 1).End(xlUp)(1).Select
Selection.Copy
End Sub

Rows.Count, 1) change 1 to to for col B etc

Mike
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top