Autofill

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How can I get a formula keyed in cell E2 and then copy down to the last row
that has contents in a2. I've also got to copy and paste special values from
column E that has the formula back to column c and delete column E.

This is the formula I am using =(LEFT(C2,LEN(C2)-2)

Any ideas? I've tried numerous things but I can't get any of them to work..
 
rojobrown,

here's one way:

Sub test()
Dim lLastRow As Long

lLastRow = Range("A65535").End(xlUp).Row
With Range("E2:E" & lLastRow)
.FillDown
.Copy
End With
Range("C2:C" & lLastRow).PasteSpecial xlPasteValues
Range("E2:E" & lLastRow).ClearContents

End Sub
 
That did it. I am not good at this stuff. Thank you sooo much for your
help!!!
 

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

Back
Top