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

Popular posts from this blog

City Code Table for Casio SGW300HD-1AV Watch

How to force only 4G or LTE network connection for Samsung Galaxy Note 4

Mounting NFS share directory from D-link DNS 320L on Ubuntu 12.04 LTS