View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Macro to copy data from One sheet to another

Public Sub CopyOne()
Worksheets("Sheet1").Range("E1:E7").Copy _
destination:=worksheets("sheet2").Range("F2")
End Sub

Excel will expand that "to" range--just like when you do it manually.

Jurassien wrote:

Hello,

Can someone help me in creating a macro that will copy data from one
worksheet and paste it to a new worksheet? The code below move data within
the same worksheet. Please Helps!

Public Sub CopyOne()
Worksheets("Sheet1").Activate
'Range("E1:E7").Copy Range("F2:F7")


End Sub


--

Dave Peterson