Update a power query in excel with varying process times

Hi there
I’m trying to automate opening an excel file containing a power query to update. Once refreshed, I want to save the excel file and close it.

Studio does a great job at this when it comes to PivotTables. However, the process does not apply to power queries.

I’ve tried using Send HotKey (Ctrl+Alt+F5) → it starts the refresh, but it’s impossible for me to predict the time it will take to refresh all… it can vary from 2 mintes to 35 minutes!!

I’ve tried running a macro using Refresh and Save commands. But the save seems to attempt before the refresh is completed.

I thought this would be simple to accomplish but getting increasingly frustrated with options.

Any ideas on how this can be accomplished?