Hi,
I am trying to create a VBA code that can open a workbook that is saved in different locations with varying file names.
But the sheet name and range remains the same. I want to select a constant range and copy it and paste values in the current openned work book.
Shown below is my code.
Code:
>>> You've already noted <<<
>>> use code - tags <<<
I am trying to create a VBA code that can open a workbook that is saved in different locations with varying file names.
But the sheet name and range remains the same. I want to select a constant range and copy it and paste values in the current openned work book.
Shown below is my code.
Code:
>>> You've already noted <<<
>>> use code - tags <<<
Code:
Sub Macro2()
Workbooks.Open Filename:= _
"C:\Users\dakis\Documents\99_blast_review\M001_WGP_Daily_Production_Report_221114.xlsx"
Columns("A:Q").Select
Range("Q1").Activate
Selection.Copy
Windows("Warrawoona_Digrates.xlsm").Activate
ActiveWindow.SmallScroll Down:=-15
Sheets("L&H_Input").Select
Range("U1").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Sheets("digrates").Select
End Sub
Attachments
Last edited by a moderator: