Scale Userform and Change Color Scheme

allenpierce

New Member
Joined
Dec 23, 2013
Messages
13
I'm developing an application on a Macbook air that will run mostly on PCs. I have two questions:

1. I need to write a routine which scales the UserForm for screen resolution, as most of the PC users I work with use a lower screen resolution than what I use on my Mac. I've seen sample code which interrogates the system for screen resolution. Trouble is, I don't know in which modules to put the various parts of the user code I see listed on various forums (i.e. variable declarations, subroutines, functions). Big picture, I think that with the current (user) screen resolution and the base resolution of my screen when I set up the UserForm, I can change the zoom factor of the UserForm and then change the width and height of the UserForm by the same percentage. Any specific code recommendations would be greatly appreciated. Please be specific as to where to put the various portions of the code.

2. The colors of the UserForm I developed on my Mac are great. When I run the same code on a PC, several of the colors are terrible. In particular, the background color on the UserForm itself as well as the color of the command buttons are terrible. What code can I put in the UserForm, probably in the initialize subroutine, to change the color scheme to something appropriate for each user? This code needs to work on both a PC and a Mac.

Thanks in advance for any help!
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.

Forum statistics

Threads
1,214,394
Messages
6,119,263
Members
448,881
Latest member
Faxgirl

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top