Hello,
I have made sql which refresh all data, when excel document open. I have written such code :
Private Sub Worksheet_Activate()
ThisWorkbook.RefreshAll
End Sub
But i need that document will be closed automatically after it finish update data. (refresh all data takes about 12 minutes). Maybe somebody have any suggestion ?
Or maybe where are possibility to refresh data just one time per 24 hours, when open document ?
I have made sql which refresh all data, when excel document open. I have written such code :
Private Sub Worksheet_Activate()
ThisWorkbook.RefreshAll
End Sub
But i need that document will be closed automatically after it finish update data. (refresh all data takes about 12 minutes). Maybe somebody have any suggestion ?
Or maybe where are possibility to refresh data just one time per 24 hours, when open document ?