Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Calling MS Access functions via ADO
Message
 
À
06/06/2002 17:33:57
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00665704
Message ID:
00665828
Vues:
17
I think that you cannot call Access's functions directly via ADO. Use OLE Automation instead. It should be something like:
oAcc = CreateObject("Access.Application")
oAcc.Eval("MakeNewHeader()")
* or
oAcc.Run("MakeNewHeader")
>I am using VFP 6 to call an Access function and can't get it to work. The command object and the connection object get created okay, and I set the commandtype to 4 (also tried to 1 and 8). ActiveConnection is the connection object and CommandText is the function name (tried it with and without trailing parans). After executing the command I get an error message that says it can't find the table or query "MakeNewHeader", which is the function name. In the case of CommandTypes 1&8, the error says it is an invalid SQL statement.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform