Que voulez-vous dire par exécuter ? Il n'y a rien à faire d'autre que cliquer...Ah j'oubliai de remercier Job et Phlaurent pour votre intervention, mais malheureusement je peux ouvrir votre fichier mais ne peut exécuter votre VBA
Ben si, sur mon fichier (2) post #11 j'utilise la macro Private Sub Label1_Click(), cliquer sur un objet c'est basique...Mais il n'existe pas de simple clic.
Option Explicit
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Rows.Count * Target.Columns.Count > 1 Then Exit Sub
If Intersect(Me.[A1:C10], Target) Is Nothing Then Exit Sub
Target.Value = Choose(Target.Value Mod 3 + 1, 1, 2, Empty)
Application.EnableEvents = False
Me.[A1].Select
Application.EnableEvents = True
End Sub
Option Explicit
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Rows.Count > 1 Or Target.Columns.Count > 1 Then Exit Sub
If Intersect(Me.[A1:C10], Target) Is Nothing Then Exit Sub
Target.Value = 1
End Sub
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
If Target.Rows.Count * Target.Columns.Count > 1 Then Exit Sub
If Intersect(Me.[A1:C10], Target) Is Nothing Then Exit Sub
Target.Value = 2: Cancel = True
End Sub
Private Sub Worksheet_BeforeRightClick(ByVal Target As Range, Cancel As Boolean)
If Target.Rows.Count * Target.Columns.Count > 1 Then Exit Sub
If Intersect(Me.[A1:C10], Target) Is Nothing Then Exit Sub
Target.Value = Empty: Cancel = True
End Sub
If Intersect(Target, [G10:BD16,G21:BD27]) Is Nothing Or Target.CountLarge > 1 Then Label1.Visible = False: Exit Sub