CONTROL FORM SIZE

S

Sammie

I'm having trouble controling the size of a dialog box. I set border
style to sizeable, adjust the size in design view, preview to check,
and then switch back to border style: dialog and save the form. Looks
good at this point. Now when I open up my form via a command button on
my main form, the dialog box is maximized. When I retore the dialog box
window to the proper size, it restores all of my open forms (not desirable).

I tried adding the acDialog statement to my command button on the main
form, but then it won't let me search any of the fields on the form.

What is the secret? It's driving me crazy.
Thanks!
 
R

Rick Brandt

Sammie said:
I'm having trouble controling the size of a dialog box. I set border
style to sizeable, adjust the size in design view, preview to check,
and then switch back to border style: dialog and save the form. Looks
good at this point. Now when I open up my form via a command button
on my main form, the dialog box is maximized. When I retore the dialog
box window to the proper size, it restores all of my open forms (not
desirable).
I tried adding the acDialog statement to my command button on the main
form, but then it won't let me search any of the fields on the form.

What is the secret? It's driving me crazy.
Thanks!

In Access if you maximize one object you maximize ALL objects. The
exception being dialog or popup forms. If you set your second form's Popup
property to True that should prevent it from maximizing.
 
A

Albert D. Kallal

What is the secret? It's driving me crazy.

here it is (really!!!).

I explined the below simply steps to many people..and they loved it!!!

----------------------

I would set the forms "auto center" property to yes.
I would set the forms "auto re-size" property to NO

Now, size the form exactly the way you want, and then
save the form (use ctrl-s to save the form).

Now, flip the form into design mode, and change the
border style to "thin". Flip back...ctrl-s.

This means that you, or your users will NOT be able
to change the form size unless it is in desing mode
(as a general rule..that is how I design
ALL my forms anyway).

So, really, to control this max/min issue, and cntorl the size, you

.. you don't need any code...but you
do have to pay attention to the forms settings.


If you don't want you, or users to min/max the forms, then you can remove
this option in the forms properties setting. Just change the min/max Buttons
setting to "none". If the this "min/max buttons" form setting is none, then
even if a form on top is maxed, when you return to the previous form, it
will NOT be maxed since the min/max buttons setting is gone!

do the above...and forms will stay EXACTLY how you design them..and you
save yourself some frazzled nerves...
 
R

Rick Brandt

Albert said:
here it is (really!!!).

I explined the below simply steps to many people..and they loved it!!!

Albert, just curious... Why Auto-Resize to NO? Why not just set the form
sections so that Auto-Resize produces the size window you want? I
understand that this doesn't apply to a continuous form, but for a single
view form wouldn't it be better not to rely on a "saved" window size that
could get accidentally changed?
 
A

Albert D. Kallal

Albert, just curious... Why Auto-Resize to NO? Why not just set the form
sections so that Auto-Resize produces the size window you want?

We are assuming (well, ok I am assuming!!) that the developer wants to build
a form, and NOT have the size change from what was designed. if you leave
auto-resize on, then that form size can change when you launch it. We don't
want ANY thing changed on that form once we finished our work. With the
border style set to thin, then end uses can't accident change the form size.
wouldn't it be better not to rely on a "saved" window size that could get
accidentally changed?

My suggest actually prevents the user from being able to change the
form size, and *father* by setting auto-resize to no, then the
form design will not have tabs, or any other part of the form
accidentally go out of view. With auto-resize, ms-access can
change the form size slightly when launched. I want my forms
to stay EXACTLY how I designed them. And, I want those
forms sized EXACTLY how I built them.

I suppose it depends on the application. But, for the most part
when I design an app...users don't even know it is ms-access,
and further, I don't want them changing form sizes.....

Also, that tip allows ones to see how the final form will look, since
flipping from design mode to final mode often results in a slightly
different size (and the developer gets frustrated ..since they seemed
to have sized a form..but, it keeps changing when they flip into
view mode...my tip solves this frustrating problem for those
budding developers).
 
R

Rick Brandt

Albert said:
We are assuming (well, ok I am assuming!!) that the developer wants
to build a form, and NOT have the size change from what was designed.
if you leave auto-resize on, then that form size can change when you
launch it.

But only if you have the size of the form sections such that they do not
produce the desired sized window in the first place.
We don't want ANY thing changed on that form once we
finished our work. With the border style set to thin, then end uses
can't accident change the form size.

That is true whether auto-resize is true or not.
My suggest actually prevents the user from being able to change the
form size, and *father* by setting auto-resize to no, then the
form design will not have tabs, or any other part of the form
accidentally go out of view. With auto-resize, ms-access can
change the form size slightly when launched. I want my forms
to stay EXACTLY how I designed them. And, I want those
forms sized EXACTLY how I built them.

Again, the auto-resize would only do those things if the sections weren't
sized correctly in the ifrst place.
I suppose it depends on the application. But, for the most part
when I design an app...users don't even know it is ms-access,
and further, I don't want them changing form sizes.....

Agreed, but that is accomplished with the thin border style.
Also, that tip allows ones to see how the final form will look, since
flipping from design mode to final mode often results in a slightly
different size (and the developer gets frustrated ..since they seemed
to have sized a form..but, it keeps changing when they flip into
view mode...my tip solves this frustrating problem for those
budding developers).

For me it would be exactly the opposite. I want to make the window size
whatever I want in design view, save whenever I want, and know that when the
form is opened under normal use that the window size will revert to exactly
that required by the structure of the form sections. I only set and save
the window in normal view for continuous forms where Auto-Resize can't
determine what the desired height should be.
 
A

Albert D. Kallal

For me it would be exactly the opposite. I want to make the window size
whatever I want in design view, save whenever I want, and know that when
the form is opened under normal use that the window size will revert to
exactly that required by the structure of the form sections. I only set
and save the window in normal view for continuous forms where Auto-Resize
can't determine what the desired height should be.

That is interesting approach. I beginning to think that I had a badly sized
form,
and whacked it on the head by setting auto-resize no, when in fact I
should have sized the form correctly.....

Some where along the way, that auto re-size setting was causing
me trouble..and thus I not had it enabled for about 5 years now..

can't even remember the last time using it...

I much suspect (and appreciate) that your comments seem
to suggest a better approach here....
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

CONTROL DIALOG BOX SIZE 1
Form Height 4
Resize main form and subform? 6
Dialog form opens wrong 4
Form size 1
Form Size 2
Disable Button on Opening Form 1
Split form size 6

Top