Bonjour,
voici la modification,
j'ai délimité la plage de recherche avec la variable joute et joutesuivante
Function adversaire(joute As String, team As String, FeuilSource As String)
Dim x1 As Long, x2 As Long, x As Integer
Dim c As Range, plg As Range, sh, n As Long, joutesuivante As String
Set sh = Sheets(Left(FeuilSource, Len(FeuilSource) - 1))
n = sh.Cells(Rows.Count, 1).End(xlUp).Row
joutesuivante = "J" & CDbl(Right(joute, Len(joute) - 1) + 1)
x1 = Application.Match(joute, sh.Range("A:A"), 0)
x2 = Application.Match(joutesuivante, sh.Range("A:A"), 0) - 2
Set plg = sh.Range("B" & x1 & ":C" & x2)
For Each c In plg
If c = team Then
Select Case c.Column
Case 2: adversaire = sh.Cells(c.Row, 3)
Case 3: adversaire = sh.Cells(c.Row, 2)
End Select
End If
Next
End Function