zur laufzeit menu

fazzo

Grünschnabel
hi.. hab ne kleine frage :D
ich erstelle ein menu zur laufzeit für ein addin im powerpoint mit vba..
das funktioniert so weit auch ganz gut, würde gerne aber zwischen 2 buttons
eine "Trennlinie" einfügen. Weiss jemand wie das funktioniert?:suspekt:



'' toolbar erstellen
Set CB = Application.CommandBars.Add(Name:="bsgtool", _
temporary:=True, Position:=msoBarTop)
CB.Visible = True

'' popup menu
Set CBF = CB.Controls.Add(Type:=msoControlPopup)
With CBF
.Caption = "Formatierung"
End With



'' button im menu
Set cbe = CBF.Controls.Add(Type:=msoControlButton)
With cbe
.Caption = "Aufzählungszeichen"
.OnAction = "points"
End With

Set cbe = CBF.Controls.Add(Type:=msoControlButton)
With cbe
.Caption = "Kickerbox"
.OnAction = "balkentext"
End With


'' TRENNLINIE HIER

Set cbe = CBF.Controls.Add(Type:=msoControlButton)
With cbe
.Caption = "Titel"
.OnAction = "Titel"
End With

gruss
fazzo
 
Lösung:

Set cbe = CBF.Controls.Add(Type:=msoControlButton)
With cbe
.BeginGroup = True
.Caption = "Titel"
.OnAction = "Titel"
End With

und schon hat man eine linie
 
Zurück