问题
Is there a way to auto refresh a form by time? I'm creating an status board to display the current RMA status on a big screen for manufacturing. Is there a way to refresh this data every 10 seconds or so? Thanks in advance for any assistance. Tony
回答1:
Yes, there is. Just set the Timer interval property on the form, and use the Form_Timer event.
Add the following code to auto-refresh on the timer.
Private Sub Form_Timer()
Me.Requery
End Sub
Note that the timer interval is in milliseconds, so 10 seconds = 10000. Also note that it causes a noticable "blink", and can reset the field you're currently focusing on.
来源:https://stackoverflow.com/questions/45547939/auto-refresh-form-in-access-2017