我正在运行以下代码将整个工作表从excel导入到访问,工作表有77k行,但Access只导入65.535,如何解决它的任何问题? Excel和Access都是2013版本。
Function importa()
Dim rs As DAO.Recordset
Dim inicio As String
Dim fim As String
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel12, _
"NOMEBASE", Application.CurrentProject.Path() + "\Abre_Envio_Novo_Layout.xlsm", True, "Menu!BJ25:BM26"
Set db = CurrentDb()
Set rs = db.OpenRecordset("NOMEBASE")
inicio = rs.Fields(2).Value
fim = rs.Fields(3).Value
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel12, _
"BASE", Application.CurrentProject.Path() + "\Abre_Envio_Novo_Layout.xlsm", True, "Mailing_Recebido!A:AX"
rs.Close
End Function
答案 0 :(得分:1)
acSpreadsheetTypeExcel12
应为acSpreadsheetTypeExcel12Xml
,用于导入Excel 2010工作簿。
答案 1 :(得分:-1)
docmd.transfertext.........
如果您想在访问
中传输超过65536行,请在MS访问中使用此命令