[thelist] Stupid ASP Question
Anthony Baratta
Anthony at Baratta.com
Thu May 24 02:07:05 CDT 2001
Try this....
<% Option Explicit %>
<% Dim dcnDB 'As ADODB.Connection
Set dcnDB = Server.CreateObject("ADODB.Connection")
dcnDB.ConnectionString = "DSN=Database"
dcnDB.Open
Set dcnRS = dcnDB.Execute("SELECT * FROM Products")
if not (dcnRS.BOF AND dcnRS.EOF) then
while not (dcnRS.EOF)
for each fld in dcnRS.Fields
Response.Write "<b>" & fld.name & "</b>: " & fld.value & "<br>" &
vbCRLF
next
dcnRS.MoveNext
wend
else
Response.Write "No Data!"
end if
%>
---
Anthony Baratta
President
Keyboard Jockeys
More information about the thelist
mailing list