hi i hav problem display the information i have saved in the database..can anione help mi ? thx a lot! The codes are below..by the way gt can intro ani website that teaches using sql to appy on asp codes.....Reali thx a lot!
<% Option Explicit %>
<%
dim conn
dim rs
dim varDatabaseName
dim sql
varDatabaseName="db2.mdb"
set conn = server.createobject("ADODB.connection"
conn.open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath(varDatabaseName)
set rs = server.createobject("ADODB.recordset"
rs.CursorType = 2
rs.LockType = 3
dim s
s = "Select * from friens"
rs.open s,conn
Do While Not rs.EOF
response.write rs("Firstname" &
response.write rs("Lastname" &
response.write rs("Gender" &
response.write rs("Age" &
response.write rs("Email" &
rs.movenext
loop
rs.close
set rs=nothing
conn.close
set conn=nothing
%>
<% Option Explicit %>
<%
dim conn
dim rs
dim varDatabaseName
dim sql
varDatabaseName="db2.mdb"
set conn = server.createobject("ADODB.connection"
conn.open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath(varDatabaseName)
set rs = server.createobject("ADODB.recordset"
rs.CursorType = 2
rs.LockType = 3
dim s
s = "Select * from friens"
rs.open s,conn
Do While Not rs.EOF
response.write rs("Firstname" &
response.write rs("Lastname" &
response.write rs("Gender" &
response.write rs("Age" &
response.write rs("Email" &
rs.movenext
loop
rs.close
set rs=nothing
conn.close
set conn=nothing
%>