Upon opening a database, I would like for a form to be automatically
maximised so that it covers the whole workspace.
How do I autorun this on opening the database? I know I need the do.cmd, but
what would be the complete code and how do I insert this?
Thanks.
PS: The form is called, frmMain
Rick Brandt - 06 May 2005 14:14 GMT
> Upon opening a database, I would like for a form to be automatically
> maximised so that it covers the whole workspace.
>
> How do I autorun this on opening the database? I know I need the
> do.cmd, but what would be the complete code and how do I insert this?
In the Open Event of the form...
DoCmd.Maximize
In Tools - Startup you can specify which form you want to automatically open
when the file is opened.

Signature
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Neil Greenough - 06 May 2005 14:29 GMT
Many thanks Rick
- All works great!
Van T. Dinh - 06 May 2005 14:26 GMT
I nomally use the Form_Activate Event to run the code:
DoCmd.Maximize

Signature
HTH
Van T. Dinh
MVP (Access)
> Upon opening a database, I would like for a form to be automatically
> maximised so that it covers the whole workspace.
[quoted text clipped - 5 lines]
>
> PS: The form is called, frmMain