Hi,
My VBA pulls data from three different source files into one central location, however, there is now a password on the source files, so the VBA falls over.
Is there a code that I can add in that will input the password once it gets to the right moment.
Please see code below.
My VBA pulls data from three different source files into one central location, however, there is now a password on the source files, so the VBA falls over.
Is there a code that I can add in that will input the password once it gets to the right moment.
Please see code below.
Code:
Sub copy_newlines()
Dim LastRow1
LastRow1 = Sheets("SUMMARY").Cells(Sheets("SUMMARY").Rows.Count, "A").End(xlUp).Row
Application.DisplayAlerts = False
Workbooks.Open Filename:= _
"\\Dhvs-data05\data05\Shared\List\P2017\WWBTagE\BF WK 29-32.xlsx", ReadOnly:=True
Windows("BF WK 29-32 CE.xlsx").Activate
Range("A10:A2500").Copy
Windows("BF Master 2017.xlsm").Activate
Range("A" & Rows.Count).End(xlUp).Offset(1).Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Last edited by a moderator: