Summary
The Office Scripts method workbook.refreshAllDataConnections() no longer refreshes a live connection to a Power BI Semantic Model in Excel Online.
Environment
- Excel Online
- Office Scripts
- Power Automate ("Recurrence" + "Run Office Script")
- Live connection to a Power BI Semantic Model (Analyze in Excel)
Expected behavior
Calling
workbook.refreshAllDataConnections();
should trigger the same refresh as manually selecting Data → Refresh All in Excel Online.
Actual behavior
The script completes successfully without any error, but the workbook does not requery the Power BI Semantic Model.
Additional observations
- The same workbook worked correctly for approximately two years.
- The issue started around mid-July 2026.
- Manual Data → Refresh All in Excel Online refreshes successfully.
- Refreshing in Excel Desktop also works correctly.
- The problem occurs both:
- when running the Office Script manually from the Automate tab in Excel Online
- when running the same Office Script from Power Automate ("Run Office Script")
This suggests the issue is specific to the Office Scripts implementation of refreshAllDataConnections() rather than the workbook, authentication, or the Power BI connection itself.
Steps to reproduce
- Create an Excel workbook with a live connection to a Power BI Semantic Model.
- Confirm that manual Data → Refresh All refreshes the data successfully.
- Create an Office Script containing only:
function main(workbook: ExcelScript.Workbook) {
// Refresh all data connections
workbook.refreshAllDataConnections();
}
- Run the script.
Result
The script finishes successfully but no refresh is performed.
Expected result
The workbook should requery the Power BI Semantic Model exactly as when using the manual Refresh All button in Excel Online.
Summary
The Office Scripts method
workbook.refreshAllDataConnections()no longer refreshes a live connection to a Power BI Semantic Model in Excel Online.Environment
Expected behavior
Calling
should trigger the same refresh as manually selecting Data → Refresh All in Excel Online.
Actual behavior
The script completes successfully without any error, but the workbook does not requery the Power BI Semantic Model.
Additional observations
This suggests the issue is specific to the Office Scripts implementation of
refreshAllDataConnections()rather than the workbook, authentication, or the Power BI connection itself.Steps to reproduce
Result
The script finishes successfully but no refresh is performed.
Expected result
The workbook should requery the Power BI Semantic Model exactly as when using the manual Refresh All button in Excel Online.