Forum Discussion
MichaelJSchulz
May 27, 2022Copper Contributor
Refresh All button, multiple Query Tables, and VBA
I have an Excel workbook containing multiple Query Tables. To refresh the data in all the Query Tables, I want the User to click the Refresh All button on the Ribbon. I have a block of VBA code I w...
MichaelJSchulz
May 28, 2022Copper Contributor
The Refresh All button does work. The Refresh All button does refresh the data in all the tables.
The question is how to have a block of VBA code run automatically once all the tables have finished being refreshed.
The question is how to have a block of VBA code run automatically once all the tables have finished being refreshed.
alannavarro
May 29, 2022Iron Contributor
why not use ActiveWorkbook.RefreshAll in your VBA code instead of going to Data > Refresh all?
at the end is the same result, just insert a button in which the user selects that button to run the macro.
at the end is the same result, just insert a button in which the user selects that button to run the macro.
- MichaelJSchulzMay 29, 2022Copper ContributorWhy create a button to refresh all the tables when there is already button that does that? What advantage is there to doing that?
If I did do that, how would I trigger the next block of code to run automatically once all the tables have finished being refreshed?