Link to home
Start Free TrialLog in
Avatar of Mohammad Alsolaiman
Mohammad AlsolaimanFlag for Saudi Arabia

asked on

keep a form maximized

Hi:
I have two forms opened at the same time
The one at the back is opened as normal maximized form
The one at the front is opened as a dialog
There is a button in the second form(the dialog one) , this button is to open a report, and at the same time it is make the (the dialog form) invisible.
When I close the report, I make the (dialog form) visible again.
but the first form (which is at the back) appear as restored (I mean not maximized).
I did not understand why access act like that.
What can I do to make it remain maximized?
Please.

Avatar of Scott McDaniel (EE MVE )
Scott McDaniel (EE MVE )
Flag of United States of America image

Try this in the Activate event of that form:

DoCmd.Restore

or

DoCmd.Maximize
ASKER CERTIFIED SOLUTION
Avatar of Mohammad Alsolaiman
Mohammad Alsolaiman
Flag of Saudi Arabia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Sorry I missed your comment:

you can refer to other forms like this:

Forms("YourSecondForm")

In order to maximize this other form from your dialog form, try this:

Add a code procedure to the Second form (the one you want to maximize):

Function MaximizeMe()
  DoCmd.SetFocus "nameOfSomeControlOnThisForm"
  DoCmd.Maximize
End Function

Now, from the dialog form, do this:

Forms("YourSecondForm").MaximizeMe

Avatar of Mohammad Alsolaiman

ASKER

Thank u 4 reply
I'll try it and refer back 2 u