Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Access dbase connection string errors

Reply
Thread Tools

Access dbase connection string errors

 
 
J. Muenchbourg
Guest
Posts: n/a
 
      08-08-2003
I keep getting
"Unable to open registry key 'Temporary (volatile) Jet DSN "
errors pointing to my connection string when the same connection string
is working for a few of my other pages. The MSAccess database does have
the right permissions configured. Below is code I'm using:

<%
dbcon="DBQ=" & Server.Mappath("diary.mdb") & ";Driver={Microsoft Access
Driver (*.mdb)};"
Set calConn = Server.CreateObject("ADODB.Connection")
calConn.Open dbcon%>
<%dim freetsql,rsfree
freetsql = "select text_field from diary where dte ='" & dfm & "'"
set rsfree = Server.CreateObject("ADODB.Recordset")
rsfree.Open freetsql,calConn,3 %>


???
Muench

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
 
Reply With Quote
 
 
 
 
Ray at
Guest
Posts: n/a
 
      08-08-2003
Try this connection string:

"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" &
Server.Mappath("diary.mdb")
OLEDB

Then, after that's all working, go to
http://yoursite.com/TheDirectoryWithTheDB/diary.mdb and notice that you are
prompted to download your database. Anyone would be able to download your
database that way.

For further information on the error you received, read
http://www.aspfaq.com/2009.

Ray at work

"J. Muenchbourg" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I keep getting
> "Unable to open registry key 'Temporary (volatile) Jet DSN "


> <%
> dbcon="DBQ=" & Server.Mappath("diary.mdb") & ";Driver={Microsoft Access
> Driver (*.mdb)};"



 
Reply With Quote
 
 
 
 
Mats
Guest
Posts: n/a
 
      08-08-2003
Then, after that's all working, go to
http://yoursite.com/TheDirectoryWithTheDB/diary.mdb and notice that you are
prompted to download your database. Anyone would be able to download your
database that way.
Yes, just checked. How could we avoid that?
Mats

"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message news:<#(E-Mail Removed)>...
> Try this connection string:
>
> "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" &
> Server.Mappath("diary.mdb")
> OLEDB
>
> Then, after that's all working, go to
> http://yoursite.com/TheDirectoryWithTheDB/diary.mdb and notice that you are
> prompted to download your database. Anyone would be able to download your
> database that way.
>
> For further information on the error you received, read
> http://www.aspfaq.com/2009.
>
> Ray at work
>
> "J. Muenchbourg" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > I keep getting
> > "Unable to open registry key 'Temporary (volatile) Jet DSN "

>
> > <%
> > dbcon="DBQ=" & Server.Mappath("diary.mdb") & ";Driver={Microsoft Access
> > Driver (*.mdb)};"

 
Reply With Quote
 
Ray at
Guest
Posts: n/a
 
      08-08-2003
Do not keep your mdb file in your website's directory structure. I.E.


Physical path on server to .htm/.asp files:
D:\Websites\Website1


Put mdb databases elsewhere, like:
D:\Databases\Website1\diary.mdb

When you do that, your Server.MapPath will no longer work, since that will
no longer be the path to your DB, but I think that's a minor tradeoff. You
could keep the path to your DB in an application variable or a global
constant. More on this topic can be found at:
http://www.aspfaq.com/2454
http://groups.google.com/groups?thre...ing.google.com

Ray at work


"Mats" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) om...
> Then, after that's all working, go to
> http://yoursite.com/TheDirectoryWithTheDB/diary.mdb and notice that you

are
> prompted to download your database. Anyone would be able to download your
> database that way.
> Yes, just checked. How could we avoid that?
> Mats
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Access dbase no longer works on workstation? JVRudnick ASP General 2 02-29-2008 01:12 AM
DBase database connection Problem shieldguy ASP .Net 0 05-23-2007 10:16 AM
insert new record in Access dbase AND retrieve autonumber loreille ASP .Net 1 10-28-2004 06:57 PM
re:insert new record in Access dbase AND retrieve autonumber loreille ASP .Net 0 10-28-2004 02:55 PM
Dbase Connection Stan Cook Python 9 09-06-2004 07:36 AM



Advertisments