I am trying to setup my database listing so that the data is sorted in multiple colums side by side. Here's the code:
Code:
<TABLE Border=1 CellPadding=3 bgColor=23415D>
<%
SQL = "SELECT * FROM tblCategory, tblBusiness " _
& " WHERE tblBusiness.CategoryID = tblCategory.ID " _
& " AND tblCategory.ID IN (" & catsChosen & ")" _
& " ORDER BY CategoryName, Name"
Set RS = catConn.Execute(SQL)
priorCat = ""
Do Until RS.EOF
curCat = RS("CategoryName")
If curCat <> priorCat Then
Response.Write "<TR >" _
& "<TD colspan=2 align=center>" & "<font size=4 color=FFFFFF>" & "<B>" & curCat & "</font>" & "</b>" & "</TD>" _
& "</TR>" & vbNewLine
priorCat = curCat
End If
Response.Write "<TR><TD>" _
& "<B>" & RS("Name") & "</b>" & "<br>" & RS("Address") & "<br>" & RS("City") & ", " & RS("State") & " " & RS("Zip") & "<br>" & RS("Phone") & "</TD>" & vbNewLine
RS.MoveNext
Response.Write "<TD>" & "<B>" & RS("Name") & "</b>" & "<br>" & RS("Address") & "<br>" & RS("City") & ", " & RS("State") & " " & RS("Zip") & "<br>" & RS("Phone") & "</TD>" _
& "</TR>" & vbNewLine
Rs.MoveNext
Loop
Response.Write "</TABLE>" & vbNewLine
RS.Close
' end of displaying results from prior request...if any
'
End If
%>
The problem I am having is down at the bottom. I create one side of the table, then I want to move to the next record to create the other side. I keep getting an error 80020009 with no other information, just
index2.asp, line 63. I really am just a newb so any help you can give would be appreciated.
I have the page posted at
http://www.tcurtis45.dns2go.com/index2.asp
Thank you,
Tony