Programme macros excel pour activer/désactiver un bouton
Haitam_mhamdi
Messages postés
15
Statut
Membre
-
Haitam_mhamdi Messages postés 15 Statut Membre -
Haitam_mhamdi Messages postés 15 Statut Membre -
Bonjour,
SVP je veux le programme macros pour activer/désactiver un bouton et merci !
SVP je veux le programme macros pour activer/désactiver un bouton et merci !
2 réponses
-
Bonjour
Tes boutons doivent être pris dans les contrôles ActiveX (boite à outils contrôles et non formulaires)
Ici un clic sur le bouton 1 change le statut (actif/Inactif) du bouton 2
Private Sub CommandButton1_Click()
CommandButton2.Enabled = Not CommandButton2.Enabled
End Sub
http://www.cjoint.com/c/GGeq40AsiXB
Cdlmnt-
voila le code je c'est pas comment faire les conditon pour relié c'est programe.
Sub Macro11() >>>>>>verrouiller >>>>>>>>>>>>>>>>>>>>>>>>>>>>> ActiveSheet.Protect DrawingObjects:=False, Contents:=True, Scenarios:= _ False, AllowFormattingCells:=True, AllowFormattingColumns:=True, _ AllowFormattingRows:=True, AllowInsertingColumns:=True, AllowInsertingRows _ :=True, AllowInsertingHyperlinks:=True, AllowDeletingColumns:=True, _ AllowDeletingRows:=True, AllowSorting:=True, AllowFiltering:=True, _ AllowUsingPivotTables:=True, Password:=2344 >>>>>>>Deverrouiller >>>>>>>>>>>>>>>>>>>>>>>>>>>> ActiveSheet.Unprotect >>>>>>> pour que les cellule reste actif >>>>>>>>>>>>>>>> Range("K:K,L:L,M:M,N:N,O:O").Select Range("O1").Activate Selection.Locked = False Selection.FormulaHidden = False End Sub
-
-