By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,203 Members | 1,401 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,203 IT Pros & Developers. It's quick & easy.

Moving Tab Control and everything on it

P: 11
Morning all. I was hoping somone would be able to help me with some VBA program that will allow me to move the whole Tab Control on an Access form at runtime.

What I have is a form in Access 2000 that has 2 tab controls side by side, with multiple pages on each control, that looks fine on a 22inch monitor at its heigest screen resolution. Unfortunately not eveyone using this db will have a screen this size or be running at the max resolution.

I'm currently checking the screen resolution as the db starts and changing the value of the left property of my control to match that of other control and turning it invisible until needed. I.E after moving it sits behind the first tab control until a VBA process moves to it.

This all seems to work fine, my problem is that everything within the moved tab control stays where it originally was and the tab control seems to automatically stretch in width to match. I tried setting the width at the same time as moving it but this does not work.

Is it possible to move everything on a tab control to a new location in one move or would I have to move every control on every page?
Jul 24 '08 #1
Share this Question
Share on Google+
3 Replies


Expert Mod 2.5K+
P: 2,545
Hi, and welcome to Bytes. I think that the controls within the tab would need to be moved individually, as each has its own position attributes relative to the form itself. You can loop through all controls in code and reset their positions as necessary.

IIf I could comment on your approach, I think it would be fair to say that simplicity of design is a real plus point. If a form requires a 22" monitor for its display it is almost certainly too complex for most users.

I stick with the old 7 +/- 2 principle that humans can keep in mind 7 +/- 2 things simultaneously. I'm not slavish about it - if I need 12 items on a menu so be it, but in general I try to present users with simple menus, form layouts, command and radio buttons and so on that do not overwhelm with visual complexity.

Where I can't fit everything in to a form I use separate pop-up forms to overcome complexity.

Tabbed pages are a good way to structure main forms, but if you really need a 22" monitor to fit it all in it would be a reasonable guess that users will find the form overcomplex no matter to what location you move the controls.

-Stewart
Jul 27 '08 #2

missinglinq
Expert 2.5K+
P: 3,532
As usual, I agree with everything Stewart has said! It is always the best policy to design software to the lowest common denominator, which in this case means the lowest screen resolution being used by any of your users. I especially agree with him in that it sounds like you're reallly trying to cram too may things onto the screen at one time. I think you need to rethink the physical design of your app.

What you're attempting to do is probably going to take as much or more development time as the rest of your app will. There is a hack, free for downloading and using in your app, available at

http://jamiessoftware.tk/

It, like the other form scalers available, comes with the caveat that it works far better in upsizing an app than in downsizing one.

Welcome to Bytes!

Linq ;0)>
Jul 27 '08 #3

P: 11
Many thanks for your suggestions. I would also agree that simplicity is the key, however I guess I just was not thinking of that when I first started this one :)

I've used a form scaler on this once before, I had to show it on a laptop, and your right they tend not to work so well when reducing the size. I also found not all the controls would be scaled, such as the web controls on the pages and in some cases the pages themselves. So I gave that idea away.

I thought I might have to move everything, oh well, thanks anyway.
Jul 28 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.