By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,292 Members | 1,758 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,292 IT Pros & Developers. It's quick & easy.

Access / ASP Slow Web connection

P: 1
I'm using an access DB as a back end of a Web application. Sometimes, the web page is very slow comming up ( 40 - 120 secs) I troubleshooted the page
and determined that the slowness is in the Open connection command; See code below.

connectstr = "Driver={Microsoft Access Driver (*.mdb)};DBQ=" & db_path
Set oConn = Server.CreateObject("ADODB.Connection")
oConn.Open connectstr

Any thoughts on whay this command would take so long to execute?

Oct 3 '08 #1
Share this Question
Share on Google+
1 Reply

Expert 100+
P: 1,923
Not sure, but the example given in this link uses the activeConnection property. Try using the activeConnection property in your code, and see if it helps.

Excerpted from link:
Expand|Select|Wrap|Line Numbers
  1. 'Connects to the Access driver and Access database in the Inetpub
  2. 'directory where the database is saved
  3. strProvider = "Driver={Microsoft Access Driver (*.mdb)};
  4.    DBQ=C:\Inetpub\Wwwroot\Tutorial\guestbook.mdb;"
  5. 'Creates an instance of an Active Server component
  6. set objConn = server.createobject("ADODB.Connection")
  7. 'Opens the connection to the data store
  8. objConn.Open strProvider
  9. 'Instantiate Command object and use ActiveConnection property to
  10. 'attach connection to Command object
  11. set cm = Server.CreateObject("ADODB.Command")
  12. cm.ActiveConnection = objConn 
Oct 5 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.