Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP Pro Code Clinic As of Oct 5, 2005, this forum is now locked. No posts have been deleted. Please use "Classic ASP Professional" at: http://p2p.wrox.com/forum.asp?FORUM_ID=56 for discussions similar to the old ASP Pro Code Clinic or one of the other many remaining ASP and ASP.NET forums here.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP Pro Code Clinic section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old July 2nd, 2003, 10:38 AM
Authorized User
 
Join Date: Jun 2003
Location: , , .
Posts: 37
Thanks: 0
Thanked 0 Times in 0 Posts
Default request object

i need some serious help

i generate values dynamically and pass an unspecifyed No. of variables to the next page in the requststring... that works fine... now i need to retrieve and sort those values stored in variables called CaseAsset1, CaseAsset2 , CaseAsset3... the nr after Asset is autogenerated by a counter (depending on howmany values the user will have to enter)
How do i concatinate in the line:

<%= request.QueryString("CaseAsset" + ANY CHARACTER) %>
is there a wildcard i can use?

i will need that line to be dynamic since i never know howmany variables i have to deal with

thanks a bunch
Toran
__________________
... there is always more to learn...
  #2 (permalink)  
Old July 2nd, 2003, 05:02 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: High Wycombe, UK, United Kingdom.
Posts: 344
Thanks: 0
Thanked 1 Time in 1 Post
Default

Why not set a boolean to false and then use a DO WHILE loop and then within that test to see if you have a parameter :

Dim incomplete
Dim count
incomplete=TRUE
count=0

Do while incomplete
  if (Request.QueryString("Field" & count)) then
       response.write("we have a field")
       count=count+1
   else
       response.write("the end")
       incomplete=FALSE
   end if
WEnd
  #3 (permalink)  
Old July 2nd, 2003, 06:38 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: Sydney, NSW, Australia.
Posts: 215
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Or this:

Code:
Dim intCnt
Dim strConCat

' assuming that you are writing the variables to the screen
' you could also do something else with them
For intCnt = 0 To Request.QueryString.Count
    If (Left(Request.QueryString.Key(intCnt), 9) = "CaseAsset") Then
        Response.Write Request.QueryString.Item(intCnt) & "<br>"
    End If
Next
regards
David Cameron
  #4 (permalink)  
Old July 8th, 2003, 07:22 PM
Authorized User
 
Join Date: Jun 2003
Location: , , .
Posts: 37
Thanks: 0
Thanked 0 Times in 0 Posts
Default

many thanks to both of you... i will try this ...:)

I'll keep ya posted


Toran ...

  #5 (permalink)  
Old July 24th, 2003, 12:45 PM
Authorized User
 
Join Date: Jun 2003
Location: , , .
Posts: 37
Thanks: 0
Thanked 0 Times in 0 Posts
Default

worx..:) Thanks again


 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
object required Request RoniR ASP.NET 1.0 and 1.1 Basics 3 January 8th, 2007 06:53 AM
Request Object g2000 ASP.NET 1.0 and 1.1 Basics 1 October 21st, 2005 02:01 PM
Request Object kagitas .NET Web Services 1 October 2nd, 2004 10:26 PM
the request object Toran Classic ASP Basics 0 June 27th, 2003 01:06 PM



All times are GMT -4. The time now is 08:51 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.