Hi, in Access 97 I have a form with progress bars. I want to open the form
and then automatically run code.
How do I have the form open and all the controls visible before running the
code (and not require a user to click a button)?
Using the OnOpen and OnLoad events trigger the code before displaying the
form.
Many thanks
Jonathan
Technique that I have used for this:
Private Sub Form_Open(Cancel As Integer)
Me.TimerInterval = 1
End Sub
Private Sub Form_Timer()
Me.TimerInterval = 0
Your automatic code here
End Sub
This allows the form to open but needs a very fast user to get in before the
code runs!
If you want to update the form from your code I have found that
Me.Repaint
is needed to get the update displayed.
HTH
John
> Hi, in Access 97 I have a form with progress bars. I want to open the form
> and then automatically run code.
> How do I have the form open and all the controls visible before running the
> code (and not require a user to click a button)?
> Using the OnOpen and OnLoad events trigger the code before displaying the
> form.
Jonathan - 12 Dec 2005 21:05 GMT
Thanks John, your suggestion works well....
Cheers
Jonathan
> Technique that I have used for this:
>
[quoted text clipped - 23 lines]
> > Using the OnOpen and OnLoad events trigger the code before displaying the
> > form.