I'm using the following macro to close out error messages which occasionally pop up during data queries:

Private Sub Workbook_Activate()
On Error Resume Next
Application.DisplayAlerts = False
End Sub

Private Sub Workbook_Open()
On Error Resume Next
Application.DisplayAlerts = False
End Sub
A typical error might say "[expression.error The column of "Date" of the table wasn't found.]. Closing this error message appears to work... because I see the circling icons in the data queries indicating that the query is stuck. If I manually close out the error message, the tables will not refresh even though it looks like they are (error closes out. circles appear again briefly. looks like all is well. but its not. all of the tables have not been refreshed). So.. is there a method where the macro determines if it has been invoked... and if so, then click the "refresh all"? I know that an alternative solution is to set up another macro to "refresh all" every x minutes or so but this is not practical for my purposes. Thanks.