%@LANGUAGE="VBSCRIPT"%> <% Dim rsRedDwarfFanClubMerchandise Dim rsRedDwarfFanClubMerchandise_numRows Set rsRedDwarfFanClubMerchandise = Server.CreateObject("ADODB.Recordset") rsRedDwarfFanClubMerchandise.ActiveConnection = MM_cnMerchandise_STRING rsRedDwarfFanClubMerchandise.Source = "SELECT * FROM reddwarffanclub_merchandise ORDER BY Type ASC" rsRedDwarfFanClubMerchandise.CursorType = 0 rsRedDwarfFanClubMerchandise.CursorLocation = 2 rsRedDwarfFanClubMerchandise.LockType = 1 rsRedDwarfFanClubMerchandise.Open() rsRedDwarfFanClubMerchandise_numRows = 0 %> <% Dim Repeat1__numRows Dim Repeat1__index Repeat1__numRows = -1 Repeat1__index = 0 rsRedDwarfFanClubMerchandise_numRows = rsRedDwarfFanClubMerchandise_numRows + Repeat1__numRows %> <% ' *** Recordset Stats, Move To Record, and Go To Record: declare stats variables Dim rsRedDwarfFanClubMerchandise_total Dim rsRedDwarfFanClubMerchandise_first Dim rsRedDwarfFanClubMerchandise_last ' set the record count rsRedDwarfFanClubMerchandise_total = rsRedDwarfFanClubMerchandise.RecordCount ' set the number of rows displayed on this page If (rsRedDwarfFanClubMerchandise_numRows < 0) Then rsRedDwarfFanClubMerchandise_numRows = rsRedDwarfFanClubMerchandise_total Elseif (rsRedDwarfFanClubMerchandise_numRows = 0) Then rsRedDwarfFanClubMerchandise_numRows = 1 End If ' set the first and last displayed record rsRedDwarfFanClubMerchandise_first = 1 rsRedDwarfFanClubMerchandise_last = rsRedDwarfFanClubMerchandise_first + rsRedDwarfFanClubMerchandise_numRows - 1 ' if we have the correct record count, check the other stats If (rsRedDwarfFanClubMerchandise_total <> -1) Then If (rsRedDwarfFanClubMerchandise_first > rsRedDwarfFanClubMerchandise_total) Then rsRedDwarfFanClubMerchandise_first = rsRedDwarfFanClubMerchandise_total End If If (rsRedDwarfFanClubMerchandise_last > rsRedDwarfFanClubMerchandise_total) Then rsRedDwarfFanClubMerchandise_last = rsRedDwarfFanClubMerchandise_total End If If (rsRedDwarfFanClubMerchandise_numRows > rsRedDwarfFanClubMerchandise_total) Then rsRedDwarfFanClubMerchandise_numRows = rsRedDwarfFanClubMerchandise_total End If End If %> <% ' *** Recordset Stats: if we don't know the record count, manually count them If (rsRedDwarfFanClubMerchandise_total = -1) Then ' count the total records by iterating through the recordset rsRedDwarfFanClubMerchandise_total=0 While (Not rsRedDwarfFanClubMerchandise.EOF) rsRedDwarfFanClubMerchandise_total = rsRedDwarfFanClubMerchandise_total + 1 rsRedDwarfFanClubMerchandise.MoveNext Wend ' reset the cursor to the beginning If (rsRedDwarfFanClubMerchandise.CursorType > 0) Then rsRedDwarfFanClubMerchandise.MoveFirst Else rsRedDwarfFanClubMerchandise.Requery End If ' set the number of rows displayed on this page If (rsRedDwarfFanClubMerchandise_numRows < 0 Or rsRedDwarfFanClubMerchandise_numRows > rsRedDwarfFanClubMerchandise_total) Then rsRedDwarfFanClubMerchandise_numRows = rsRedDwarfFanClubMerchandise_total End If ' set the first and last displayed record rsRedDwarfFanClubMerchandise_first = 1 rsRedDwarfFanClubMerchandise_last = rsRedDwarfFanClubMerchandise_first + rsRedDwarfFanClubMerchandise_numRows - 1 If (rsRedDwarfFanClubMerchandise_first > rsRedDwarfFanClubMerchandise_total) Then rsRedDwarfFanClubMerchandise_first = rsRedDwarfFanClubMerchandise_total End If If (rsRedDwarfFanClubMerchandise_last > rsRedDwarfFanClubMerchandise_total) Then rsRedDwarfFanClubMerchandise_last = rsRedDwarfFanClubMerchandise_total End If End If %>
Red Dwarf Fan Club Merchandise |
| Description | Picture |
<%=(rsRedDwarfFanClubMerchandise.Fields.Item("Type").Value)%> <%=(rsRedDwarfFanClubMerchandise.Fields.Item("Description").Value)%> <%=(rsRedDwarfFanClubMerchandise.Fields.Item("Notes").Value)%> |
|
| <%=(rsRedDwarfFanClubMerchandise_total)%> items listed | back |