Sub ParcourSheets()
Dim Feuille As Worksheet, cn As String
cn = GenereCSTRING(Xls, Base:=ThisWorkbook.FullName, Titre:=True)
For Each Feuille In ThisWorkbook.Sheets
ExportExceltoSql Feuille, cn
Next
End Sub
Sub ExportExceltoSql(Feuille As Worksheet, cn As String)
Const CnSqlServeur = "[ODBC;Driver={SQL Server};SERVER=MyServeur;DATABASE=MyDATABASE;UID=UserName;Pwd=PassWord]"
Dim Sql As String
Sql = "SELECT * INTO " & CnSqlServeur & "." & Feuille.Name & " FROM [" & Feuille.Name & "$]"
ExecuteRequete Sql, cn
End Sub