I need the portion of macro below to automatically save over a file that has the same name and is in the same location. Currently, an alert is created that prompts the user to save over the file.
Sheets("All Data").Select
Sheets("All Data").Copy
ChDir "R:\Location\AFile"
ActiveWorkbook.SaveAs Filename:= _
"R:\Location\AFile.xlsx", FileFormat _
:=xlOpenXMLWorkbook, CreateBackup:=False
ActiveWindow.Close
Range("A1").Select
Sheets("All Data").Select
Sheets("All Data").Copy
ChDir "R:\Location\AFile"
ActiveWorkbook.SaveAs Filename:= _
"R:\Location\AFile.xlsx", FileFormat _
:=xlOpenXMLWorkbook, CreateBackup:=False
ActiveWindow.Close
Range("A1").Select