Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Foxpro database gives error '80040e37' and 'table not found'

Status
Not open for further replies.

longingforfriday

Programmer
Apr 4, 2003
1
NL
Hi there ...
I am trying to write asp pages to access the database of our companies CRM package (Known as ARCHIE). I have made a DSN on the webserver (the webserver2) pointing to a share on the machine where the data is (the 'citrix1'). When I run my page , I get the problem that the .asp code doesnt seem to be able to find any of the tables. I have also tryed writing a Java applet, and this works as long as the database is on the local machine, but when I use the ODBC coupling, I get the same problem. The database is FoxPro, I think version 2.? - so you have to use 'free tables' and not a '.dbc'database.....any ideas anyone ?: here is the effect:

Error looks like this:-
=======================


Microsoft OLE DB Provider for ODBC Drivers error '80040e37'

[Microsoft][ODBC Visual FoxPro Driver]File 'naw001.dbf' does not exist.

/default.asp, line 13


Code looks like this:-
======================


<%@LANGUAGE=VBSCRIPT%>
<!
This ASP example uses ADO to read records from a database
>
<html>
<body>
<%
dim ADOconn, ADOrs, sqlstr

sqlstr=&quot;SELECT * FROM naw001&quot;
set ADOconn = Server.CreateObject(&quot;ADODB.Connection&quot;)
ADOconn.Open &quot;archie&quot;
set ADOrs = ADOconn.execute(sqlstr)
if ADOrs.BOF and ADOrs.EOF then ' Query didn't return any records.
Response.Write(&quot;No Records.&quot;)
else
ADOrs.MoveFirst
Do While Not ADOrs.EOF
Response.Write(ADOrs(&quot;R01&quot;) & &quot; &quot; _
& ADOrs(&quot;R02&quot;) & &quot;<br>&quot;)
ADOrs.MoveNext
Loop
Response.Write(&quot;<p>End of data.&quot;)
end if
ADOrs.close
set ADOrs = nothing
%>
</body>
</html>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top