Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Save As Macro
I have created a macro that I use weekly. The macro names and saves the
spreadsheet. Currently, when saving the spreadsheet I am asked "A file name €˜c:\filename.xls already exists in this location. Do you want to replace it?" Is there a way that I can amend the macro to automatically answer YES. ActiveWorkbook.SaveAs Filename:="c:\filename.xls", _ FileFormat:=xlNormal, Password:="", WriteResPassword:="", _ ReadOnlyRecommended:=False, CreateBackup:=False Thanks |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Save As Macro
Application.displayalerts = false
'your code to save application.displayalerts = true Max2073 wrote: I have created a macro that I use weekly. The macro names and saves the spreadsheet. Currently, when saving the spreadsheet I am asked "A file name €˜c:\filename.xls already exists in this location. Do you want to replace it?" Is there a way that I can amend the macro to automatically answer YES. ActiveWorkbook.SaveAs Filename:="c:\filename.xls", _ FileFormat:=xlNormal, Password:="", WriteResPassword:="", _ ReadOnlyRecommended:=False, CreateBackup:=False Thanks -- Dave Peterson |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Save As Macro
Hi,
Try this Application.DisplayAlerts = False ActiveWorkbook.SaveAs Filename:="c:\filename.xls", _ FileFormat:=xlNormal, Password:="", WriteResPassword:="", _ ReadOnlyRecommended:=False, CreateBackup:=False Application.DisplayAlerts = True -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Max2073" wrote: I have created a macro that I use weekly. The macro names and saves the spreadsheet. Currently, when saving the spreadsheet I am asked "A file name €˜c:\filename.xls already exists in this location. Do you want to replace it?" Is there a way that I can amend the macro to automatically answer YES. ActiveWorkbook.SaveAs Filename:="c:\filename.xls", _ FileFormat:=xlNormal, Password:="", WriteResPassword:="", _ ReadOnlyRecommended:=False, CreateBackup:=False Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
macro save | Excel Discussion (Misc queries) | |||
Macro to Insert Current Date into cell - Macro to "Save As" | Excel Worksheet Functions | |||
Macro (SAVE AS) | Excel Discussion (Misc queries) | |||
Macro to Save without the Save Message | Excel Discussion (Misc queries) | |||
Save as Macro | Excel Discussion (Misc queries) |