Mac VBA UserForm Font

  • Thread starter Michael R Middleton
  • Start date
M

Michael R Middleton

What font does Mac Excel X use in its dialog boxes?

Background: I'm using Win Excel 97 to develop an add-in, and I'm testing on
later versions of Mac Excel and Win Excel. When I create a user form in Win
Excel 97, the default font on my system is Tahoma Regular 8, and it looks
like the font used in Win Excel's built-in dialog boxes. When I display the
same user form in Mac Excel X, the text labels are much smaller than those
on Mac Excel X built-in dialog boxes. I know how to detect Mac vs Win, and
I'd like to use VBA code to specify an appropriate font on Mac. But I don't
know what that appropriate font is. When I insert a user form in an empty
VBA project in Mac Excel X, the default font on my system is Geneva Regular
9, which is still much smaller and different than the font used on Mac Excel
X built-in dialog boxes.

- Mike

www.mikemiddleton.com
 
P

Paul Berkowitz

What font does Mac Excel X use in its dialog boxes?
It looks like the OS X system font, Lucida Grande. The standard size,
believe it or not, is 13. VB's MsgBox looks like it's using Lucida Grande
Bold 13. Most Mac dialog messages are Lucida Grande Regular 13. "Small
System Font" is Lucida Grande Regular 11. "Label Font" is Lucida Grande
Regular 10.

You'll find Lucida Grande on every Mac OS X computer, and on no Windows
computer. It's an Apple font. (Full Unicode, by the way.)


--
Paul Berkowitz
MVP MacOffice
Entourage FAQ Page: <http://www.entourage.mvps.org/faq/index.html>
AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/>

Please "Reply To Newsgroup" to reply to this message. Emails will be
ignored.

PLEASE always state which version of Microsoft Office you are using -
**2004**, X or 2001. It's often impossible to answer your questions
otherwise.
 
M

Michael R Middleton

Paul Berkowitz -

Thanks for the information. If you have the time, please take a look at my
"Better Histogram" add-in at www.treeplan.com. The add-in's Win VBA code
uses different spacing and font size for the user form when it detects Mac.
I am interested in your feedback about whether it looks like other Mac
dialog boxes. Thanks again.

- Mike Middleton

www.mikemiddleton.com
 
P

Paul Berkowitz

Hi, Michael

The fonts look fine. The User Form does not look like an OS X dialog should,
but since I see no specifications for background color, etc. in the code,
probably that's what Office User Forms look like. (It has a tell-tale boxy
Windows look. You'd never catch that on the Mac.) I'm just a visitor here
and have never worked with Excel user forms - JE and Jim would know. I once
tried a user form in an older version of Word - may have been way back on OS
9.

The widgets aren't right (the collapse arrow thingy is almost invisible) and
there's a wide gap at the left of all the text boxes before the cursor - it
looks like something is wrong. To get user forms looking right on the Mac
you have to adapt them there. The resolution is different: 72 ppi vs. 96 on
Windows, so vertical/horizontal relationships are different too.

It's perfectly functional, and works OK, but to look really good you'd need
to try it out on a Mac yourself and make adjusts in your conditional

Private Sub UserForm_Initialize()
If Not Application.OperatingSystem Like "*Win*" Then


code.


--
Paul Berkowitz
MVP MacOffice
Entourage FAQ Page: <http://www.entourage.mvps.org/faq/index.html>
AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/>

Please "Reply To Newsgroup" to reply to this message. Emails will be
ignored.

PLEASE always state which version of Microsoft Office you are using -
**2004**, X or 2001. It's often impossible to answer your questions
otherwise.
 

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