1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
| Sub test()
Dim Plage As Range
Dim C As Range
Dim derligE As Long
Dim derligJ As Long
Dim F As Worksheet
Set F = Sheets("Feuil1")
derligE = F.Range("E" & Rows.Count).End(xlUp).Row
derligJ = F.Range("J" & Rows.Count).End(xlUp).Row
Set Plage = F.Range("J2:J" & derligJ)
For i = 2 To derligE
Set C = Plage.Find(F.Cells(i, "E"), LookIn:=xlValues, lookat:=xlWhole)
If Not C Is Nothing Then
F.Cells(i, "L") = F.Cells(C.Row, "B")
F.Cells(i, "M") = F.Cells(C.Row, "C")
F.Cells(i, "N") = F.Cells(C.Row, "D")
end if
Next i
End Sub |
Partager