Xldown en boucle sur "with"

Bonjour à tous

Problème en colonne "i"

Merci les gars !!!!!!!!!!!!!

Private Sub Worksheet_SelectionChange(ByVal Target As Range)

                        ActiveSheet.Unprotect
Application.ScreenUpdating = True
'{Autofit.Line}-----------------------
Dim Plage As Range
Set Plage = Range("désignation")

Application.ScreenUpdating = False

    If Not Intersect(Plage, ActiveCell) Is Nothing Then
       ActiveCell.UnMerge
      ActiveCell.EntireRow.AutoFit
Range(ActiveCell.Address, ActiveCell.Offset(0, 1).Address).Select
    Selection.Merge
 End If
Set Plage = Nothing

Application.ScreenUpdating = True

'{TVA}--------------------------------
Set ColTVA = Range("TVA")

Application.ScreenUpdating = False

    If Not Intersect(ColTVA, ActiveCell) Is Nothing Then
        If (Target.Column = 8) And Target.Count = 1 Then
            If Target = "" Then SendKeys "%{down}"
        End If
    End If
Set ColTVA = Nothing

Application.ScreenUpdating = True
'{Insert line copy}-------------------
Const n°G As Integer = 9
If Target.Column = n°G Then

Application.ScreenUpdating = False
ActiveSheet.Unprotect

    ActiveCell.Offset(1, 0).Select 'Une case vers le bas
  ActiveCell.EntireRow.Select
  Selection.Insert Shift:=xlDown

    ActiveCell.Offset(0, 6).Select 'Cinq cases vers la droite
        ActiveCell.FormulaR1C1 = "=IF(AND(RC[-2]>0,RC[-1]>0),RC[-2]*RC[-1],"" "")"

    ActiveCell.Offset(0, 3).Select
        ActiveCell.FormulaR1C1 = "=IF(AND(RC[-5]>0,RC[-4]>0,RC[-2]>0),(RC[-3]/100)*RC[-2],IF(AND(RC[-5]>0,RC[-4]>0,RC[-2]=0),(RC[-3]/100)*19.6,"" ""))"

    ActiveCell.Offset(0, -7).Select
        Range(ActiveCell.Address, ActiveCell.Offset(0, 1).Address).Select
    Selection.Merge

ActiveSheet.Protect

Application.ScreenUpdating = True

End If
End Sub

Bonjour

Un fichier dans lequel tu aurais marqué ce que tu as et ce que tu veux serait souhaitable au manque d'informations

Même ton titre "xldown en boucle sur "with" : Pas vu de With dans ton code

A suivre

Bonne journée

Rechercher des sujets similaires à "xldown boucle"