faqts : Computers : Programming : Languages : Asp : ASP/VBScript : Common Problems

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

1 of 1 people (100%) answered Yes

Entry

Is there a way to use the count property to do a response.write.count?

Jun 26th, 2000 07:19
unknown unknown, Scott Mitchell


Problem:

I want to do a count of how many items of this querystring have been 
selected (and show that on the page) is there a way to do this using a 
for each item in request.querystring loop?

Solution:

Check out this really cool-looking code.

        Dim iQSCount
        iQSCount = UBound(split(Request.QueryString,"&")) -
LBound(split(Request.QueryString,"&"))

Neat, eh?  No loops here.  To learn more about split check out:

        Parsing with join and split
        http://www.4guysfromrolla.com/webtech/050999-1.shtml



© 1999-2004 Synop Pty Ltd