Sub Importation_xlsx()
Dim FichierData, Template As String
Dim myData As Variant
FichierData = Application.GetOpenFilename("Fichier Excel (*.xlsx), *.xlsx", , _
"Select your file!")
If FichierData = "Faux" Then
MsgBox "@Data Tech : No file selected!"
End
End If
ThisWorkbook.ActiveSheet.Cells.Clear
'Cells.Clear
Application.ScreenUpdating = False
Application.DisplayAlerts = True
Workbooks.Open Filename:=FichierData, ReadOnly:=True
NomFichierOuvert = ActiveWorkbook.Name
Set Monclasseur = Application.Workbooks.Open(FichierData)
Dim sheetsNumber, RowLength, i, j, columnLength As Integer
sheetsNumber = 2
RowLength = 5
columnLength = 2
i = 1
j = 1
For m = 1 To sheetsNumber
For l = 1 To columnLength
For k = 1 To RowLength
ThisWorkbook.ActiveSheet.Cells(i, j).Value = Monclasseur.Sheets(m).Cells(k, l).Value
i = i + 1
Next k
i = 1
j = j + 1
Next l
Next m
Application.DisplayAlerts = False
Workbooks(NomFichierOuvert).Close
Application.DisplayAlerts = True
End Sub