<% If Request("del") <> "" And IsNumeric(Request("del")) Then Con.Execute("UPDATE customers SET is_visible = 0 WHERE customer_id = " & MakeNumber(Request("del"))) End If SQL = "" SQL = "SELECT customer_id,created_dt,last_name+', '+first_name AS name,company,phone,email FROM customers WHERE " If Request("search") <> "" Then Search = Request("search") SQL = SQL & "(CAST(created_dt AS VARCHAR(50)) LIKE " & CSQL(Search & "%") & " OR " & _ "last_name+', '+first_name LIKE " & CSQL("%" & Search & "%") & " OR " & _ "company LIKE " & CSQL("%" & Search & "%") & " OR " & _ "phone LIKE " & CSQL("%" & Search & "%") & " OR " & _ "email LIKE " & CSQL("%" & Search & "%") & ") AND " End If SQL = SQL & "(is_visible = 1) ORDER BY last_name,first_name DESC" Set RS = Server.CreateObject("Adodb.Recordset") RS.Open SQL, Con, 3 If Not RS.EOF Then RS.PageSize = 20 If Request("page") <> "" And IsNumeric(Request("page")) Then Page = CInt(Request("page")) Else Page = 1 If Page > CInt(RS.PageCount) Then Page = CInt(RS.PageCount) RS.AbsolutePage = Page End If %> ACLUS Customer Edit
Engine Bearings Gaskets Order Information Contact Us
Customer Service Sales Rep's Regional Distribution Links
 

ACLUS | Admin | Members  [logout]

Search:     <% If Search <> "" Then %> clear search <% End If %>

<% If Not RS.EOF Then %> <% For A = 1 To RS.PageSize %> <% RS.MoveNext %> <% If RS.EOF Then Exit For %> <% Next %> <% Else %> <% End If %>
<% If Page > 1 Then %> «back   <% End If %> Currently on page    of <%=RS.PageCount%> <% If Page < CInt(RS.PageCount) Then %>   next» <% End If %>
Name Company Created Phone Email
">view [);">del] <%=RS("name")%> <%=RS("company")%> <%=FormatDateTime(RS("created_dt"), 2)%> <%=RS("phone")%> "><%=RS("email")%>
Sorry, no members found.
 
<% If Page > 1 Then %> «back   <% End If %> Currently on page    of <%=RS.PageCount%> <% If Page < CInt(RS.PageCount) Then %>   next» <% End If %>
<% RS.Close: Set RS = Nothing %> <% KillCon %>