change form height at runtime

M

moondaddy

I need to dynamically change the height of a form and its detail section at
runtime. How can I do this? I could change the detail section's height,
but the form's height wont change.
 
G

Gary Miller

Check out the MoveSize method in Help. It will move and
resize the active window.

Gary Miller
Sisters, OR
 
M

Marshall Barton

moondaddy said:
I need to dynamically change the height of a form and its detail section at
runtime. How can I do this? I could change the detail section's height,
but the form's height wont change.


If you set the form's InsideHeight property, the form will
resize with the detail section getting whatever space is
left over from the form's Header and Footer sections.
Assuming you do have a header and footer, and given that you
know what size you want the detail to be:

Me.InsideHeight = newdetailheight + Me.Section(1).Height +
Me.Section(2).Height

If you don't have a header or footer, just leave out the
corresponding Section term in that expression.
 

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

Top