P
Paul Lambson
I created this macro in Microsoft Visual Basic wihin excel and
exported it as a VBS file. The macro runs fine within excel but if I
run it from my desktop I get an end of statement error.
Any Ideas?
Paul
Dim udpatedate As String
Dim myFile As String
Sub OpenBookTest()
Dim myPath As String
Dim myFile As String
myPath = "W:\YIELDMGT\Paul Lambson\SAS"
myFile = "ThanksChart.xls"
Set wbk = Workbooks.Open(Filename:=myPath & "\" & myFile, _
Password:="turkey", WriteResPassword:="turkey", UpdateLinks:=True)
ActiveWorkbook.RefreshAll
ActiveWorkbook.Save
ActiveWorkbook.Close
End Sub
exported it as a VBS file. The macro runs fine within excel but if I
run it from my desktop I get an end of statement error.
Any Ideas?
Paul
Dim udpatedate As String
Dim myFile As String
Sub OpenBookTest()
Dim myPath As String
Dim myFile As String
myPath = "W:\YIELDMGT\Paul Lambson\SAS"
myFile = "ThanksChart.xls"
Set wbk = Workbooks.Open(Filename:=myPath & "\" & myFile, _
Password:="turkey", WriteResPassword:="turkey", UpdateLinks:=True)
ActiveWorkbook.RefreshAll
ActiveWorkbook.Save
ActiveWorkbook.Close
End Sub