• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 257
  • Last Modified:

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.

0
Mohammad Alsolaiman
Asked:
Mohammad Alsolaiman
  • 2
  • 2
1 Solution
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
Try this in the Activate event of that form:

DoCmd.Restore

or

DoCmd.Maximize
0
 
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:
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

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now