Forum Discussion
Anonymous
4 years agoNot applicable
Power Query NOT Refreshing on Refresh All VBA
I have built a large report using purely Excel with Power Query. A lot of steps are involved in PQ and later loaded in Excel sheet the final report. I tried to automate it but Refreshing is not worki...
CNENFRNL
4 years agoCommunity Champion
Sounds wierd. It functions well on my end.
- Anonymous4 years agoNot applicable
CNENFRNL I will have a check with your code. Just a quick question, I saw your VBA code, could you clafify what I wrote in purple below?
Public Sub Workbook_Open()
Application.ScreenUpdating = False
' ActiveWorkbook.RefreshAllWith ActiveWorkbook.Connections("Query - Query1")
.Refresh
.OLEDBConnection.BackgroundQuery = bBackground //bBackground or Background only?
End With
ThisWorkbook.Save' Application.Quit
End Sub