Microsoft OLE DB Provider for ODBC Drivers (0x80004005)


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 4 of 4

Thread: Microsoft OLE DB Provider for ODBC Drivers (0x80004005)

  1. #1
    bcm Guest

    Microsoft OLE DB Provider for ODBC Drivers (0x80004005)


    Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
    [Microsoft][ODBC Driver Manager] Data source name not found and no default
    driver specified
    /Login.asp, line 19


    My code is valid as it worked using a PWS on an earlier version of windows.
    Any suggestions? My code is below

    <%@ Language=VBScript %>

    <html>
    <body bgcolor=#ffffff>

    <%
    if ((Request.form("uid") = "") OR (Request.form("ups") = "")) then
    %>
    <Table><TR><TD><b><form action="Login.asp" method="post">
    User ID:</b></TD><TD><input type=text name=uid size=8></TD></TR><TR><TD><b>
    Password:</b></TD><TD><input type=password name=ups size=8></TD></TR><TR><TD></TD><TD>
    <input type=submit value="Go"></TD></Table>
    </form>
    <%
    else

    Dim con
    Set con = Server.CreateObject("ADODB.Connection")
    con.Open "DSN=cmstemp"

    Set rstuid = Server.CreateObject("ADODB.Recordset")
    SQL = "SELECT * FROM UserAccess WHERE UserID = '" & Request.form("uid")
    & "';"
    rstuid.Open SQL, con, 3
    If not rstuid.EOF then
    rstuid.movefirst
    If ((rstuid.RecordCount = 1) and (strcomp(rstuid("Password"),Request.form("ups"))
    = 0)) then
    Select Case rstuid("Access")

    Case 1
    SQL = "SELECT * FROM ClientContactInfo WHERE UserID = '" & Request.form("uid")
    & "';"
    Set rstuac = Server.CreateObject("ADODB.REcordset") 'rstuid.Close
    rstuac.Open SQL, con, 3
    If not rstuac.EOF then
    rstuac.movefirst
    Response.Write(rstuac("FirstName") & ", " & rstuac("LastName") & "<br><br>")
    end if
    %>
    Which action do you wish to take?<Br><Br>
    <b>Customer Contact Info:</b><Table>
    <TR><TD><form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=submit value="Add">
    </form>
    </TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Modify">
    </form>
    </TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Delete">
    </form>
    </TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <b>Memo and Notes:</b><Table>
    </TD><TD>
    <form action="MemoNotes.asp" method="post">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <b>Calendar and Appointments:</b><Table>
    <TR><TD><form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Add">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Modify">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Delete">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <b>Expirations:</b><Table>
    <TR><TD><form action="Expirations.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Add">
    </form>
    </TD><TD>
    <form action="Expirations.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Modify">
    </form>
    </TD><TD>
    <form action="Expirations.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="Delete">
    </form>
    </TD><TD>
    <form action="Expirations.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <%

    Case 2
    SQL = "SELECT * FROM ClientContactInfo WHERE UserID = '" & Request.form("uid")
    & "';"
    Set rstuac = Server.CreateObject("ADODB.REcordset") 'rstuid.Close
    rstuac.Open SQL, con, 3
    If not rstuac.EOF then
    rstuac.movefirst
    Response.Write(rstuac("FirstName") & ", " & rstuac("LastName") & "<br>")
    end if
    %>
    <b>Which action do you wish to take?</b><br><Br>
    <b>Customer Contact Info:</b><Table>
    <TR><TD><form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Add">
    </form></TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Modify">
    </form></TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Delete">
    </form></TD>
    <TD><form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="View">
    </form>
    </TD><TD>
    </form></TD></TR></Table><b>
    View Agri Marketing Staff:</b><Table><TR><TD>
    <form action="Staff.asp" method="post">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="View"></TD></TR></Table>
    </form>
    <b>Memo and Notes:</b><Table><TD>
    <form action="MemoNotes.asp" method="post">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value=View></form></TD></TR></Table>
    <b>Calendar and Appointments:</b><Table>
    <TR><TD><form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Add">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Modify">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Delete">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>"><input type=hidden
    name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <b>Expirations:</b><Table>
    <TR><TD><form action="Expirations.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <%
    Case 3

    SQL = "SELECT * FROM ClientContactInfo WHERE UserID = '" & Request.form("uid")
    & "';"
    Set rstuac = Server.CreateObject("ADODB.REcordset") 'rstuid.Close
    rstuac.Open SQL, con, 3
    If not rstuac.EOF then
    rstuac.movefirst
    Response.Write(rstuac("FirstName") & ", " & rstuac("LastName") & "<br><br>")
    end if
    %>
    <b>Which action do you wish to take?</b><Br><Br>
    <b>Memo and Notes:</b><Table>
    </TD><TD>
    <form action="MemoNotes.asp" method="post">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <b>View Agri Marketing Staff:</b><Table><TR><TD>
    <form action="Staff.asp" method="post">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="View"></TD></TR></Table>
    </form>
    <b>Customer Contact Info:</b><Table>
    <TR><TD><form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Add">
    </form>
    </TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Modify">
    </form>
    </TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Delete">
    </form>
    </TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <b>Calendar and Appointments:</b><Table>
    <TR><TD><form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Add">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Modify">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Delete">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <%
    Case 4

    SQL = "SELECT * FROM ClientContactInfo WHERE UserID = '" & Request.form("uid")
    & "';"
    Set rstuac = Server.CreateObject("ADODB.REcordset") 'rstuid.Close
    rstuac.Open SQL, con, 3
    If not rstuac.EOF then
    rstuac.movefirst
    Response.Write(rstuac("FirstName") & ", " & rstuac("LastName") & "<br>")
    end if
    %>
    <b>Which action do you wish to take?</b><br><Br>
    <b>Customer Contact Info:</b><Table>
    <TR><TD><form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="View">
    </form>
    </TD><TD>
    <form action="CustomerContactInfo.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Modify">
    </form></TD></TR></Table><b>
    View Agri Marketing Staff:</b><Table><TR><TD>
    <form action="Staff.asp" method="post">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=submit value="View"></TD></TR></Table>
    </form>
    <b>Memo and Notes:</b><Table><TD>
    <form action="MemoNotes.asp" method="post">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=uid value="<%=Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value=View></form></TD></TR></Table>
    <b>Calendar and Appointments:</b><Table>
    <TR><TD><form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=1>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Add">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=2>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Modify">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=3>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="Delete">
    </form>
    </TD><TD>
    <form action="CalendarAppointments.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=hidden name=Comp value="<%=rstuac("Company")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <b>Expirations:</b><Table>
    <TR><TD><form action="Expirations.asp" method="post">
    <input type=hidden name=save value=4>
    <input type=hidden name=uid value="<%Request.form("uid")%>">
    <input type=hidden name=ups value="<%=Request.form("ups")%>">
    <input type=hidden name=ua value="<%=rstuid("Access")%>">
    <input type=submit value="View">
    </form>
    </TD></TR></Table>
    <%
    End Select

    Else
    Response.Write("Invalid login, go back and try again<br>")
    End if
    End if
    End if
    ' rstuid.Close
    ' rstuac.Close
    Set rstuid=Nothing
    Set rstuac=Nothing
    %>
    <hr noshade size="1">

    </body>
    </html>



  2. #2
    Devin Knutson Guest

    Re: Microsoft OLE DB Provider for ODBC Drivers (0x80004005)

    "bcm" <mail@hotmail.com> wrote in message
    news:3c9a3ead$1@10.1.10.29...
    >
    > My code is valid as it worked using a PWS on an earlier version of

    windows.
    > Any suggestions? My code is below


    Have you made sure that the cmstemp DSN exists on the new server,
    and points to the correct database using the correct driver?

    --
    Devin
    ========================================================



  3. #3
    CHOUKRI Guest

    Re: Microsoft OLE DB Provider for ODBC Drivers (0x80004005)


    Hello!..
    Perhaps, you should configure your database as a data source of the system
    (in Win2000 -> control panel -> Admnistration tools -> odbc manager -> ...
    -> add ....) -> see win2000 help...
    bye..

  4. #4
    Join Date
    Jan 2009
    Posts
    1

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center