<% ' 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(MyConn)) = "OBJECT" then MyConn.Close Set MyConn = Nothing end if end sub ' End of subroutines. %> <% 'dim RS 'dim RS2 '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") %> <% strSQL = "SELECT * FROM Catalog ORDER BY Category ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=0" catstr = "All Items" If (request("S")="1") Then strSQL = "SELECT * FROM Catalog Where Category Like '%MakeNoise%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=1" catstr="MakeNoise" End If If (request("S")="2") Then strSQL = "SELECT * FROM Catalog Where Category Like '%Dwarfcraft%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=2" catstr="Dwarfcraft" End If If (request("S")="3") Then strSQL = "SELECT * FROM Catalog Where Category Like '%Select%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=3" catstr=" " tabstr="tab3.png" End If If (request("S")="4") Then strSQL = "SELECT * FROM Catalog Where Category Like '%intercom%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=4" catstr="_" End If If (request("S")="5") Then strSQL = "SELECT * FROM Catalog Where Category Like '%i/o%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=5" catstr="_" End If If (request("S")="6") Then strSQL = "SELECT * FROM Catalog Where Category Like '%z%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=6" catstr="_" End If If (request("S")="7") Then strSQL = "SELECT * FROM Catalog Where Category Like '%Free%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=7" catstr="Free!" End If If (request("S")="8") Then strSQL = "SELECT * FROM Catalog Where Category Like '%power%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=8" catstr="_" End If If (request("S")="9") Then strSQL = "SELECT * FROM Catalog Where Category Like '%enviro%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=9" catstr="_" End If If (request("S")="10") Then strSQL = "SELECT * FROM Catalog Where Category Like '%sera%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=10" catstr=" " End If If (request("S")="11") Then strSQL = "SELECT * FROM Catalog Where Category Like '%steel%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=11" catstr="_" End If If (request("S")="12") Then strSQL = "SELECT * FROM Catalog Where Category Like '%tiles%' ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=12" catstr="_" End If If (request("SQL")<>"") Then tmpsql=request("SQL") tmpsql="'%" & tmpsql & "%'" strSQL = "SELECT * FROM Catalog Where Category Like " & tmpsql strSQL = strSQL & " OR Description Like " & tmpsql strSQL = strSQL & " OR Description1 Like " & tmpsql strSQL = strSQL & " OR part_number Like " & tmpsql strSQL = strSQL & " ORDER BY part_number ASC" strSQL2 = "SELECT * FROM tabtoptext where tabindex=14" catstr=request("SQL") End If If (request("SearchString")<>"") Then tmpsql=request("SearchString") tmpsql= Server.HTMLEncode(tmpsql) strRedir="imagedex.asp?SQL=" strRedir= strRedir + tmpsql MyConn.Close response.redirect strRedir End If RS.Open strSQL, MyConn, 3 RS2.Open strSQL2, MyConn, 3 %>
  reprolabs.com
Catalog   -   <% response.write catstr%>     

Embedded Programming, Circuit Design, and Prototyping      

     <% RS2.MoveFirst If (NOT RS2.EOF) Then response.write RS2("blurbtext") End If If (request("SQL")<>"") Then tmpsql=request("SQL") response.write "    " response.write tmpsql response.write "" End If %>


<% tabstr="tab3.png" If (request("S")="") Then tabstr="tab1.png" If (request("S")="0") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="1") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="2") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="3") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="4") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="5") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="6") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="7") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="8") Then tabstr="tab1.png" Response.Write " <% tabstr="tab3.png" If (request("S")="9") 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 " <% tabstr="tab3.png" 'tabstr="lgrey040.jpg" If (request("S")="13") Then tabstr="tab1.png" Response.Write "
    " %> All Items" %> Rantbot " %> __________" %> __________" %> __________" %>   __________  " %> __________
   " %> __________ " %> __________ " %> __________ " %> __________ " %> __________ " %> __________ " %>

<% If (NOT RS.EOF) Then RS.MoveFirst End If k=0 colalt=0 Response.Write "
    " 'Response.Write "
" Response.Write "
" While (NOT RS.EOF) colalt=colalt + 1 if (colalt > 2) Then colalt = 0 if (colalt=0) Then colstr="lgrey040-1.jpg" if (colalt=1) Then colstr="lgrey040-2.jpg" if (colalt=2) Then colstr="lgrey040-3.jpg" colstr="lgrey040.jpg" 'Force background color Response.Write "" Response.Write "" Response.Write "" Response.Write "" Response.Write "" Response.Write "" k=k+1 'RS.MoveNext Response.Write "" Response.Write "" Response.Write "" Response.Write "" End If 'End of section conditional on no Product Selection Matrix. 'The following selection displays link to PSMbase if the product has a Product Selection Matrix... If (Not RS3.EOF) Then Response.Write "" Response.Write "" & (RS("Category")) Response.Write "    " Response.Write (RS("part_number")) & "" Response.Write "    " Response.Write (RS("Description1")) Response.Write "" k=k+1 Response.Write "" Response.Write "" Response.Write "" Response.Write "" End If 'End of section conditional on Product Selection Matrix available. RS3.Close RS.MoveNext Wend Response.Write "" Response.Write "
" Response.Write k Response.Write "." Response.Write "  " Response.Write "" img="rpl-icon-cntr2.gif" if (not isnull(RS("icon_name"))) Then img=Cstr(RS("icon_name")) end if Response.Write "" Response.Write "" Response.Write "    " Response.Write "" strSQL3 = "SELECT * FROM Product_Selection_Matrix where PSM like '%" & RS("part_number") & "%'" RS3.Open strSQL3, MyConn, 3 'If no Product Selection Matrix for this part number, display link to imagebase.asp page... If RS3.EOF Then Response.Write "" Response.Write "" & (RS("Category")) Response.Write "    " Response.Write (RS("part_number")) & "" Response.Write "    " Response.Write (RS("Description1")) Response.Write "" itemname = Cstr (RS("Description1")) itemname = Left(itemname, 80) bflag=0 if Not (IsNull(RS("Price"))) Then bflag=1 if (RS("Price")=0) Then bflag=0 'bflag=0 if (bflag=1) Then %>
"> ">
<% End If Response.Write "


" session("i")=0 %>

 Catalog by reprolabs.com, LLC


<% call cleanup %>