Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Save As Function
I am trying to create code that will save a workbook based on a date in a
cell on a sheet within the workbook. I have started the code but VB doesn't like it. See below: ActiveWorkbook.Save Sheets("Schedule").Select ActiveWorkbook.SaveAs Filename:= _ "T:\Period End Schedules\Inventory Account Schedules\Inventory Obsolescence\Schedule\" & Month("A2") & "/" & Day("A2") & "/" & Year("A2") & ".xls", FileFormat:=xlNormal, Password:="", WriteResPassword:="Password", _ ReadOnlyRecommended:=False, CreateBackup:=True End Sub The problem I am having is that the code bombs at the SaveAs command. How do I get around this? -- Hlewis |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Save As Function
Hi,
a slash "/" is not a valid character in a filename. -- Greetings from Bavaria, Germany Helmut Weber, MVP WordVBA Win XP, Office 2003 "red.sys" & Chr$(64) & "t-online.de" |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
auto save function | Excel Worksheet Functions | |||
Save result of IF function | New Users to Excel | |||
Always prompted for Save with function | Excel Programming | |||
Save and Save as Function gone | Excel Programming | |||
Disable save Function | Excel Discussion (Misc queries) |