Sub Essa()
Dim Ligne1 As Long, ligne2 As Long, Ligne3 As Long, ligne4 As Long
ligne2 = Sheets("Donnees").Columns(16).Find("*", , , , xlByColumns, xlPrevious).Row
Ligne1 = Sheets("Nicoll").Columns(3).Find("*", , , , xlByColumns, xlPrevious).Row
Ligne3 = Sheets("Nicoll").Columns(21).Find("*", , , , xlByColumns, xlPrevious).Row
ligne4 = Sheets("Nicoll").Columns(10).Find("*", , , , xlByColumns, xlPrevious).Row
For n = 1 To ligne2
For m = 1 To Ligne1
For p = 1 To Ligne3
For q = 1 To ligne4
If p > q And Sheets("Donnees").Range("P" & n) = Sheets("Nicoll").Range("C" & m) Then
Sheets("Donnees").Range("AE" & n) = Sheets("Nicoll").Range("U" & m)
Elself p < q And Sheets("Donnees").Range("P" & n) = Sheets("Nicoll").Range("C" & m) Then
Sheets("Donnees").Range("AE" & n) = Sheets("Nicoll").Range("R" & m)
End If
Next
Next
Next
Next
End Sub