Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Returning data from a string passed to the next .ASP page

Status
Not open for further replies.

DougP

MIS
Dec 13, 1999
5,985
US
When I hit the Submit button I pass this mess to the next .ASP page.


Buried near the end is all of the parts a person wants to order, as shown below.

QTY+100130=2&QTY+100130=4&QTY+100130=1&QTY+100134=1&QTY+100139=5&QTY+410013=1&QTY+100275=2&QTY+100130=1

So on this order there are 8 itmes.
for example the following is the Quantity box with the quantity of 2 for part number 100130.
QTY+100130=2

Can a grab all 8 items somehow in a "For Next" loop or a "Do Loop" to get get out the part number and the quantity of that part number.

this works for Customer number and PO and so forth
<%Customer=request.querystring(&quot;Cust&quot;)%>
<%PONum=request.querystring(&quot;PONum&quot;)%>
<%BillToAttn=request.querystring(&quot;BillToAttn&quot;)%>

But there will be a different number of Qty boxes and different part numbers for each order.

TIA [sig]<p>DougP, MCP<br><a href=mailto: dposton@universal1.com> dposton@universal1.com</a><br><a href= > </a><br> Ask me how Bar-codes can help you be more productive.[/sig]
 
Well I got some help from another site
this loop will print out all of the querstrings passed to a page.
So I am checking the parameters to see if QTY exists in it.

<% For Each name In Request.querystring%>
<%Item=name%>
<%If left(Item, 3) = &quot;QTY&quot; then%>
<%pnum=right(Item,len(Item)-4)%>
<%response.write pnum%> <\>
<%=Request.querystring(name)%><br>

<%End if%>
<% Next %>
[sig]<p>DougP, MCP<br><a href=mailto: dposton@universal1.com> dposton@universal1.com</a><br><a href= > </a><br> Ask me how Bar-codes can help you be more productive.[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top