How to save file and automatically overwrite an existing file without prompt in VBA macro

This is how to run the FileSaveAs command in VBA macro which is commonly used in Ms Excel or Ms Project without having the application prompt for overwriting and existing file.

The idea is to temporarily setting the object "Application.DisplaysAlerts" to false and then set it back to true after the file save.

Example:

Application.DisplayAlerts = False
FileSaveAs command
Application.DisplayAlerts = True


Comments

Post a Comment

Thank you for visiting Almost a Technocrat. Due to many spam comments, your comment will be moderated.

Popular posts from this blog

How to recalibrate your Samsung Note 4 battery

How to import Tasker projects, profiles, tasks and scenes

How to turn your Windows 7 laptop or dekstop into a WiFi repeater or extender

A Better SKMEI 1358 Instructions Manual