Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error message unexplained

Status
Not open for further replies.

new2programming

Programmer
Joined
Mar 6, 2003
Messages
4
Location
US
Microsoft VBScript compilation error '800a03ea'

Syntax error

/Training_Dept/RPTPOTA.asp, line 40

RS.MoveNext Wend RS.Close Set RS = Nothing
------------^
Here is the error message that I receive I will provide the code below if any one has suggestion for a fix to this problem please sumbit.

Code:

<%@Language=VBScript%>
<%Response.Buffer = True%>
<!--#include file=&quot;include/RPTConnect.asp&quot;-->
<html>

<head>
<title>Performance Overview by Class (Totals) Report</title>
</head>

<body background=&quot;WB00760_.gif&quot;>

<hr>

<hr>

<p><font size=&quot;5&quot;>Performance Overview by Class (Totals) Report</font></p>

<hr>

<hr>
<!--#include file=&quot;include/menu.asp&quot;-->
<%
LocCity = Request.Form(&quot;LocCity&quot;)

If LocCity = &quot;&quot; Then



SQL = &quot; Select Distinct LocCity From Classes &quot;

Set rs=Server.CreateObject(&quot;ADODB.RecordSet&quot;)
rs.Open SQL, MyDSN


%>

<form Method=&quot;Post&quot;>
<p><select Name=&quot;LocCity&quot; size=&quot;1&quot;>
<option Selected>--Select City-- <%While Not RS.EOF%> </option>
<option value=&quot;<%=RS(&quot;LocCity&quot;)%>&quot;> <%=RS.Fields(&quot;LocCity&quot;)%> <% RS.MoveNext Wend RS.Close Set RS = Nothing %> </option>
</select> <input type=&quot;submit&quot; name=&quot;btnSearch&quot; value=&quot;Search&quot;> </p>
</form>
<%
Else



SQLT = &quot;Select Distinct TName From Classes Where LocCity = '&quot;&LocCity&&quot;'&quot;

Set rsT=Server.CreateObject(&quot;ADODB.RecordSet&quot;)
rsT.Open SQLT, MyDSN


%>

<form action=&quot;RPTPOTACLSTotRD2.asp?Yr=<%=varYrA%>&quot; method=&quot;Post&quot;>
<input type=&quot;hidden&quot; name=&quot;LocCity&quot; value=&quot;<%=LocCity%>&quot;><p><select name=&quot;TName&quot; size=&quot;1&quot;>
<option selected>--Select Name-- <%While Not rsT.EOF%> </option>
<option value=&quot;<%=rsT(&quot;TName&quot;)%>&quot;> <%=rsT.Fields(&quot;TName&quot;)%> <% rsT.MoveNext Wend rsT.Close Set rsT = Nothing %> </option>
</select> <input type=&quot;submit&quot; name=&quot;btnSearch&quot; value=&quot;Search&quot;> </p>
</form>
<%End If%>
</body>
</html>
 
This is the VB5/6 forum. You will do better in forum329 (it's the VBScript forum)
________________________________________________________________
If you want to get the best response to a question, please check out FAQ222-2244 first

'People who live in windowed environments shouldn't cast pointers.'
 
write the statement like this

<% rsT.MoveNext: Wend :rsT.Close Set rsT = Nothing %>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top