I am making a dashboard. The goal is to query data and refresh the dashboard about every minute.
Employees are working through a continual flow of work.
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 process.
It is looping through the iterations but not refreshing. I need this loop to stop once a cycle and display the updates.
It is looping but it is frozen until I press Esc.
Is there any code that can make this loop stop for a second so it can display what has changed since the last loop iteration?
The dashboard is named Summary in the VBA properties.
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