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.

Mohammad Alsolaimanapplication programmerAsked:
Who is Participating?
 
Mohammad Alsolaimanapplication programmerAuthor Commented:
The concentrate now is at the dialog form which is on the front
And the form at the back is restored now(not maximized).
I need a code to maximize the form at the back. But this code I need to write it in the other form(dialog form).
How can I point to (form1) from (form2) to do this maximization of (form1).
I am not sure if I describe my problem well?

0
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
Try this in the Activate event of that form:

DoCmd.Restore

or

DoCmd.Maximize
0
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
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

0
 
Mohammad Alsolaimanapplication programmerAuthor Commented:
Thank u 4 reply
I'll try it and refer back 2 u

0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.