![]() |
OLEDB Error on Excel Macro
Hi All, I've created an Excel Macro that has the following code: con.Execute "INSERT INTO Estr_Materiais SELECT * FROM OPENROWSET ('Microsoft.Jet.OLEDB.4.0','Excel 8.0;HDR=YES;IMEX=1;Database=" & caminhoExport & arquivoExport & "','SELECT CodZFoccus_IV, CodInterno_IV, CodZFoccus_IF, CodInterno, Quantidade, Unid, Descricao, Now() AS Data FROM [MatImport$]');" When I execute this code accessing a local SQL Server, it's work fine. But, when I execute macro accessing a remote SQL Server I receive the following error message: " ... '-2147217900 (80040e14)': OLE DB Provider 'Microsoft.Jet.OLEDB.4.0' reported an error. The provider did not give any information about the error." Any help will be precious!!! Best regards, JV. -- joaovtt ------------------------------------------------------------------------ joaovtt's Profile: http://www.excelforum.com/member.php...o&userid=24286 View this thread: http://www.excelforum.com/showthread...hreadid=384358 |
OLEDB Error on Excel Macro
Any help?? -- joaovtt ------------------------------------------------------------------------ joaovtt's Profile: http://www.excelforum.com/member.php...o&userid=24286 View this thread: http://www.excelforum.com/showthread...hreadid=384358 |
All times are GMT +1. The time now is 01:42 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com