Sub TirageSansDoublon()
Dim TNoms(), TRés(), M&, L&, C&, J&, TClub(0 To 0), TMarg(0 To 0)
With Feuil2.Sort
.SortFields.Clear
.SortFields.Add Key:=Range("C2:C193"), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:=xlSortNormal
.SortFields.Add Key:=Range("B2:B193"), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:=xlSortNormal
.SetRange Range("A1:C193")
.Header = xlYes
.MatchCase = False
.Orientation = xlTopToBottom
.SortMethod = xlPinYin
.Apply
End With
TNoms = Feuil2.[B2].Resize(Feuil2.[C195].End(xlUp).Row - 1).Value
If Tirage33OK(UBound(TNoms, 1), 3, TClub, TMarg) Then
For M = 1 To UBound(Tirage, 1)
ReDim TRés(1 To 30, 1 To 2)
For L = 1 To UBound(Tirage, 2)
For C = 1 To 6
J = Tirage(M, L, C)
If J > 0 Then TRés(L * 3 + (C - 1) Mod 3 - 2, (C - 1) \ 3 + 1) = TNoms(J, 1)
Next C, L
ThisWorkbook.Worksheets("Partie " & M).[A3:B32].Value = TRés
Next M: End If
End Sub