Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Configure Buttons for macros 1

Status
Not open for further replies.

Gwynne

MIS
Sep 20, 1999
19
0
0
US
I am working in Word XP and I am creating a toolbar for a group of users. After I create a macro, I want to be able to install a button by which to use the macro. I get a bunch of icons that I can choose from, but I would like to pick ones that are not shown on the list. Does anyone know how I can use ones that I already have and not have to create new ones or use the ones that Word allows? Many thanks for all help.
 
Hi,

I have wondered about this also but decided that a different strategy was best. Users (incl moi) often loose, move, customise, hide toolbars, and therefore there is the risk of your command being lost (unless on a unique toolbar for easy recovery). I put mine in one of the dropdown menus - they are usually less 'managed' by users & therefore more stable, IMHO.

Cheers

Steve

(I'll still be watching to see a solution though!)



 
This piece of code creates non-customizable toolbar with down-arrow icon (there are hundreds in office package):
[tt]Dim tBar As CommandBar, cBtn As CommandBarButton
Set tBar = CommandBars.Add(Name:="theToolbar", Temporary:=True)
tBar.Protection = msoBarNoCustomize
Set cBtn = tBar.Controls.Add(Type:=msoControlButton, Temporary:=True)
With cBtn
.Caption = "do something"
.FaceId = 135
End With
tBar.Visible = True[/tt]

combo
 
You can also experiment with just plain old pasting an image or picture on to the button. Looks quite neat sometimes.

Des.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top