Private Sub CommandButton13_Click()
Dim Variable1 As String
Dim Variable2 As String
Dim Variable3 As String
Dim Variable4 As String
Dim Variable5 As String
Dim Variable6 As String
Dim Variable7 As String
Dim Variable8 As String
Dim x As String
Dim i As Integer
Dim j As Integer
Dim h As Integer
i = 9
For i = 9 To 846 Step 27
If Cells(i, 2) = "753220 - PARIS KELLER ACP" Then
For j = 5 To 26 Step 1
If Cells(i + 1, j) = "Janvier" Then
With ThisWorkbook.Sheets("Détail ACP")
Variable1 = .Cells(i + 8, j).Value
Variable2 = .Cells(i + 12, j).Text
Variable3 = .Cells(i + 11, j).Text
Variable4 = .Cells(i + 3, j).Text
Variable5 = .Cells(i + 14, j).Text
Variable6 = .Cells(i + 15, j).Text
Variable7 = .Cells(i + 5, j).Text
Variable8 = .Cells(i + 6, j).Text
End With
Set Dest = Workbooks.Open(ActiveWorkbook.Path & "\TBM ACP.xls")
With Dest.Sheets("Paris Keller")
.Cells(9, 7).Value = Variable1
x = (Variable2 * .Cells(9, 7).Value) / .Cells(5, 7).Value
.Cells(13, 7).Value = x
.Cells(30, 7).Value = Variable3
.Cells(40, 7).Value = Variable4
.Cells(42, 7).Value = Variable5
.Cells(43, 7).Value = Variable6
.Cells(45, 7).Value = Variable7
.Cells(47, 7).Value = Variable8
End With
Exit For
End If
Next
Exit For
End If
Next
End Sub