Bonjour
J'utilise la macro suivante mais elle bugge au niveau du code coloré en rouge
Ce bout de code me sert à copier la zone "CurrentRegion" de la feuille "Filtre" vers la feuille "Ref"
Je ne comprends pas les raisons du bug
Quelqu'un peut t'il m'aider?? 🙁
Sub MAJ_UO()
Sheets("Filtre").Select
Plage = Range("E3:E65536")
Nbval = Application.WorksheetFunction.CountA(Plage)
Range("B3").CurrentRegion.Select
selection.Copy
Sheets("Ref").Select
Range("B10").Select
For i = 1 To Nbval
selection.EntireRow.Insert
selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
selection.Interior.ColorIndex = 12
Range("B10").Select
selection.EntireRow.Delete
Next i
Calculate
End Sub
J'utilise la macro suivante mais elle bugge au niveau du code coloré en rouge
Ce bout de code me sert à copier la zone "CurrentRegion" de la feuille "Filtre" vers la feuille "Ref"
Je ne comprends pas les raisons du bug
Quelqu'un peut t'il m'aider?? 🙁
Sub MAJ_UO()
Sheets("Filtre").Select
Plage = Range("E3:E65536")
Nbval = Application.WorksheetFunction.CountA(Plage)
Range("B3").CurrentRegion.Select
selection.Copy
Sheets("Ref").Select
Range("B10").Select
For i = 1 To Nbval
selection.EntireRow.Insert
selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
selection.Interior.ColorIndex = 12
Range("B10").Select
selection.EntireRow.Delete
Next i
Calculate
End Sub