how to save a file and overwrite existing file

D

Daniel M

I have a macro where i want to save a file but there is an existing file with
that name already. how can i keep the dialog box from popping up and asking
if i want to save it. i have tried the following code but it doesnt work.
Thanks.

ActiveWorkbook.SaveAs Filename:= _
"\\Houston\manfdocs\Macros\RepairImporttest.xls", FileFormat _
:=xlNormal, Password:="", WriteResPassword:="",
ReadOnlyRecommended:= _
False, CreateBackup:=False, AccessMode:=xlNoChange,
ConflictResolution:=xlLocalSessionChanges
 
D

dbKemp

I have a macro where i want to save a file but there is an existing file with
that name already. how can i keep the dialog box from popping up and asking
if i want to save it. i have tried the following code but it doesnt work.
Thanks.

ActiveWorkbook.SaveAs Filename:= _
"\\Houston\manfdocs\Macros\RepairImporttest.xls", FileFormat _
:=xlNormal, Password:="", WriteResPassword:="",
ReadOnlyRecommended:= _
False, CreateBackup:=False, AccessMode:=xlNoChange,
ConflictResolution:=xlLocalSessionChanges

Does Application.DisplayAlerts = False help? Don't forget to turn it
back on.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top