Commandbar shows vertically instead of horizontally

C

Charles Chung

I need to write some marcos in a excel file that need to be
cross-platform compatible.

I have this VBA code:
CommandBars.Add "PurchaseOrder", msoBarTop

The problem is the commandbar shows vertically instead of horizontally
in Mac Excel 2004, but it shows properly in Office XP!

Do anyone knows why is that?

Thanks you!

Charles Chung
 
J

JE McGimpsey

The problem is the commandbar shows vertically instead of horizontally
in Mac Excel 2004, but it shows properly in Office XP!

Do anyone knows why is that?

I can't reproduce that - the new commandbar is horizontal when I perform
the .Add method.

Try, with XL closed, renaming or deleting the

~:Library:preferences:Microsoft:Excel Toolbars (11)

file.
 
J

Jim Gordon MVP

Hi Charles,

You need to specify more parameters to make sure the commandbar comes
out horizontal. Here's a snippet of code I use for one of my commandbars:

MyBar.Position = msoBarTop
With MyBar
.Height = 31
.Width = 175
.Top = 90
.Left = 225
.Visible = True
End With

-Jim
 

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