VBA toolbars

F

Francis Hookham

Office 2004 VBA

On opening only Standard toolbar is in view ­ I have not found how to
default to all toolbars on view

Better still, how about a custom toolbar with only the buttons I normally
need, as in XL 2000 - or didn¹t Bill think Mac users needed it as much as PC
users?

Francis Hookham
 
B

Bob Greenblatt

Office 2004 VBA

On opening only Standard toolbar is in view ­ I have not found how to default
to all toolbars on view

Better still, how about a custom toolbar with only the buttons I normally
need, as in XL 2000 - or didn¹t Bill think Mac users needed it as much as PC
users?

Francis Hookham

Unfortunately, that¹s the way it works. There are no options to change the
configuration. If you¹d like a different toolbar configuration, you¹ll have
to develop a custom macro to build it for you and display it when the VBE is
active.
 
J

JE McGimpsey

Francis Hookham said:
On opening only Standard toolbar is in view ­ I have not found how to
default to all toolbars on view

There's no preferences that you can set to do that.

However, you can include code to make them visible in a startup add-in.
Better still, how about a custom toolbar with only the buttons I normally
need, as in XL 2000 -

That's what I do, building it in my startup add-in.
or didnt Bill think Mac users needed it as much as PC users?

Don't blame it on Bill - it was MacBU's decision.

Back before Office 98, their research indicated that Mac users wouldn't
pay the extra hundreds of dollars per copy of MacOffice in order to
implement a VBE similar to WinOffice, nor would they accept the
additional months/years required to implement it. Because of the
platform differences, what we got was still a kludge. It's only become
more uneconomical since, as WinOffice has gone to VBA6 and the cost to
implement something like the current WinOffice VBE would be prohibitive.

And in fact, Mac users *DON'T* need it as much as PC users. The amount
of VBA development that occurs on the Mac is miniscule in comparison to
that produced by WinOffice developers, even when adjusted for market
share.
 
B

Bernard Rey

Francis Hookham a écrit :
On opening only Standard toolbar is in view ­ I have not found how to
default to all toolbars on view

Better still, how about a custom toolbar with only the buttons I normally
need, as in XL 2000 - or didn¹t Bill think Mac users needed it as much as PC
users?

There is a workaround, borrowed from JE McGimpsey that does fit the bars
where I like to have them. You can copy the following lines in a macro
module of your "Personal Macros Workbook"

----------------------------------------------------
Public Sub SetUpVBEToolbars()
Const LEFTPOS = 752 ' these are my settings
Const TOPPOS = 21 ' adapt them to your needs
Const ROWNDX = 2

With Application.VBE
'With .CommandBars("Edit") ' Edition
' .Visible = True
'End With
With .CommandBars("Debug") ' Débogage
.Position = msoBarTop
.RowIndex = ROWNDX
.Left = LEFTPOS
.Top = TOPPOS
.Visible = True
.Protection = msoBarNoMove
End With
.Windows("Properties").Visible = True
End With
End Sub
----------------------------------------------------


In order to have it automatically launched on statup, put these lines in the
ThisWorkbook code sheet of the "Personal Macros Workbook":


----------------------------------------------------
Private Sub Workbook_Open()
SetUpVBEToolbars
End Sub
----------------------------------------------------

That way, when your personal macros Workbook is automatically opened on
Excel startup, the bars will be placed where you'd like to have them.
Unfortunaltely, there's no way (that I know) to customize these bars.

The Mac VB Editor is certainly much "simpler" than its Windows equivalent...
The Mac User is usually supposed not to use VBA that much and/or to be a
rather good AppleScripter if he wants to automate things :-/
 
F

Francis Hookham

Thank you for this below - I have included the Edit toolbar

Can I add to the code so the Properties window does not open?

Even better, can the Projects window be moved to a position to the right of
the screen? Of course I realise I should have to experiment with x-y dims

Francis Hookham
 

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