I have a dashboard I am making. The goal is to query data and refresh the dashboard about every 1 minute. Basically employees are working through a continual flow of work and the dashboard needs to query data, replace the data in the dashboard, refresh the dashboard visual so the change can be seen, wait about a minute, and repeat the whole process including the query.
I have everything working EXCEPT it's looping through the iterations but not refreshing. I need this loop to stop once a cycle and display the updates. What it's doing now is looping but its frozen essentially until I press Esc. Any code that can make this loop stop for a second so it can visually display what has changed since the last loop iteration?
The dashboard is named Summary in the VBA properties.
Any Suggestions? Thanks!!!
For cycle_count = 1 To cycles
Application.ScreenUpdating = False
Summary.Range("F3").Value = cycle_count
If cycle_count > 1 Then
Application.Wait (Now + TimeValue("0:00:45"))
End If
Calculate
SQL_MR.SQL_MR
SQL_Issues.SQL_Issue_Import
If Not Application.CalculationState = xlDone Then
DoEvents
End If
Calculate
Summary_Build.service_window
Application.ScreenUpdating = True
Summary.Activate
Next