Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub AddMenuIcon()
With Application.CommandBars("Standard").Controls.Add( _ Type:=msoControlButton, _ ID:=2950, Befo=9) .OnAction = "myMacro" End With End Sub -- --- HTH Bob (change the xxxx to gmail if mailing direct) "Richard" wrote in message ... Hello, This is second time that I'm posting it. Hope someone can help me with this. I want to assign a macro( Userform1.show) to icon that I add in for command bar. I use the below code to add smiley icon on command bar and I want to use code to assign a macro. Sub AddMenuIcon() Application.CommandBars("Standard").Controls.Add Type:=msoControlButton, ID _ :=2950, Befo=9 ???????? <<== Here I want to code to assign macro so that if user click this amiley button, the userform can be poped up. End Sub Any help will be appreciated. Thanks |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Finding a single word match in a text string and assigning a code | Excel Worksheet Functions | |||
Urgent - Pl help code for assigning a shape to cells | Excel Programming | |||
Creating Buttons and assigning code | Excel Programming | |||
Assigning VBA code to a Toolbar | Excel Programming | |||
Assigning Selected Cells to Code | Excel Programming |