Change size of form based on client data

The client database I am working on has a form that, based on the age of the client, shows an aging infor subform on it.  It is located to the right of all the other data and in a big blank space.  However, all the primary data is on the left of the form and the aging information only applies to a small portion and this form is not visible if the client is not int his category.  But it makes for a big empty space on the right.  I am trying to figure out how, in VBA, to make the form smaller unless the client is in the aging category and then show the full form with this subform.  But when I try to make the form small in code, it still opens full size.  Can this even be done if this form is on the right side and even with code I cannot make the main form thinner?
Sandra SmithRetiredAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Jeffrey CoachmanMIS LiasonCommented:
I try to avoid forms that "Change Size" dynamically.
To much work, IMHO, to calculate how much area to show...
So we can see if another expert chimes in with a solution to your Q, as stated.

At the simple end, I would simply let the user scroll down to see more info.
At the more complex end, I would allow them to resize the form as they like.
At another end, you could simply open up a separate pop-up form to display this additional info and not try to fit it all on one form.

JeffCoachman
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Sandra SmithRetiredAuthor Commented:
Popup works for me.  It is such a small population that not worth the effort to resize.  Thanks for confirming my initial thoughts.

Sandra
0
Dale FyeCommented:
I do occassionally size the form based on record status, but find that users will center the form (if they can) and then when they encounter an "aging" patient, making the subform visible and resizing the forms width to fit the now visible subform is problematic.

Jeff has forgotten the "middle" method, which is to simply put a tab control on the form and put the "Aging" controls on the "Aging" tab.

Then, you use the Form_Current event to hide or reveal that tab if the client meets the "aging" criteria.

Dale
0
Jeffrey CoachmanMIS LiasonCommented:
ssmith94015
Hey, you did not have to accept any post so fast.

I merely stated my opinion.

As I said, you could have waited for another expert to answer your Q as stated, ...or like Dale, ...propose another alternative.

;-)

Jeff
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.

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.