Forum Discussion
How to copy and paste data automatically with power query
Hello,
Please refer to the attached image.
I have imported data from another worksheet into a master excel file and loaded it which is seen in the attached image.
How do I copy and paste all those cells into specific cells in another worksheet in the master file as a macro step ?
Thank you
Please help !
2 Replies
- Logaraj SekarIron Contributor
Hi Raj,
Just specify excel file names in macro.
Sub Macro1()
Windows("<another worksheet name>.xlsx").activate
Sheets("<specify the sheetname>").Select
Range("C2:H24").SelectSelection.Copy
Windows("<master worksheet name>.xlsx").Activate
Sheets("<specify the sheetname>").Select
Range("C2").Select
Selection.PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = FalseEnd Sub
Ask in any clarification.
- RAJ GUJARECopper Contributor
Are you able to help me with this problem :
https://techcommunity.microsoft.com/t5/Excel/Need-help-urgently-with-power-query/m-p/183448#M5307
?