Option Explicit
Sub SupprDoubEtTri() 'Exemple de Jacques Boisgontier
Dim Mondico As Object, Wks As Worksheet
Dim PlageJ As Variant, x As Long, Lig As Long
Dim c, cel, ColA, Plage As Range,
Set Wks = Sheets(1)
Set Mondico = CreateObject("Scripting.Dictionary")
PlageJ = Range(Wks.[j3], Wks.[j65000].End(xlUp)).Value
For Each c In PlageJ
Mondico(c) = ""
Next c
Set ColA = Wks.Range("a3")
ColA.Resize(Mondico.Count, 1) = Application.Transpose(Mondico.Keys)
ColA.Resize(Mondico.Count, 1).Sort Key1:=ColA, Order1:=xlAscending
Set Mondico = Nothing
With Wks 'Et j'ai rajouté ceci
Lig = .Range("a" & Rows.Count).End(xlUp).Row
If .Range("a" & Lig).Value <> "" Then
Set plage = .Range("j3:k" & Lig)
For x = 3 To Lig
Set cel = plage.Find(.Cells(x, 1).Value, , xlValues, xlWhole)
If Not cel Is Nothing Then
.Cells(x, 2).Value = cel.Offset(0, 1).Value
End If
Next x
End If
End With
End Sub