Private Sub SetWarnings(ByVal pbOn As Boolean)
Application.DisplayAlerts = pbOn 'turn off sheet compatability msg
Application.EnableEvents = pbOn
Application.ScreenUpdating = pbOn
End Sub
you can try this, but it may not stop THAT message.
usage: SetWarnings false
Code:Private Sub SetWarnings(ByVal pbOn As Boolean) Application.DisplayAlerts = pbOn 'turn off sheet compatability msg Application.EnableEvents = pbOn Application.ScreenUpdating = pbOn End Sub
I tried that but I still see the message. My work-around is to first display my own MsgBox message briefly explaining what to do before the internal Excel message appears.you can just use:
Application.DisplayAlerts = FALSE
but that error may be too severe to be ignored by the command.