Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem using ADO in an ASP page
Message
De
03/10/2002 10:11:07
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Titre:
Problem using ADO in an ASP page
Divers
Thread ID:
00707310
Message ID:
00707310
Vues:
49
Hi,

There are some VFP free tables residing in a directory of a file server. I created a data source (called maquinas_testes) and want to access them via ODBC in an ASP page. Below is the code fragment of that ASP page, where the connection is made:
StrConnDB = "DSN=maquinas_testes"
Set oConn = server.createobject("ADODB.Connection")
oConn.ConnectionString = StrConnDB
oConn.Open()
It connects ok. Then I try to perform a select in one of those tables (Maquinas_PedMaqCab), as shown below:
Set rsMaq=server.createobject("ADODB.Recordset")
rsMaq.ActiveConnection= oConn
StrSql="Select * from Maquinas_PedMaqCab WHERE PH_numped=900243"
oConn.execute(StrSql)
When the Select is executed I get the following error:
Microsoft OLE DB Provider for ODBC Drivers error '80040e37' 
[Microsoft][ODBC Visual FoxPro Driver]File 'maquinas_pedmaqcab.dbf' does not exist. 
/maquinas/relatorio.asp, line 15 
Line 15 is the line containing the "oConn.execute(StrSql)"

If I try to make the same accesses via SQLexec() in a VFP prg it works fine.

What's happening?

TIA

Fernando
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform