i try the following.
A workflow that every morning open my excel file, refreshed it, saves and close again.
What would the process look like? 🤗
Thank you in advance
Are you working in an Excel Online file?
In that case, you can have a Flow run every day "Reoccurence" and have an Excel Script refresh the data.
If you're unfamiliar with this or unsure how to do so, let me know, and I'll show you.
First ensure that your Excel file is stored in an online location (Like Drive or SharePoint). Not sure how it works with an offline Excel file. Then, I would build something like this:
The Flow triggers daily at 8:00 AM now and runs a created script (similar to Excel Macro's).
You can either record the script yourself, or paste the code below in a new script.
Both can be done via the "Automate" Tab in Excel (see highlighted below (even though in Dutch)):
After refreshing the data, the Flow will send an email to the email-address filled in.
If I have answered your question, please mark my post as a solution
If you have found my response helpful, please give it a thumbs up.
Can you see your script within Excel Online? Otherwise it might not have saved correctly.
If you have added the script with your Flow open, be sure to save the Flow, refresh the page and try again.
Thank you very much for your efforts. I managed to create.
But unfortunately I am still faced with one of the following questions / problems.
I created the workflow and I want it to run every minute.
After the workflow was successfully completed, I opened the Excel list, which is saved on my desktop, and the data has not been updated: /
Do I have to make further settings in the Excel list?
I'm unsure whether you are able to do this with a file that is stored on your desktop.
Could you try saving the Flow in SharePoint or Drive, and see if the file gets updated that way?
I am trying to accomplish the same thing. I have been working on this for days.
Here is what we have.
An excel file saved to SharePoint library:
This works fine on excel desktop - manual Refresh All works perfect, there is a setting to refresh on file open and every 30 minutes - those also work fine on desktop.
What we are trying to do is AUTOMATE the refresh all, then send the resulting refreshed excel file attached to an email. ( the flow to send the scheduled email works perfectly!)
HOWEVER; The data is NOT refreshed when fetched by the flow.
Any help would be greatly approciated.
We have the same issue. The online script will not run the refresh. I even tried adding a delay, then close> still no refresh.
As an alternative I attempted to use 'Desktop Power Automate' - and it worked, the excel file (with power queries) on sharepoint > opened> refreshed> waited> and closed.
That did not solve our requirement - only the first step.
Step 2 - need to schedule a daily email with the file attached after refresh.
To call desktop flow from online is a 'premium' license - which we don't have.
online PA - wont refresh file or open file do to query
desktop - cant run schedule email
online script - cant send email
I have been working on this also for some time and found a solution that is working for me.
In my case I have to refresh the data in one worksheet with the data in another (I haven't tried this for external data sources).
What I did was to add to the script some hide/unhide worksheet orders, leaving the document as before. However, the document refreshed. Something like this (for my document):
Hope this also works for you.
I was also trying to use Power Automate to refresh an Excel file which pulls data from a Sharepoint List. After researching and trying, my conclusion is that Enterprise license is needed. Correct me if I'm wrong.
Currently in Excel, if you click Get Data, you need Enterprise license in order to select Sharepoint List as a source, which I don't have. The way I build refresh-able connections to Sharepoint Lists is by going to the List, click the export button which downloads a query file, and open the file in Excel. This connection works fine in desktop Excel, but DOES NOT work in the web version, and I assume if you use Power Automate to refresh this connection, it will not refresh.
Seems to be a dead end for me, so I did a work around.
Since the Sharepoint List is populated by Power Automate, I made change to the Flow so that whenever an item is inserted into the List, also add a new row to the Excel file. This way the file is always up to date.
Even if the List is not populated by Power Automate, you can probably set up a Flow triggered by insertion, and add that insertion to the Excel.
I love this. Set up the script and cloud flow. My data connection is to an external Excel file. Seems that Excel for Web only allows OBdata or table/range (within same workbook). so....this won't work?
If you have a premium Power Automate license, you can Get your rows from a premium SQL action, then use this template to Update & Create all those rows in an Excel table:
And if you don’t have a premium Power Automate license, but you have an Azure account, then you can convert the flow to an Azure Logic App where SQL actions are not premium.
It takes a bit more set up than just a refresh, but it can work if the refresh doesn’t.
Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.
Learn to digitize and optimize business processes and connect all your applications to share data in real time.