Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I set a form to auto open to max size?

Status
Not open for further replies.

freedomyou

Programmer
Feb 28, 2002
8
0
0
CA
How do I set a form to automatically open to maximium viewable size?
 
Use DoCmd.Maximize in the Form Open Event.

Private Sub Form_Open(Cancel As Integer)
DoCmd.Maximize
End Sub
Terry L. Broadbent - DBA
Computing Links:
faq183-874 contains "Suggestions for Getting Quick and Appropriate Answers" to your questions in the SQL Server forum. Many of the ideas apply to all forums.
 
SOOOO cool. Man that was irritating me. Now it just pops opem at max.

THANKS

[medal]
 
A thing to remember is that one you issue the MAXIMIZE command, any other open forms and reports will also be maximized. This may or may not be an intended effect. Since a lot of my apps use invisible forms, I tend to work in this sequence:
Code:
1) Make current form Invisible.
2) Open next form.
3) Maximize it.
4) Process....
5) RESTORE current form. (Docmd.Restore)
6) CLOSE or make invisible 2nd form.
7) Re-visible first form

Following this process, the first form always reappears the same size it was before it was hidden. IF you skip step 5, Form #1 will reappear maximized.

Jim



Jim Hare
"Remember, you're unique - just like everonone else"
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top