Private Sub OptionButton1_Click()
Afficher 1
End Sub
Private Sub OptionButton2_Click()
Afficher 2
End Sub
Private Sub OptionButton3_Click()
Afficher 3
End Sub
Private Sub Afficher(op As Byte)
Dim plage As Range, cel As Range, affich As Range
Application.ScreenUpdating = False
Rows.Hidden = False 'affiche tout [indispensable pour End(xlUp)]
Set plage = Range("A8", Range("A65536").End(xlUp))
For Each cel In plage
If cel = "a" Or (op > 1) * (cel = "b") Or (op = 3) * (cel = "c") Then _
Set affich = Union(IIf(affich Is Nothing, cel, affich), cel)
Next
plage.EntireRow.Hidden = True 'masque tout
If Not affich Is Nothing Then affich.EntireRow.Hidden = False 'affiche
End Sub