what I want is copy the data and paste in the same sheet as shown in the sample file by vba

what I want is copy the data and paste in the same sheet as shown in the sample file  by vba
Book1.xlsm
Avinash SinghAsked:
Who is Participating?
 
Subodh Tiwari (Neeraj)Connect With a Mentor Excel & VBA ExpertCommented:
You may try something like this...

Sub CopyData()
Dim ws As Worksheet
Set ws = Sheets("Sheet1")
ws.Range("D5:G23").Copy ws.Range("J35")
End Sub

Open in new window

0
 
LET (Learn Excel in Tamil)Connect With a Mentor Reporting Automation ExpertCommented:
Hi ,

Open your excel file, press ALT+F11 and paste this code

Press F8 to run, please note this code created based only on the range were you highlighted on sample file,

In case there is no change in data ranges this will working fine, you can change range if require

Please let me know for any queries


Sub Copypaste()
Range("D5:G23").Copy
Range("J35:M53").PasteSpecial
Application.CutCopyMode = False
End Sub

Open in new window



Thanks and Regards,
Learn Excel in Tamil
Mail us: learnexcelintamil@gmail.com

Subscribe on YouTube : https://www.youtube.com/channel/UC5vGAvycUz41AzyUP7vi61Q 
Like our page in Facebook : https://www.facebook.com/Learnexcelintamil/
0
 
Avinash SinghAuthor Commented:
Thnx again Neeraj sir and thnx Learn Excel in Tamil Sir
1
 
Subodh Tiwari (Neeraj)Excel & VBA ExpertCommented:
You're welcome Avinash!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.