Sub Symbolleiste_erweitern()
Call Symbol_löschen
Set CB = Application.CommandBars("Formatting"). _
Controls.Add(msoControlButton)
With CB
.Caption = "Befehl"
.FaceId = 66
.OnAction = "MachWas"
.Visible = True
End With
End Sub
Sub Symbol_löschen()
On Error Resume Next
Application.CommandBars("Formatting"). _
Controls("Befehl").Delete
End Sub
Sub MachWas()
MsgBox "Hallo, da bin ich !"
End Sub
|