This is my code:
The error message that appears is:
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
/GuestBook/guestbook.asp, line 17
Any ideia? I've been trying to discover by myself but this is all new to me...
Code:
<html>
<head>
<title>Base de Dados</title>
</head>
<body bgcolor="white" text="#000000">
<%
Dim adoCon
Dim rsGuestbook
Dim strSQL
Dim dbPath
Set adoCon = Server.CreateObject("ADODB.Connection")
adoCon.Open "DRIVER={Microsoft Acccess Driver (*.mdb)}; DBQ=" & Server.MapPath("guestbook.mdb")
Set rsGuestbook = Server.CreateObject("ADODB.Recordset")
strSQL = "SELECT tblComments.Name, tblComments.Comments FROM tblComments;"
rsGuestbook.Open strSQL, adoCon
Do While not rsGuestbook.EOF
response.write ("<br>")
response.write (rsGuestbook("Name"))
response.write ("<br>")
response.write (rsGuestBook("Comments"))
response.write ("<br>")
rsGuestbook.MoveNext
Loop
rsGuestbook.Close
Set rsGuestbook = Nothing
Set adoCon = Nothing
%>
</body>
</html>
The error message that appears is:
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
/GuestBook/guestbook.asp, line 17
Any ideia? I've been trying to discover by myself but this is all new to me...