Count Lines in Pages

Contents of Page: whodidcheckcash.asp Number of Lines: 204 Last Modified: 3/7/2026 4:19:30 PM
0001: 	<% @Language = "VBScript" %>
0002: <!-- #include FILE="include/adovbs.inc" -->
0003: <!-- #include FILE="include/constants.inc" -->
0004: <!-- #include FILE="include/ReturnPageSet.inc" -->
0005: <%
0006: 		user = Request.Cookies("user")
0007: 	yr = Request.QueryString("yr")
0008: 	If yr = "" Then yr = season
0009:    	sortStr = Request.QueryString("sort")
0010:    	inputsort = Request.QueryString("sort")	
0011: 		AddCondition = ""
0012: 	If Right(SortStr,4) = "Used" Then
0013: 	   AddCondition = "AND " & SortStr & " <> False "
0014: 	   Sortstr = "Name"
0015: 	End If
0016: 
0017: 	
0018: 	If sortStr = "" Then sortStr = "Name"
0019: 	Select Case sortStr
0020: 		Case "FirstName,City,State,EmailAddress"
0021: 			sortStr = sortStr 
0022: 		Case "NumEntries"
0023: 			sortStr = sortStr & " DESC " 
0024: 		
0025: 	End Select
0026: 	
0027: 	Set rs = Server.CreateObject("ADODB.Recordset")
0028: 	
0029: 	If inputsort = "CheckUsed" Then
0030: 	
0031: 	sqlString = "SELECT * FROM mmEntries " & _
0032: 			"WHERE Season = " & yr & " " & _
0033: 			"AND PaidEntries > 0 " & _
0034: 			"AND PayPalUsed = False  " & _
0035: 			"AND VenMoUsed = False  " & _
0036: 			"AND ZelleUsed = False  " & _
0037: 			"AND CashUsed = False " & _		
0038: 			"ORDER BY Name, Firstname "
0039: 			
0040:     Else			
0041: 	
0042: 	sqlString = "SELECT * FROM mmEntries " & _
0043: 			"WHERE Season = " & yr & " " & _
0044: 			"AND PaidEntries > 0 " & _
0045: 			AddCondition & " " & _
0046: 			"ORDER BY " & sortStr & ", FirstName"
0047: 			
0048:      End If		
0049: 
0050:  Response.Write(SqlString & "<br>")	 
0051: 
0052: 	rs.Open sqlString, conn, adOpenDynamic, adLockOptimistic, adCmdText
0053: 
0054: 
0055: 
0056: 	totreg = 0
0057:    totentries = 0
0058:    totpaid = 0
0059:    totmade = 0
0060: 
0061: %>
0062: <html>
0063: 
0064: <head>
0065: <title>March Madness - Who Paid Cash/Check</title>
0066: <link href="mm.css" rel="stylesheet" type="text/css">
0067: </head>
0068: 
0069: <body bgcolor="#ffffff">
0070: 
0071: <table cellspacing="1" border="0" cellpadding="0" width="700" height="53">
0072:   <tr>
0073:     <td class="norm" colspan="2">Season: <b><%= season %></b></td><td height="4" colspan="12"><p align="center"><font face="Arial" size="2"><img
0074:     src="images/clear.gif" width="1" height="4">Check / Cash Payments Received -   
0075: 			&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="whoisdeadbeat_m.asp?sort=ID">Mobile Unpaid</a>
0076: 	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="whoisin.asp">Everyone</a>
0077: 
0078: <img src="images/clear.gif"
0079:     width="1" height="4"></font></td>
0080:   </tr>
0081:  
0082:   <tr bgcolor="#577fbe">
0083:     <td class="small" align="center" height="19" width="5%"></td>
0084:     <td class="norm" align="center" height="19" width="15%"><a href="whodidCheckCash.asp?sort=Name" class="smallUndl">Last Name</a></td>
0085:     <td class="norm" align="center" height="19" width="15%"><a href="whodidCheckCash.asp?sort=FirstName" class="smallUndl">First Name</a></td>
0086:     <td class="norm" align="center" height="19" width="20%"><a href="whodidCheckCash.asp?sort=City" class="smallUndl">City</a></td>
0087:     <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=State" class="smallUndl">St</a></td>
0088:     <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=NumEntries" class="smallUndl">Entries</a></td>
0089:     <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=CheckUsed">Check</a></td>
0090:     <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=PayPalUsed">PayPal</a></td>
0091:  <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=VenMoUsed">VenMo</a></td>
0092:  <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=ZelleUsed">Zelle</a></td> 
0093:  <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=CashUsed">Cash</td>
0094:  <td class="norm" align="center" height="19" width="5%"><a href="whodidCheckCash.asp?sort=AmountDonatedToCOH" class="smallUndl">Donated</a></td>
0095: 
0096: <%	bgcolor = "#e8e8e8"
0097: 
0098: 			TotCheckAmount = 0
0099: 			TotPaidAmount = 0
0100: 			TotCOHAmount = 0
0101: 
0102: 		Do Until rs.EOF
0103: 		emailaddr = rs("EmailAddress").value
0104: 		
0105: 			If bgcolor = "#e8e8e8" Then
0106: 				bgcolor = "#ffffff"
0107: 			Else
0108: 				bgcolor = "#e8e8e8"
0109: 			End If
0110: 			NumEntries = rs("NumEntries").Value
0111: 			paid = rs("PaidEntries").Value
0112: 			CashUsed = Rs("CashUsed").Value
0113: 			PayPalUsed = Rs("PayPalUsed").Value
0114: 			VenMoUsed = Rs("VEnMoUsed").Value
0115: 			ZelleUsed = Rs("ZelleUsed").Value
0116: 			ToCOH = Rs("AmountDonatedToCOH").Value
0117: 			CheckAmount = ""
0118: 			CashAmount = ""
0119: 			PayPalAmount = ""
0120: 			VenMoAmount = ""
0121: 			ZelleAmount = ""
0122: 
0123: 			PaidAmount = paid * 20
0124: 			If CashUsed = True Then
0125: 			CashAmount = PaidAmount
0126: 			TotCashAmount = TotCashAmount + PaidAmount
0127: 			ElseIf VenMoUsed = True Then 
0128: 			VenMoAmount = PaidAmount
0129: 			TotVenMoAmount = TotVenMoAmount + PaidAmount
0130: 			ElseIf PayPalUsed = True Then
0131: 			PayPalAmount = PaidAmount
0132: 			TotPayPalAmount = TotPayPalAmount + PaidAmount
0133: 			ElseIf ZelleUsed = True Then
0134: 			ZelleAmount = PaidAmount
0135: 			TotZelleAmount = TotZelleAmount + PaidAmount
0136: 			Else
0137: 			CheckAmount = PaidAmount
0138: 			TotCheckAmount = TotCheckAmount + PaidAmount
0139: 			End If
0140: 			If ToCOH = "" Then
0141: 			ToCOH = 0
0142: 			End If
0143: 			ToCOH = ToCOH * 1
0144: 			TotCOHAmount = TotCOHAmount + ToCOH
0145: 			totreg = totreg + 1
0146: 			totmade = totmade + totPicksMade
0147: 				If ToCOH = 0 Then
0148: 			ToCOH = ""
0149: 			End If
0150: 	%>
0151: 
0152:   </tr>
0153: 
0154:  <% If CashUsed = False Then %>
0155:   <tr bgcolor="<%= bgcolor %>" height="20">
0156: <% Else 
0157: totPaid = TotPaid + (NumEntries * 20)
0158: 
0159: %>
0160:   <tr bgcolor="#ccff33" height="20">
0161: <% End If %>
0162:     <td class="norm" align="center" ><%= totreg %></td>
0163:     <td class="norm" align="left" ><%= rs("Name").Value %></td>
0164:     <td class="norm" align="left" ><%= rs("FirstName").Value %></td>
0165:     <td class="norm" align="left" ><%= rs("City").Value %></td>
0166:     <td class="norm" align="left" ><%= rs("State").Value %></td>
0167:     <td class="norm" align="center" ><%= NumEntries %></td>
0168:     <td class="norm" align="center" ><%= CheckAmount %></td>
0169:     <td class="norm" align="center" ><%= PayPalAmount %></td>
0170:     <td class="norm" align="center" ><%= VenMoAmount %></td>
0171:     <td class="norm" align="center" ><%= ZelleAmount %></td>
0172:     <td class="norm" align="center" ><%= CashAmount %></td>
0173:     <td class="norm" align="center" ><%= ToCOH %></td>
0174: 
0175:     <td class="norm" align="left" ><a href="editmmEntries.asp?from=deadbeat&amp;id=<%= rs("ID").Value %>" class="smallblueUndl"><%= rs("ID").Value %></a></td>
0176: </td>
0177: 
0178:   </tr>
0179: <%	   totentries = totentries + NumEntries
0180: 
0181:       rs.MoveNext
0182: 		Loop
0183: 		If bgcolor = "#e8e8e8" Then
0184: 				bgcolor = "#ffffff"
0185: 			Else
0186: 				bgcolor = "#e8e8e8"
0187: 			End If
0188: 
0189: 		rs.Close
0190: 		Set rs = Nothing	%>
0191:   <tr bgcolor="<%= bgcolor %>">
0192:     <td class="norm" align="left" colspan="2" >Total Reg:<b><%= totreg %></b></td>
0193:     <td class="norm" align="left" colspan="3" ><p align="right">Total Entries:</td>
0194:     <td class="norm" align="center" ><% = totentries %></td>
0195:     <td class="norm" align="right"><b><% = TotCheckAmount %></td>
0196:     <td class="norm" align="right"><b><% = TotPayPalAmount %></td>
0197: 	<td class="norm" align="right"><b><% = TotVenMoAmount %></td>
0198:     <td class="norm" align="right"><b><% = TotZelleAmount %></td>
0199:     <td class="norm" align="right"><b><% = TotCashAmount  %></td>
0200:     <td class="norm" align="right"><b><%= TotCOHAmount %></td>
0201:   </tr>
0202: </table>
0203: </body>
0204: </html>