We help IT Professionals succeed at work.

Provider error '80040e4d'

mjoesting
mjoesting asked
on
983 Views
Last Modified: 2013-12-25
Experts;
My code is generating the following error(on the connection string line):

Provider error '80040e4d'
Authentication failed.


dim conn, rs, sql, connstr
set conn = Server.CreateObject("ADODB.Connection")
set rs = Server.CreateObject("ADODB.Recordset")
connstr = "Microsoft.Jet.OLEDB.4.0;Data Source=" &_
response.write(Server.MapPath("ts2incentives.mdb")) &_
";User ID=ts2incentives;Password=Passw0rd;"
conn.open connstr
sql = "select * from PINs;"
set rs = conn.Execute(sql)
Comment
Watch Question

Try this:

connstr = "Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath(".") & "\ts2incentives.mdb";User ID=ts2incentives;Password=Passw0rd;"

Author

Commented:
This code worked for me:

dim conn, rs, sql, connstr
set conn = Server.CreateObject("ADODB.Connection")
connstr="Driver={Microsoft Access Driver (*.mdb)};" &_
      "filedsn=d:\hosting\ts2incentives\test\access_ts2incentives.dsn;" &_
      "DBQ=d:\hosting\ts2incentives\test\ts2incentives.mdb;" &_
      "UID=ts2incentives;PWD=Passw0rd;"
conn.open connstr
sql = "select * from PINs;"
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.