Sub transfert_donnee()
Dim chemin As String
Dim N, L As Integer
Dim NumModule As String
Dim Module1 As Long
Dim Num As Integer
' Ouverture du fichier .csv et remise en forme
Module1 = 101510
Module2 = 101511
Module3 = 101512
Module4 = 101519
Module5 = 101520
Module6 = 101521
Module7 = 101522
Module8 = 101524
Module9 = 101569
Module10 = 101570
Module11 = 101571
Module12 = 101572
Module13 = 101573
Module14 = 101574
Module15 = 101575
For N = 1 To 15
NumModule = "Module" & N
chemin = ThisWorkbook.Path & "\MAVG_" & NumModule & "_M1105" & ".CSV"
Workbooks.Open Filename:=chemin
L = Range("A60000").End(xlUp).Row + 1 ' Nombre de ligne dans le fichier csv
With ActiveWorkbook.Sheets(1).Columns(1) ' separe les points-virgules dans les différentes colonnes
.TextToColumns Destination:=.Cells(1, 1), DataType:=xlDelimited, Tab:=False, Semicolon:=True
End With
MaxIL1 = Application.WorksheetFunction.Max(Range("g1:g" & Range("g65530").End(xlUp).Row))
MaxIL2 = Application.WorksheetFunction.Max(Range("h1:h" & Range("h65530").End(xlUp).Row))
MaxIL3 = Application.WorksheetFunction.Max(Range("i1:i" & Range("i65530").End(xlUp).Row))
ThisWorkbook.Activate
Range("D" & N + 9).Value = MaxIL1
Range("E10").Value = MaxIL2
Range("F10").Value = MaxIL3
Next N
End Sub