hughesmi
04-06-2005, 08:42 PM
I getting this error and I can't fugure out where I'm screwing up, Can anyone help?
Error Type:
Microsoft VBScript compilation (0x800A040E)
'loop' without 'do'
/TEST/tickertest/newview.asp, line 28
Loop
Code:
<!--#INCLUDE FILE="connection.asp" -->
<%
DIM mySQL, objRS
mySQL = "SELECT * FROM news"
Set objRS = Server.CreateObject("ADODB.Recordset")
objRS.Open mySQL, objConn
DIM recCount
IF Not objRS.EOF THEN
Response.Write "<table width='100%'>"
recCount = 0
Do Until objRS.EOF
IF recCount Mod 3 = 0 THEN
IF recCount <> 0 THEN
Response.Write "</tr>"
Response.Write "<tr><td>"&objRS("Item")&"</td>"
ELSE
Response.Write "<td>"&objRS("Item")&"</td>"
END IF
recCount = recCount + 1
objRS.MoveNext
Loop
Response.Write"</tr></table>"
'ELSE
'Response.Write "Sorry, there are no records in our database."
'END IF
%>
Error Type:
Microsoft VBScript compilation (0x800A040E)
'loop' without 'do'
/TEST/tickertest/newview.asp, line 28
Loop
Code:
<!--#INCLUDE FILE="connection.asp" -->
<%
DIM mySQL, objRS
mySQL = "SELECT * FROM news"
Set objRS = Server.CreateObject("ADODB.Recordset")
objRS.Open mySQL, objConn
DIM recCount
IF Not objRS.EOF THEN
Response.Write "<table width='100%'>"
recCount = 0
Do Until objRS.EOF
IF recCount Mod 3 = 0 THEN
IF recCount <> 0 THEN
Response.Write "</tr>"
Response.Write "<tr><td>"&objRS("Item")&"</td>"
ELSE
Response.Write "<td>"&objRS("Item")&"</td>"
END IF
recCount = recCount + 1
objRS.MoveNext
Loop
Response.Write"</tr></table>"
'ELSE
'Response.Write "Sorry, there are no records in our database."
'END IF
%>