Originally Posted by
JBeaucaire
Maybe you can adapt something like this:
You rock, and that saves so much time and is so much easier!
For those trying to do the same thing as me, which is to have a semi-complex userform and pictures that work across Mac and Windows (and multiple versions of windows XL), here's some nice info:
i) Preprocessor commands (with a # symbol before them) are a handy way to make your code dynamic for a given platform, e.g.:
ii) Userforms themselves change size between Mac and Windows. This code by Ron de Bruin is very handy for that.
iii) Pictures are also resized (aspect ratio changes) between Mac and Windows. For example, a picture imported into XL in Windows will experience an aspect ratio (width/height) change of ~1.226 when the XL file is opened in Mac. Similarly, if imported into XL in Mac and opened in Windows, the change is ~/1.226, or ~0.8155. JBeaucaire's above code works great for pictures that HAVE NOT been resized after being imported into XL. For pictures that have been resized in XL after being imported, change the second argument to "False" to resize relative to current size, such as in the following code:
(I changed the height, but the same result can be achieved by scaling the width)
Thanks again!
Tim
Bookmarks