SQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsDatabaseSQL Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old October 19th, 2000, 03:06 AM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 23
ODBC driver problems with Access / ASP

<i><b>Originally posted by : ADEW (asp@adew.co.uk)</b></i><br />I'm having problems getting an ASP file to open up my Access database on both W2000 and W98. The Access is a new install in all cases, and is Access 2000. The error I get on W2000 is listed below:<br /><br />Error Type:<br />Microsoft OLE DB Provider for ODBC Drivers (0x80004005)<br />[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified<br /><br />And the code I am using is (with error line marked):<br /><br /><%<br /> Dim objConnection<br /> <br /> Set objConnection = Server.CreateObject("ADODB.Connection")<br /> objConnection.ConnectionString="DSN=Contacts_Test.dsn"<br /> objConnection.Open ' error at this line<br /> <br /> Dim objRecSet<br /> objRecSet = Server.CreateObject("ADODB.Recordset")<br /> objRecSet.Open "Contacts", objConnection, , , 2<br />%><br /><br />I've also tried non DSn and get the same error. I guess I have not set my system up correctly - but I've no idea how to get around this problem. Can any one suggest a solution??<br />

Reply With Quote
  #2  
Old November 7th, 2000, 01:54 PM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 23
<i><b>Originally posted by : Fredrik (psyk00@chello.se)</b></i><br />well u should allways use DSN-less conn.<br />the error u got is ODBC cannot find it<br />or u dont have accosiated the right driver for<br />the conn.<br />TRY THIS ONE:<br />remember dont include inetpub/wwwroot <br /><br /><%<br />Option Explicit<br />Response.Buffer = True<br />dim conn<br />dim rs<br />dim strID<br />dim strconn<br /><br />strconn = "DRIVER=Microsoft Access Driver (*.mdb);DBQ=" & Server.MapPath("/database.mdb")<br />set conn = server.createobject("adodb.connection")<br />conn.open strconn<br /><br />set rs = server.createobject("adodb.recordset")<br />rs.open "TABLEname", conn, 2, 2<br />%> <br /><br /><br />if this dosent work for u then u dont have the<br />necesary files installed<br /><br />

Reply With Quote
Reply

Viewing: ASP Free ForumsDatabaseSQL Development > ODBC driver problems with Access / ASP


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
Stay green...Green IT