Hello all, the below code is giving me an error of
Microsoft VBScript runtime error '800a0009'
Subscript out of range: '17'
Not sure where it is at - below is my code with the error line marked. Thank you in advance for any assistance.
<%
Dim fieldNames()
ReDim fieldNames( rstemp.fields.count-1 )
Response.Write "<TR>" & vbCrLf
For i = 0 To rstemp.fields.count - 1
curname = rstemp.fields(i).name
fieldNames(i) = curname
Response.Write "<TH>" & curname & "</TH>" & vbCrLf
Next
Response.Write "</TR>" & vbCrLf
' Now lets grab all the records
alldata=rstemp.getrows
Call CloseAll
numcols=ubound(alldata,1)
numrows=ubound(alldata,2)
FOR rowcounter= 0 TO numrows
response.write "<tr>" & vbcrlf
FOR colcounter=0 to numcols
thisfield=alldata(colcounter,rowcounter)
if isnull(thisfield) then
thisfield=shownull
end if
if trim(thisfield)="" then
thisfield=showblank
End If
%>
<TD Valign="top">
<INPUT Name="<%=fieldNames(i)%>" Value="<%=thisfield%>" Class="inputbox">
</TD>
<%
Next
response.write "</tr>" & vbcrlf
NEXT
response.write "</table>"
%> "Damn the torpedoes, full speed ahead!"
-Adm. James Farragut
Stuart
Microsoft VBScript runtime error '800a0009'
Subscript out of range: '17'
Not sure where it is at - below is my code with the error line marked. Thank you in advance for any assistance.
<%
Dim fieldNames()
ReDim fieldNames( rstemp.fields.count-1 )
Response.Write "<TR>" & vbCrLf
For i = 0 To rstemp.fields.count - 1
curname = rstemp.fields(i).name
fieldNames(i) = curname
Response.Write "<TH>" & curname & "</TH>" & vbCrLf
Next
Response.Write "</TR>" & vbCrLf
' Now lets grab all the records
alldata=rstemp.getrows
Call CloseAll
numcols=ubound(alldata,1)
numrows=ubound(alldata,2)
FOR rowcounter= 0 TO numrows
response.write "<tr>" & vbcrlf
FOR colcounter=0 to numcols
thisfield=alldata(colcounter,rowcounter)
if isnull(thisfield) then
thisfield=shownull
end if
if trim(thisfield)="" then
thisfield=showblank
End If
%>
<TD Valign="top">
<INPUT Name="<%=fieldNames(i)%>" Value="<%=thisfield%>" Class="inputbox">
</TD>
<%
Next
response.write "</tr>" & vbcrlf
NEXT
response.write "</table>"
%> "Damn the torpedoes, full speed ahead!"
-Adm. James Farragut
Stuart