Sub ReproValCoul()
Dim i As Long, j As Long, i1 As Long, j1 As Long
With Sheets("S2").UsedRange
.Offset(1, 1).Clear
For i = 2 To .Rows.Count
For j = 2 To .Columns.Count
If .Cells(i, 1).Value <> "" And .Cells(1, j).Value <> "" Then
If Application.CountIf(Sheets("a").Range("A1:IV1"), .Cells(i, 1).Value) > 0 And _
Application.CountIf(Sheets("a").Range("A1:A65536"), CLng(.Cells(1, j).Value)) > 0 Then
i1 = Application.Match(CLng(.Cells(1, j).Value), Sheets("a").Range("A1:A65536"), 0)
j1 = Application.Match(.Cells(i, 1).Value, Sheets("a").Range("A1:IV1"), 0)
Sheets("a").Cells(i1, j1).Copy .Cells(i, j)
End If
End If
Next j
Next i
Application.CutCopyMode = False
End With
End Sub