<%@ LANGUAGE="VBSCRIPT" %> <% ' First, the subroutines... sub cleanup if ucase(TypeName(RS)) = "OBJECT" then RS.Close Set RS=nothing End If if ucase(TypeName(RS2)) = "OBJECT" then RS2.Close Set RS2=nothing End If if ucase(TypeName(RS3)) = "OBJECT" then RS3.Close Set RS3=nothing End If if ucase(TypeName(RS4)) = "OBJECT" then RS4.Close Set RS4=nothing End If if ucase(TypeName(RS5)) = "OBJECT" then RS5.Close Set RS5=nothing End If if ucase(TypeName(RS6)) = "OBJECT" then RS6.Close Set RS6=nothing End If if ucase(TypeName(MyConn)) = "OBJECT" then MyConn.Close Set MyConn = Nothing end if end sub ' End of subroutines. %> Automation Displays Catalog <% dim RS dim RS2 dim RS3 dim RS4 dim RS5 dim RS6 dim MyConn call cleanup 'Just in case. Set MyConn = Server.CreateObject("ADODB.Connection") MyConn.Open Application("Database1_ConnectionString") Set RS = Server.CreateObject ("ADODB.Recordset") Set RS2 = Server.CreateObject ("ADODB.Recordset") Set RS3 = Server.CreateObject ("ADODB.Recordset") Set RS4 = Server.CreateObject ("ADODB.Recordset") Set RS5 = Server.CreateObject ("ADODB.Recordset") Set RS6 = Server.CreateObject ("ADODB.Recordset") strSQL = "SELECT * FROM Catalog ORDER BY Category ASC" If (request("PN")<>"") Then strSQL = "SELECT * FROM Catalog where part_number LIKE " strSQL = strSQL & "'%" & request("PN") & "%'" strSQL4 = "SELECT * FROM Options where part_number LIKE " strSQL4 = strSQL4 & "'%" & request("PN") & "%'" strSQL5 = "SELECT * FROM flipbook where image_name LIKE " strSQL5 = strSQL5 & "'%" & request("PN") & "%'" End If If (Request("k")<>"") Then tempk=request("k") strSQL = "SELECT * FROM Catalog where part_number LIKE " strSQL = strSQL & "'%" & tempk & "%'" strSQL4 = "SELECT * FROM Options where part_number LIKE " strSQL4 = strSQL4 & "'%" & tempk & "%'" strSQL5 = "SELECT * FROM flipbook where image_name LIKE " strSQL5 = strSQL5 & "'%" & tempk & "%'" End If RS.Open strSQL, MyConn, 3 If (RS.EOF) Then Response.redirect "psmerr.html" If (not RS.EOF) Then RS.MoveFirst psmatrix=request("PSM") if psmatrix="" Then Response.redirect "psmerr.html" 'strSQL6 = "SELECT * FROM Product_Selection_Matrix where PSM LIKE '%J924%' ORDER BY short_description, value ASC" strSQL6 = "SELECT * FROM Product_Selection_Matrix where PSM LIKE '%" strSQL6 = strSQL6 & psmatrix strSQL6 = strSQL6 & "%' ORDER BY short_description, value ASC" RS6.Open strSQL6, MyConn, 3 If (RS6.EOF) Then Response.redirect "psmerr.html" If (not RS6.EOF) Then RS6.MoveFirst %>
  Automation Displays, Inc.
Catalog Part Series- <% Response.write "" %> <% Response.Write tmpstrs Response.Write "" %>     

Your Source for Graphic Control Panels    
Product Selection Matrix for <% If Not RS6.EOF Then Response.Write RS6("PSM") %>
"> "> <% option1="none" 'Setup defaults. option2="none" 'Setup defaults. option3="none" 'Setup defaults. option4="none" 'Setup defaults. option5="none" 'Setup defaults. option6="none" 'Setup defaults. If Not RS6.EOF Then odex=1 'odex counts each option group 1-6. OK to have less, but 6 is max. While ((Not RS6.EOF) AND (odex < 7)) %>
Part #  <% If Not RS6.EOF Then Response.Write RS6("PSM") %>-
<% Response.Write RS6("short_description") dname = "short_description" + Cstr(odex) 'Column IDs will be passed as short_description1, etc. %> ">
<% oname = "option" + Cstr(odex) 'Radio button values will be passed as option1, option2, etc. %> <% checkcode="" txt1 = CStr(request(oname)) if (txt1="") Then checkcode="checked" 'default to 1st option for new user. if request(oname)=RS6("code") Then checkcode="checked" %> <% RS6.MoveNext new_description="?" If Not RS6.EOF Then new_description=RS6("short_description") temp_description=new_description While new_description=temp_description %> <% checkcode="" if request(oname)=RS6("code") Then checkcode="checked" %> <% If Not RS6.EOF Then RS6.MoveNext new_description="?" If Not RS6.EOF Then new_description=RS6("short_description") Wend %>
<%=RS6("code")%>- value="<%=RS6("code")%>" <%=checkcode%>> <%=RS6("value")%>
<%=RS6("code")%>-" <%=checkcode%>> <%=RS6("value")%>
<% odex = odex + 1 oname = "option" + Cstr(odex) Wend End If %>

<% tabstr="tab3.png" 'If (RS("Category")="All Items") Then tabstr="tab1.png" If (request("S")="0") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'If (RS("Category")="Audio") Then tabstr="tab1.png" If (request("S")="1") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'If (RS("Category")="Numeric Display") Then tabstr="tab1.png" If (request("S")="2") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'If (RS("Category")="Hardware") Then tabstr="tab1.png" If (request("S")="3") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'If (RS("Category")="Intercom") Then tabstr="tab1.png" If (request("S")="4") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'If (RS("Category")="I/O Card") Then tabstr="tab1.png" If (request("S")="5") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'If (RS("Category")="Z-Card") Then tabstr="tab1.png" If (request("S")="6") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'If (RS("Category")="Free!") Then tabstr="tab1.png" If (request("S")="7") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'tabstr="lgrey040.jpg" If (request("S")="8") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'tabstr="lgrey040.jpg" If (request("S")="10") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'tabstr="lgrey040.jpg" If (request("S")="11") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" 'tabstr="lgrey040.jpg" If (request("S")="12") Then tabstr="tab1.png" Response.Write "
" %> All Items" %> Audio" %> Displays" %> Hardware" %> Intercom" %>   i/O  " %> Z-Card
" %> Free! " %> <% tabstr="tab3.png" If (request("S")="9") Then tabstr="tab1.png" Response.Write "" %> Environment" %> SERA" %> Steel " %> <% tabstr="tab3.png" 'tabstr="lgrey040.jpg" If (request("S")="13") Then tabstr="tab1.png" Response.Write "" %>

  3533 N. White Ave. Eau Claire, WI 54703  715.834.9595 (voice)  715.834.9596 (fax)  adi@adipanel.com
HOME   ·   CONTACT   ·   HELP  
 
<% call cleanup %>