I have a macro which does few calculation in another workbook and creates a new sheet where it writes the final data.
In the last step, the values from the new sheet should be copied to the current workbook where the Macro is written.
I have written the following line to do the paste activity. But my problem is, each time the data gets pasted in different places in the workbook. Is there a way for me to paste values starting from particular column
ThisWorkbook.Activate
Sheets(1).Select
ActiveSheet.Paste
Of course, if its a static range:
Range("B3:D7").Select 'Or the range you need
Selection.Copy ' Copy that selection
Sheets("yoursheet").Select 'Select the sheet or workbook where you will paste info
ActiveSheet.Paste ' Paste data
Tell me how it goes.
To select the range in destination Sheet use this order :
Sheets("yoursheet").Select
Range("A1").PasteSpecial Paste:=xlPasteValues
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.