Copy Paste in Macro

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

Guest

How do I reduce the coding involved in this statement.
FinalRow is just an integer value. Thanks you


Range("A2:D" & FinalRow).Select
Selection.Copy
Range("E2:H" & FinalRow).Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A2").Select
 
How do I reduce the coding involved in this statement.
FinalRow is just an integer value. Thanks you

Range("A2:D" & FinalRow).Select
Selection.Copy
Range("E2:H" & FinalRow).Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A2").Select

try this:
Range("A2:D" & FinalRow).Copy Range("E2:H" & FinalRow)

or:
Range("E2:H" & FinalRow).Value = Range("A2:D" & FinalRow).Value

--
Regards
Melanie Breden
- Microsoft MVP für Excel -

http://excel.codebooks.de (Das Excel-VBA Codebook)
 

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