Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


ASP Arrays & Drop Down Boxes

 
Logged in as: Guest
arrSession:exec spGetSession 2,3,273
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> ASP >> ASP Arrays & Drop Down Boxes
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 ASP Arrays & Drop Down Boxes - 7/15/2001 11:13:35 PM   
  jordan

 

Posts: 9
Score: 0
Joined: 6/9/2001
From: USA
Status: offline
I need to populate a drop down box in ASP with an array. Is this
possible and what is the code to do this. Also, how do I know what
the array reference number would be for a the user's selection? Any
help would be appreciated. Thanks.
 
 
Post #: 1
 
 Re: ASP Arrays & Drop Down Boxes - 7/15/2001 11:19:34 PM   
  rhl150

 

Posts: 29
Score: 0
Joined: 5/23/2001
From: New Zealand
Status: offline
response.write "<SELECT>"
for i = 0 to ubound(a)
response.write "<OPTION VALUE=" & i & ">" & a(i) _
& "</OPTION>"
next
response.write "</SELECT>"

Since you're setting the value of each item to be the array
index, that's the value you'll get when the item is selected.

(in reply to jordan)
 
 
Post #: 2
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> ASP >> ASP Arrays & Drop Down Boxes Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts