Hi experts,
I have another problem. I need OR to run a macro in access OR to transfer an excel-file with about 13 colomns into an access database FROM VB.
The code I'm using now is:
Dim oAccess As Microsoft.Office.Interop.A
ccess.Appl
icationCla
ss
oAccess = CreateObject("Access.Appli
cation")
oAccess.Visible = True
oAccess.OpenCurrentDatabas
e(dbpsi_so
urce)
'Run the macros.
oAccess.Run("Import_Openfp
si")
oAccess.DoCmd().Quit(AcQui
tOption.ac
QuitSaveAl
l)
System.Runtime.InteropServ
ices.Marsh
al.Release
ComObject(
oAccess)
oAccess = Nothing
This "should" work but always returns the error: "can't find the procedure 'Import_Openfpsi.'" (altough the MACRO excists)
The only thing this macro does is transfer an excel file to the access database....(works manually, so macro is ok)
Wouldn't it be better just to code this transfer??? If so, anyone has the code for this?? Or the answer/solution why I get this error?
Thanks for your time.
Regards,
Rob
Start Free Trial