JM247L
Messages postés443Date d'inscriptionmardi 27 mars 2007StatutMembreDernière intervention 1 mars 20112 11 oct. 2007 à 12:01
Salut
C'est du VBA mais ça peut aider
Dim FC_ToolsBar As CommandBar
Dim FC_ToolsBar_FC_Treatment As CommandBarButton
Application.CommandBars.Add(Name:="Frame Contract - Tools Bar").Visible = True
CommandBars("Frame Contract - Tools Bar").Position = msoBarTop
Set FC_ToolsBar = CommandBars("Frame Contract - Tools Bar")
' Bouton
Set FC_ToolsBar_FC_Treatment = FC_ToolsBar.Controls.Add(Type:=msoControlButton, ID:=548, Before:=1)
With FC_ToolsBar_FC_Treatment
.Caption = "Etiquette Du Bouton"
.DescriptionText = ""
.Style = msoButtonIconAndWrapCaptionBelow
.OnAction = "Code A Exécuter"
End With
' Traiter le cas ou le bouton ne doit pas être actif
If 'Test' then
With FC_ToolsBar_FC_Treatment
.Enabled = False
End With
Else
Exit Sub
End If
End If