rudy dehaudt
XLDnaute Occasionnel
bonsoir a tous
je voudrai sa voir quelle serai la modification dans le code si dessou pour que les colonnes de A a F soit prise en compte
( le code fonctionne trés bien avec la colonne A )
merci
A+
Sub copie()
Dim Sh1 As Worksheet, Sh2 As Worksheet, Cell As Range, Trouve As Range
Set Sh1 = Sheets("A") 'bbd
Set Sh2 = Sheets("nvl donnée") 'recois les nvl donnee
For Each Cell In Sh2.Range("A1:A" & Sh2.Range("A65536").End(xlUp).Row)
With Sh1
Set Trouve = .Range("A1:A" & Sh1.Range("A65536").End(xlUp).Row).Find(Cell.Value, LookIn:=xlValues, lookat:=xlWhole)
If Trouve Is Nothing Then .Range("A65536").End(xlUp).Offset(1).Value = Cell.Value
End With
Next
End Sub
je voudrai sa voir quelle serai la modification dans le code si dessou pour que les colonnes de A a F soit prise en compte
( le code fonctionne trés bien avec la colonne A )
merci
A+
Sub copie()
Dim Sh1 As Worksheet, Sh2 As Worksheet, Cell As Range, Trouve As Range
Set Sh1 = Sheets("A") 'bbd
Set Sh2 = Sheets("nvl donnée") 'recois les nvl donnee
For Each Cell In Sh2.Range("A1:A" & Sh2.Range("A65536").End(xlUp).Row)
With Sh1
Set Trouve = .Range("A1:A" & Sh1.Range("A65536").End(xlUp).Row).Find(Cell.Value, LookIn:=xlValues, lookat:=xlWhole)
If Trouve Is Nothing Then .Range("A65536").End(xlUp).Offset(1).Value = Cell.Value
End With
Next
End Sub