Hi everyone! I am programming (or trying to!!) a Makro to make certain administrative tasks more efficient. Unfortunetly I am completly stuck:
I have declared String Variables and used data from the workbook to define them:
Dim SupplierCode As String
Dim Year As String
Dim ToyotaPlant As String
Dim Month As String
Dim Manifest As String
Sheets("january").Select
Range("B3").Select
SupplierCode = ActiveCell
Range("G3").Select
ToyotaPlant = ActiveCell
Range("J2").Select
Month = ActiveCell
Range("J3").Select
Year = ActivCell
Sheets("TPN").Select
Range("L15").Select
Manifest = ActiveCell
Now I would like to save the file, using these variables in the File-Path:
ActiveWorkbook.SaveAs Filename:="\\Brufs01\TRANSFER\TPN_Database\"Toyotaplant"\"Year"\"SupplierCode"\"Month"\"Manifest".xls", _
FileFormat:=xlNormal, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False
This doesnt work, I think its only a syntax error but IMPOSSIBLE to make it work, aaargh
Also if this path doesnt exist I would like excel to simply create and not make a fuss!!! Any help would be very very much appreciated!!
Thanks alot in advance,
Jan
Bookmarks