J'ai entrepris une de vos solution, sauf que cela marche pour un menu deroulant mais pas pour le deuxième .
Un erreur dans l'écriture de la deuxième macros ?
Merci
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim i As Integer, j As Integer
j = Range('A65536').End(xlUp).Row
For i = j To 1 Step -1
If Cells(i, 6) = 'accident sans arrêt' Then
Cells(i, 6) = '1'
End If
If Cells(i, 6) = 'accident sans hospitalisation' Then
Cells(i, 6) = '2'
End If
If Cells(i, 6) = 'accident avec hospitalisation' Then
Cells(i, 6) = '3'
End If
If Cells(i, 6) = 'accident mortel' Then
Cells(i, 6) = '4'
End If
Next i
End Sub
Private Sub Worksheet_SelectionChange1(ByVal Target As Range)
Dim i As Integer, j As Integer
j = Range('A65536').End(xlUp).Row
For i = j To 1 Step -1
If Cells(i, 7) = 'Moins d'1 fois/semaine' Then
Cells(i, 7) = '1'
End If
If Cells(i, 7) = '1 fois/semaine' Then
Cells(i, 7) = '2'
End If
If Cells(i, 7) = '1 fois/jour' Then
Cells(i, 7) = '3'
End If
If Cells(i, 7) = 'Plus d'1 fois/jour' Then
Cells(i, 7) = '4'
End If
Next i
End Sub