G
Gary
I have created a toolbar with the following code:
Set cbars = Application.CommandBars
Set cbar = cbars.Add(Name:="XYJ", Position:=msoBarTop, Temporary:=True)
Set cbButton1 = cbar.Controls.Add(Type:=msoControlButton)
With cbButton1
.Caption = " Skill "
.TooltipText = "Click for Skill"
.Tag = "cbbVBAMacro"
.Style = msoButtonCaption
.OnAction = "ThisDocument.SkillLayerActive"
End With
I wish to change the caption from skill to SKILL in the onAction routine.
I don't know how to reference the caption in the cbButton1. Can someone
help!!
Thanks,
Set cbars = Application.CommandBars
Set cbar = cbars.Add(Name:="XYJ", Position:=msoBarTop, Temporary:=True)
Set cbButton1 = cbar.Controls.Add(Type:=msoControlButton)
With cbButton1
.Caption = " Skill "
.TooltipText = "Click for Skill"
.Tag = "cbbVBAMacro"
.Style = msoButtonCaption
.OnAction = "ThisDocument.SkillLayerActive"
End With
I wish to change the caption from skill to SKILL in the onAction routine.
I don't know how to reference the caption in the cbButton1. Can someone
help!!
Thanks,