S
shank
Trying to learn and use GetRows.
I'm using the example on: http://www.aspdev.org/articles/asp-getrows/
Without GetRows(), the below recordset will return 100+ manufacturer names.
With GetRows(), I get nothing.
What am I missing?
thanks
<%
Dim rsManuf
Dim rsManuf_numRows
Set rsManuf = Server.CreateObject("ADODB.Recordset")
rsManuf.ActiveConnection = ConnectString
rsManuf.Source = "{call stp_Manuf}"
rsManuf.CursorType = 0
rsManuf.CursorLocation = 2
rsManuf.LockType = 1
rsManuf.Open()
rsManuf_numRows = 0
If Not rsManuf.EOF Then
' Gets all the records
arrResultSet = rsManuf.GetRows()
End If
%>
<%
rsManuf.Close()
Set rsManuf = Nothing
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
</head>
<body>
<%
' Retrieve the total # of rows
iRowNumber = ubound(arrResultSet,2)
' Loop through the array holding the result set and display the data
For iCounter= 0 to iRowNumber
Response.Write(arrResultSet(1,iCounter) & "")
Next
%>
</body>
</html>
I'm using the example on: http://www.aspdev.org/articles/asp-getrows/
Without GetRows(), the below recordset will return 100+ manufacturer names.
With GetRows(), I get nothing.
What am I missing?
thanks
<%
Dim rsManuf
Dim rsManuf_numRows
Set rsManuf = Server.CreateObject("ADODB.Recordset")
rsManuf.ActiveConnection = ConnectString
rsManuf.Source = "{call stp_Manuf}"
rsManuf.CursorType = 0
rsManuf.CursorLocation = 2
rsManuf.LockType = 1
rsManuf.Open()
rsManuf_numRows = 0
If Not rsManuf.EOF Then
' Gets all the records
arrResultSet = rsManuf.GetRows()
End If
%>
<%
rsManuf.Close()
Set rsManuf = Nothing
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
</head>
<body>
<%
' Retrieve the total # of rows
iRowNumber = ubound(arrResultSet,2)
' Loop through the array holding the result set and display the data
For iCounter= 0 to iRowNumber
Response.Write(arrResultSet(1,iCounter) & "")
Next
%>
</body>
</html>