Forums

ASP

This topic is locked

This should be easy

Posted 25 Jun 2001 22:20:55
1
has voted
25 Jun 2001 22:20:55 Kirby Paugh posted:
I not sure what to do here. I have it find all the rcords through a loop, but if there are no records it gives a EOF=True error .. any suggestions

<% Do Until Recordset1.EOF %>
<tr>
<td width="2%">
<input type="submit" name="Submit" value="Delete">
</td>
<td width="12%">
<div align="center"><%=(Recordset1.Fields.Item("Name".Value)%></div>
</td>
<td width="11%">
<div align="center"><%=(Recordset1.Fields.Item("Email".Value)%></div>
</td>
<td width="12%">
<div align="center"><%=(Recordset1.Fields.Item("Phone".Value)%></div>
</td>
<td width="15%">
<div align="center"><%=(Recordset1.Fields.Item("Start_Date".Value)%></div>
</td>
<td width="14%">
<div align="center"><%=(Recordset1.Fields.Item("End_Date".Value)%></div>
</td>
<td width="14%">
<div align="center"><%=(Recordset1.Fields.Item("Start_Time".Value)%></div>
</td>
<td width="20%">
<div align="center"><%=(Recordset1.Fields.Item("End_Time".Value)%></div>
</td>
</tr>
<% Recordset1.MoveNext %>
<% Loop %>
<% Recordset1.MoveFirst %>
</table>

Replies

Replied 26 Jun 2001 01:22:45
26 Jun 2001 01:22:45 Joel Martinez replied:
surround everything in an if statement:
-------------------

if not Recordset1.eof then

'--loop code here

end if

----------
Is this thing on?....

Reply to this topic