The below script adds items to an array, the problem is only the last entry will display when calling the subroutine ShowOrder. Please help me with this battle
<% Option Explicit
%>
<style fprolloverstyle>A:hover {color: #0000FF; text-decoration: overline underline}
</style>
<% 'Order.asp
Sub AddItem(PartNumber, Item, Description, Price, Quantity, iCount)
'ReDim Preserve aPartNumber(iCount)
'aPartNumber(iCount) = PartNumber
'ReDim Preserve aItem(iCount)
'aItem(iCount) = Item
'ReDim Preserve aDescription(iCount)
'aDescription(iCount) = Description
'ReDim Preserve aPrice(iCount)
'aPrice(iCount) = Price
'ReDim Preserve aQtyOrder(iCount)
'aQtyOrder(iCount) = Quantity
'ShowOrder aPartNumber, aItem, aDescription, aPrice, aQtyOrder
End Sub
'**************************************
Sub ShowOrder
'Dim i 'as Integer
Dim sTotal
Dim sExtension
Dim sShipCharge
Dim var1
sShipCharge = 15.00
ID1 = Request("sID1"
ID2 = Request("sID2"
%>
<body vlink="#0000FF" alink="#0000FF">
<table border="1" cellpadding="2" style="border-left-color: #0000FF; border-top-color: #0000FF" width="100%" bordercolorlight="#FF0000" bordercolordark="#0000FF">
<tr>
<td bgcolor="#F5F5F5" width="60">
<font face="Arial" color="#000080">
<b>
<font size="2">Part#</font>
</b>
</td>
<td bgcolor="#F5F5F5" width="75">
<font color="#000080">
<b>
<font size="2" face="Arial">Item</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="299">
<font color="#000080">
<b>
<font size="2" face="Arial">Description</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="3">
<font color="#000080">
<b>
<font size="2" face="Arial">Quantity Ordered</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="7">
<b>
<font size="2" face="Arial" color="#000080">Price</font>
</b>
</td>
</tr>
<form name="AddItem">
<%
stotal = 0
for i=0 to iCount
'if aPartNumber(i) <> "" then
sExtension = aQtyOrder(i) * aPrice(i)
sTotal = sTotal + sExtension
%>
<tr>
<td width="60"><font size="2" color="#000080"><%=aPartNumber(i)%> </font></td>
<td width="75"><font size="2" color="#000080"><%=aItem(i)%> </font></td>
<td width="299"><font size="2" color="#000080"><%=aDescription(i)%> </font></td>
<td width="3" align="Right"><font size="2" color="#000080"><%=aQtyOrder(i)%></font></td>
<td width="7"><font size="2" color="#000080"><%=FormatCurrency(aPrice(i))%> </font></td>
</tr>
<input type="hidden" name=part<%=i%> value=<%=aPartNumber(i)%>>
<input type="hidden" name=item<%=i%> value=<%=aItem(i)%>>
<input type="hidden" name=description<%=i%> value=<%=aDescription(i)%>>
<input type="hidden" name=qty<%=i%> value=<%=aQtyOrder(i)%>>
<input type="hidden" name=price<%=i%> value=<%=aPrice(i)%>>
<%
'end if
Next 'i
iCount=iCount + 1
sTotal = sTotal + sShipCharge
%>
</form>
<tr>
<td width="60"></td>
<td width="75"></td>
<td width="299"></td>
<td bgcolor="#F5F5F5" width="3"><b><font color="#000080">Delivery Charge:</font></b></td>
<td width="7"> <font size="2" color="#000080"><%=FormatCurrency(sShipCharge)%> </font></td>
</tr>
<tr>
<td width="60"><a href="Order.asp?action=ShowCatelog&Count=<%=iCount%>&sID1=<%=ID1%>&sID2=<%=ID2%>">Previous</a></td>
<td width="75"><a href="Order.asp?action=Nothing&Count=<%=iCount%>">Item Search</a></td>
<td width="299"></td>
<td bgcolor="#F5F5F5" width="3"><b><font color="#000080">Total:</font></b></td>
<td width="7"> <font size="2" color="#000080"><%=FormatCurrency(sTotal)%> </font></td>
</tr>
<form name="ShowOrder1">
<input type="hidden" name="sID1" value=<%=ID1%>>
<input type="hidden" name="sID2" value=<%=ID2%>>
</form>
<%
End Sub
' *******Item Search
Sub ItemSearch()
Dim objDC, objRS, objRS2
iCount = CInt(Request.QueryString("Count")
' Create and establish data connection
Set objDC = Server.CreateObject("ADODB.Connection"
objDC.ConnectionTimeout = 15
objDC.CommandTimeout = 30
'Use this line to use Access
objDC.Open "DSN=JerryLabant"
' Create recordset and retrieve values using the open connection
Set objRS = Server.CreateObject("ADODB.Recordset"
Set objRS2 = Server.CreateObject("ADODB.Recordset"
objRS.Open "Makes", objDC, 0, 1
objRS2.Open "Categories", objDC, 0, 1
' Loop through recordset and display results
%>
<form name="form1" action="Order.asp?action=ShowCatelog&Count=<%=iCount%>" method="Post">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="50%" nowrap>
<p align="Center"><font color="#000080">Select Vehicle Make</font>:
<select name="sID1" style="color: #000080">
<option value="0">*ALL</option>
<%
' Continue until we get to the end of the recordset.
Do While Not objRS.EOF
' For each record we create a option tag and set it's value to the employee id
' The text we set to the employees first name combined with a space and then their last name
%>
<option value="<%= objRS.Fields("MNumber" %>"><%= objRS.Fields("MDescription" %></option>
<%
' Get next record
objRS.MoveNext
Loop
%>
</select>
</p>
</td>
<td width="50%" nowrap>
<p align="Center"> <font color="#000080">Select Category:</font>
<select name="sID2" style="color: #000080">
<option value="0">*ALL</option>
<%
' Continue until we get to the end of the recordset.
Do While Not objRS2.EOF
' For each record we create a option tag and set it's value to the employee id
' The text we set to the employees first name combined with a space and then their last name
%>
<option value="<%= objRS2.Fields("CNumber" %>"><%= objRS2.Fields("CDescription" %></option>
<%
' Get next record
objRS2.MoveNext
Loop
%>
</select>
</p>
</td>
</tr>
</table>
<p align="Center">
<input type="Submit" value="Search">
</p>
<input type="hidden" name="Count" value=<%=iCount%>>
</form>
<%
End Sub
Sub ShowCatelog(ID1, ID2)
Dim boolCanRun
Dim objConn
Dim objRS
Dim strSQL
Dim strFilter1
Dim strFilter2
Dim intRecordCount
Dim color
Dim var1
boolCanRun = true
color = "#CCCCCC"
strFilter1 = ID1
strFilter2 = ID2
iCount = CInt(Request.QueryString("Count")
If boolCanRun then
set objConn = Server.createObject("ADODB.Connection"
objConn.Open "DSN=JerryLabant"
if strFilter1 = 0 AND strFilter2 = 0 then
set objRS = objConn.Execute("select * from ItemMaster Order By MakeNumber"
end if
if strFilter1 = 0 AND strFilter2 <> 0 then
set objRS = objConn.Execute("select * from ItemMaster where CategoryNumber =" & strFilter2 &" Order By MakeNumber"
end if
if strFilter1 <> 0 AND strFilter2 = 0 then
set objRS = objConn.Execute("select * from ItemMaster where MakeNumber =" & strFilter1 &" Order By MakeNumber"
end if
if strFilter1 <> 0 AND strFilter2 <> 0 then
set objRS = objConn.Execute("select * from ItemMaster where MakeNumber =" & strFilter1 &" AND CategoryNumber =" & strFilter2 &" "
end if
'Set our counter to zero
intRecordCount = 0
%>
<table border="1" cellpadding="2" style="border-left-color: #0000FF; border-top-color: #0000FF" width="100%" bordercolorlight="#FF0000" bordercolordark="#0000FF">
<tr>
<td bgcolor="#F5F5F5" width="60">
<font face="Arial" color="#000080">
<b>
<font size="2">Part#</font>
</b>
</td>
<td bgcolor="#F5F5F5" width="75">
<font color="#000080">
<b>
<font size="2" face="Arial">Item</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="299">
<font color="#000080">
<b>
<font size="2" face="Arial">Description</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="3">
<font color="#000080">
<b>
<font size="2" face="Arial">Quantity</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="7">
<font color="#000080">
<b>
<font size="2" face="Arial">Price</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="70">
<font color="#000080">
<b>
<font size="2" face="Arial">Image</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="76">
<b>
<font color="#000080">
<font size="2" face="Arial">Add To Cart</font> </font>
</tr>
<%
Do while not objRS.EOF
if color = "#FFFFFF" then
color = "#F5F5F5"
else
color = "#FFFFFF"
end if
%>
<form name="form2" action="order.asp?action=add&Count=<%=iCount%>" method="post">
<tr>
<td bgcolor=<%=color%> width="60"> <font size="2" color="#000080"><%=objRS("PartNumber"%> </font></td>
<td bgcolor=<%=color%> width="75"> <font size="2" color="#000080"><%=objRS("Item"%> </font></td>
<td bgcolor=<%=color%> width="299"> <font size="2" color="#000080"><%=objRS("Description"%> </font></td>
<td bgcolor=<%=color%> width="3">
<font size="2" color="#000080">
<input type="text" name="txtQty" value="<%=objRS("Quantity"%>" size="2" style="color: #000080"></font></td>
<td bgcolor=<%=color%> width="7"> <font size="2" color="#000080"><%=FormatCurrency(objRS("Price")%> </font></td>
<% if objRS("Image" = "" then %>
<td bgcolor=<%=color%> width="70">
<p align="center"> <font size="2" color="#000080">No</font></td>
<% else %>
<td bgcolor=<%=color%> width="76">
<p align="center"> <font size="2" color="#000080">
<a href="images/<%=objRS("Image"%>">Yes</a></font></td>
<% end if %>
<td bgcolor=<%=color%> width="76"><font size="2" color="#000080">
<input type="Submit" Value="Add Item">
</td>
</tr>
<input type="hidden" name="txtPart" Value="<%=objRS("PartNumber"%>">
<input type="hidden" name="txtItem" Value="<%=objRS("Item"%>">
<input type="hidden" name="txtDescription" Value="<%=objRS("Description"%>">
<input type="hidden" name="txtPrice" Value="<%=objRS("Price"%>">
<input type="hidden" name="Count" Value=<%=iCount%>>
<input type="hidden" name="sID1" value=<%=ID1%>>
<input type="hidden" name="sID2" value=<%=ID2%>>
</form>
<%
objRS.MoveNext
intRecordCount = intRecordCount + 1
loop
%>
</table>
<%
if intRecordCount = 0 then
%>
<p>
<font face="Arial" color="#000080">
Your Search did not return any products. Please try again.
</font>
</p>
<%
else
%>
<p>
<font face="Arial">
<%=intRecordCount%> <font color="#000080">record(s) were found </font>
</p>
<%
end if
objRS.close
objConn.close
set objRS = nothing
set objConn = nothing
end if
End Sub
%>
<p style="margin-top: 0; margin-bottom: 1"><img border="0" src="images/LMWBanner1.png" width="468" height="60"></p>
<hr color="#0000FF">
</table>
</font>
</a>
<%
'Runtime Script
Dim aPartNumber() 'as Array
Dim aQtyOrder() 'as Array
Dim aPrice() 'as Array
Dim aItem() 'as Array
Dim aDescription() 'as Array
Dim sAction 'as String
Dim iCount 'as Integer
Dim PartNumber 'as String
Dim Item 'as String
Dim Description 'as String
Dim Price 'as Integer
Dim Quantity 'as Integer
Dim ID1
Dim ID2
Dim OrderNumber 'as Integer
Dim i
sAction = Request("action"
PartNumber = Request("txtPart"
Item = Request("txtItem"
Description = Request("txtDescription"
Price = Request("txtPrice"
Quantity = Request("txtQty"
iCount = CInt(Request.QueryString("Count")
ID1 = Request("sID1"
ID2 = Request("sID2"
Select Case sAction
Case "add"
ReDim Preserve aPartNumber(iCount)
aPartNumber(iCount) = PartNumber
ReDim Preserve aItem(iCount)
aItem(iCount) = Item
ReDim Preserve aDescription(iCount)
aDescription(iCount) = Description
ReDim Preserve aPrice(iCount)
aPrice(iCount) = Price
ReDim Preserve aQtyOrder(iCount)
aQtyOrder(iCount) = Quantity
'AddItem PartNumber, Item, Description, Price, Quantity, iCount
'iCount = iCount + 1
ShowOrder
Case "del"
DelItem PartNumber, iCount
'ShowOrder
Case "ShowOrder"
ShowOrder
Case "CheckOut"
PlaceOrder
Case "ShowCatelog"
ShowCatelog ID1, ID2
Case Else 'Item Search
ItemSearch
End Select
%>
<% Option Explicit
%>
<style fprolloverstyle>A:hover {color: #0000FF; text-decoration: overline underline}
</style>
<% 'Order.asp
Sub AddItem(PartNumber, Item, Description, Price, Quantity, iCount)
'ReDim Preserve aPartNumber(iCount)
'aPartNumber(iCount) = PartNumber
'ReDim Preserve aItem(iCount)
'aItem(iCount) = Item
'ReDim Preserve aDescription(iCount)
'aDescription(iCount) = Description
'ReDim Preserve aPrice(iCount)
'aPrice(iCount) = Price
'ReDim Preserve aQtyOrder(iCount)
'aQtyOrder(iCount) = Quantity
'ShowOrder aPartNumber, aItem, aDescription, aPrice, aQtyOrder
End Sub
'**************************************
Sub ShowOrder
'Dim i 'as Integer
Dim sTotal
Dim sExtension
Dim sShipCharge
Dim var1
sShipCharge = 15.00
ID1 = Request("sID1"
ID2 = Request("sID2"
%>
<body vlink="#0000FF" alink="#0000FF">
<table border="1" cellpadding="2" style="border-left-color: #0000FF; border-top-color: #0000FF" width="100%" bordercolorlight="#FF0000" bordercolordark="#0000FF">
<tr>
<td bgcolor="#F5F5F5" width="60">
<font face="Arial" color="#000080">
<b>
<font size="2">Part#</font>
</b>
</td>
<td bgcolor="#F5F5F5" width="75">
<font color="#000080">
<b>
<font size="2" face="Arial">Item</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="299">
<font color="#000080">
<b>
<font size="2" face="Arial">Description</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="3">
<font color="#000080">
<b>
<font size="2" face="Arial">Quantity Ordered</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="7">
<b>
<font size="2" face="Arial" color="#000080">Price</font>
</b>
</td>
</tr>
<form name="AddItem">
<%
stotal = 0
for i=0 to iCount
'if aPartNumber(i) <> "" then
sExtension = aQtyOrder(i) * aPrice(i)
sTotal = sTotal + sExtension
%>
<tr>
<td width="60"><font size="2" color="#000080"><%=aPartNumber(i)%> </font></td>
<td width="75"><font size="2" color="#000080"><%=aItem(i)%> </font></td>
<td width="299"><font size="2" color="#000080"><%=aDescription(i)%> </font></td>
<td width="3" align="Right"><font size="2" color="#000080"><%=aQtyOrder(i)%></font></td>
<td width="7"><font size="2" color="#000080"><%=FormatCurrency(aPrice(i))%> </font></td>
</tr>
<input type="hidden" name=part<%=i%> value=<%=aPartNumber(i)%>>
<input type="hidden" name=item<%=i%> value=<%=aItem(i)%>>
<input type="hidden" name=description<%=i%> value=<%=aDescription(i)%>>
<input type="hidden" name=qty<%=i%> value=<%=aQtyOrder(i)%>>
<input type="hidden" name=price<%=i%> value=<%=aPrice(i)%>>
<%
'end if
Next 'i
iCount=iCount + 1
sTotal = sTotal + sShipCharge
%>
</form>
<tr>
<td width="60"></td>
<td width="75"></td>
<td width="299"></td>
<td bgcolor="#F5F5F5" width="3"><b><font color="#000080">Delivery Charge:</font></b></td>
<td width="7"> <font size="2" color="#000080"><%=FormatCurrency(sShipCharge)%> </font></td>
</tr>
<tr>
<td width="60"><a href="Order.asp?action=ShowCatelog&Count=<%=iCount%>&sID1=<%=ID1%>&sID2=<%=ID2%>">Previous</a></td>
<td width="75"><a href="Order.asp?action=Nothing&Count=<%=iCount%>">Item Search</a></td>
<td width="299"></td>
<td bgcolor="#F5F5F5" width="3"><b><font color="#000080">Total:</font></b></td>
<td width="7"> <font size="2" color="#000080"><%=FormatCurrency(sTotal)%> </font></td>
</tr>
<form name="ShowOrder1">
<input type="hidden" name="sID1" value=<%=ID1%>>
<input type="hidden" name="sID2" value=<%=ID2%>>
</form>
<%
End Sub
' *******Item Search
Sub ItemSearch()
Dim objDC, objRS, objRS2
iCount = CInt(Request.QueryString("Count")
' Create and establish data connection
Set objDC = Server.CreateObject("ADODB.Connection"
objDC.ConnectionTimeout = 15
objDC.CommandTimeout = 30
'Use this line to use Access
objDC.Open "DSN=JerryLabant"
' Create recordset and retrieve values using the open connection
Set objRS = Server.CreateObject("ADODB.Recordset"
Set objRS2 = Server.CreateObject("ADODB.Recordset"
objRS.Open "Makes", objDC, 0, 1
objRS2.Open "Categories", objDC, 0, 1
' Loop through recordset and display results
%>
<form name="form1" action="Order.asp?action=ShowCatelog&Count=<%=iCount%>" method="Post">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="50%" nowrap>
<p align="Center"><font color="#000080">Select Vehicle Make</font>:
<select name="sID1" style="color: #000080">
<option value="0">*ALL</option>
<%
' Continue until we get to the end of the recordset.
Do While Not objRS.EOF
' For each record we create a option tag and set it's value to the employee id
' The text we set to the employees first name combined with a space and then their last name
%>
<option value="<%= objRS.Fields("MNumber" %>"><%= objRS.Fields("MDescription" %></option>
<%
' Get next record
objRS.MoveNext
Loop
%>
</select>
</p>
</td>
<td width="50%" nowrap>
<p align="Center"> <font color="#000080">Select Category:</font>
<select name="sID2" style="color: #000080">
<option value="0">*ALL</option>
<%
' Continue until we get to the end of the recordset.
Do While Not objRS2.EOF
' For each record we create a option tag and set it's value to the employee id
' The text we set to the employees first name combined with a space and then their last name
%>
<option value="<%= objRS2.Fields("CNumber" %>"><%= objRS2.Fields("CDescription" %></option>
<%
' Get next record
objRS2.MoveNext
Loop
%>
</select>
</p>
</td>
</tr>
</table>
<p align="Center">
<input type="Submit" value="Search">
</p>
<input type="hidden" name="Count" value=<%=iCount%>>
</form>
<%
End Sub
Sub ShowCatelog(ID1, ID2)
Dim boolCanRun
Dim objConn
Dim objRS
Dim strSQL
Dim strFilter1
Dim strFilter2
Dim intRecordCount
Dim color
Dim var1
boolCanRun = true
color = "#CCCCCC"
strFilter1 = ID1
strFilter2 = ID2
iCount = CInt(Request.QueryString("Count")
If boolCanRun then
set objConn = Server.createObject("ADODB.Connection"
objConn.Open "DSN=JerryLabant"
if strFilter1 = 0 AND strFilter2 = 0 then
set objRS = objConn.Execute("select * from ItemMaster Order By MakeNumber"
end if
if strFilter1 = 0 AND strFilter2 <> 0 then
set objRS = objConn.Execute("select * from ItemMaster where CategoryNumber =" & strFilter2 &" Order By MakeNumber"
end if
if strFilter1 <> 0 AND strFilter2 = 0 then
set objRS = objConn.Execute("select * from ItemMaster where MakeNumber =" & strFilter1 &" Order By MakeNumber"
end if
if strFilter1 <> 0 AND strFilter2 <> 0 then
set objRS = objConn.Execute("select * from ItemMaster where MakeNumber =" & strFilter1 &" AND CategoryNumber =" & strFilter2 &" "
end if
'Set our counter to zero
intRecordCount = 0
%>
<table border="1" cellpadding="2" style="border-left-color: #0000FF; border-top-color: #0000FF" width="100%" bordercolorlight="#FF0000" bordercolordark="#0000FF">
<tr>
<td bgcolor="#F5F5F5" width="60">
<font face="Arial" color="#000080">
<b>
<font size="2">Part#</font>
</b>
</td>
<td bgcolor="#F5F5F5" width="75">
<font color="#000080">
<b>
<font size="2" face="Arial">Item</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="299">
<font color="#000080">
<b>
<font size="2" face="Arial">Description</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="3">
<font color="#000080">
<b>
<font size="2" face="Arial">Quantity</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="7">
<font color="#000080">
<b>
<font size="2" face="Arial">Price</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="70">
<font color="#000080">
<b>
<font size="2" face="Arial">Image</font>
</b>
</font>
</td>
<td bgcolor="#F5F5F5" width="76">
<b>
<font color="#000080">
<font size="2" face="Arial">Add To Cart</font> </font>
</tr>
<%
Do while not objRS.EOF
if color = "#FFFFFF" then
color = "#F5F5F5"
else
color = "#FFFFFF"
end if
%>
<form name="form2" action="order.asp?action=add&Count=<%=iCount%>" method="post">
<tr>
<td bgcolor=<%=color%> width="60"> <font size="2" color="#000080"><%=objRS("PartNumber"%> </font></td>
<td bgcolor=<%=color%> width="75"> <font size="2" color="#000080"><%=objRS("Item"%> </font></td>
<td bgcolor=<%=color%> width="299"> <font size="2" color="#000080"><%=objRS("Description"%> </font></td>
<td bgcolor=<%=color%> width="3">
<font size="2" color="#000080">
<input type="text" name="txtQty" value="<%=objRS("Quantity"%>" size="2" style="color: #000080"></font></td>
<td bgcolor=<%=color%> width="7"> <font size="2" color="#000080"><%=FormatCurrency(objRS("Price")%> </font></td>
<% if objRS("Image" = "" then %>
<td bgcolor=<%=color%> width="70">
<p align="center"> <font size="2" color="#000080">No</font></td>
<% else %>
<td bgcolor=<%=color%> width="76">
<p align="center"> <font size="2" color="#000080">
<a href="images/<%=objRS("Image"%>">Yes</a></font></td>
<% end if %>
<td bgcolor=<%=color%> width="76"><font size="2" color="#000080">
<input type="Submit" Value="Add Item">
</td>
</tr>
<input type="hidden" name="txtPart" Value="<%=objRS("PartNumber"%>">
<input type="hidden" name="txtItem" Value="<%=objRS("Item"%>">
<input type="hidden" name="txtDescription" Value="<%=objRS("Description"%>">
<input type="hidden" name="txtPrice" Value="<%=objRS("Price"%>">
<input type="hidden" name="Count" Value=<%=iCount%>>
<input type="hidden" name="sID1" value=<%=ID1%>>
<input type="hidden" name="sID2" value=<%=ID2%>>
</form>
<%
objRS.MoveNext
intRecordCount = intRecordCount + 1
loop
%>
</table>
<%
if intRecordCount = 0 then
%>
<p>
<font face="Arial" color="#000080">
Your Search did not return any products. Please try again.
</font>
</p>
<%
else
%>
<p>
<font face="Arial">
<%=intRecordCount%> <font color="#000080">record(s) were found </font>
</p>
<%
end if
objRS.close
objConn.close
set objRS = nothing
set objConn = nothing
end if
End Sub
%>
<p style="margin-top: 0; margin-bottom: 1"><img border="0" src="images/LMWBanner1.png" width="468" height="60"></p>
<hr color="#0000FF">
</table>
</font>
</a>
<%
'Runtime Script
Dim aPartNumber() 'as Array
Dim aQtyOrder() 'as Array
Dim aPrice() 'as Array
Dim aItem() 'as Array
Dim aDescription() 'as Array
Dim sAction 'as String
Dim iCount 'as Integer
Dim PartNumber 'as String
Dim Item 'as String
Dim Description 'as String
Dim Price 'as Integer
Dim Quantity 'as Integer
Dim ID1
Dim ID2
Dim OrderNumber 'as Integer
Dim i
sAction = Request("action"
PartNumber = Request("txtPart"
Item = Request("txtItem"
Description = Request("txtDescription"
Price = Request("txtPrice"
Quantity = Request("txtQty"
iCount = CInt(Request.QueryString("Count")
ID1 = Request("sID1"
ID2 = Request("sID2"
Select Case sAction
Case "add"
ReDim Preserve aPartNumber(iCount)
aPartNumber(iCount) = PartNumber
ReDim Preserve aItem(iCount)
aItem(iCount) = Item
ReDim Preserve aDescription(iCount)
aDescription(iCount) = Description
ReDim Preserve aPrice(iCount)
aPrice(iCount) = Price
ReDim Preserve aQtyOrder(iCount)
aQtyOrder(iCount) = Quantity
'AddItem PartNumber, Item, Description, Price, Quantity, iCount
'iCount = iCount + 1
ShowOrder
Case "del"
DelItem PartNumber, iCount
'ShowOrder
Case "ShowOrder"
ShowOrder
Case "CheckOut"
PlaceOrder
Case "ShowCatelog"
ShowCatelog ID1, ID2
Case Else 'Item Search
ItemSearch
End Select
%>