Reputation: 3099
I tried to save without warnings
ActiveWorkbook.SaveAs Filename:= _
"C:\Users\Owner\Desktop\xxx\test.xlsx", _
ConflictResolution:=xlLocalSessionChanges
But still getting this It is already exists do you want to replace
thing
How can I save and replace without warnings ?
Upvotes: 2
Views: 3792
Reputation: 3960
Try wrapping it in an Application.DisplayAlerts = false at the start and Application.DisplayAlerts = true at the end. Something like:
Application.DisplayAlerts = False
ActiveWorkbook.SaveAs Filename:= _
"C:\Users\Owner\Desktop\xxx\test.xlsx", _
ConflictResolution:=xlLocalSessionChanges
Application.DisplayAlerts= True
http://msdn.microsoft.com/en-us/library/office/ff839782(v=office.15).aspx
Upvotes: 10