Geeks Talk

Prepare for your Next Interview


Welcome to the Geeks Talk forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

Vector data should be placed in Drop Down box

This is a discussion on Vector data should be placed in Drop Down box within the JSP forums, part of the Web Development category; My question is I have some data in vector or any collection consider as user names of users. Then I need that data (which is in vector) should be placed ...

Go Back   Geeks Talk > Web Development > JSP
Register Blogs FAQ Tag Cloud Calendar Mark Forums Read

JSP JSP Related Issues and Problems

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-30-2007
Junior Member
 
Join Date: Jun 2007
Location: Bangalore
Posts: 1
Thanks: 0
Thanked 2 Times in 1 Post
upenderreddy is on a distinguished road
Vector data should be placed in Drop Down box

My question is I have some data in vector or any collection consider as user names of users. Then I need that data (which is in vector) should be placed in DROP DOWN box of my JSP.

How can i code this one.
I will wait for your reply...
Reply With Quote
The Following 2 Users Say Thank You to upenderreddy For This Useful Post:
Sponsored Links
  #2 (permalink)  
Old 07-31-2007
Contributing Member
 
Join Date: Sep 2006
Location: bangalore, india
Posts: 1,016
Thanks: 0
Thanked 89 Times in 72 Posts
psuresh1982 will become famous soon enough
Re: Vector data should be placed in Drop Down box

I think you know how to get the data from Vector. After that it is easy to assign in dropdown.

First get the total for number of data in vector. Then write the following for loop.

Code:
<select name="username">
<%
for(int i=0; i<=total; i++)
{
%>
<option><%= value for the option %></option>
<% 
}
%>
</select>
-----------------
suresh
Reply With Quote
Reply

  Geeks Talk > Web Development > JSP

Thread Tools
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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
An ArrayList and a Vector FantaGuy Java 5 03-19-2009 12:34 PM
Why we say arraylist is not synchronized where as vector are Geek_Guest Java 1 06-20-2007 12:50 PM
Not able to set value in the datafilter drop down chiranjib S QTP 3 04-30-2007 09:03 AM
How to pick the data from the drop down list box Livetek QTP 2 03-27-2007 03:11 AM
Web Service method returns a vector of objects ssumitha ASP.NET 1 12-14-2006 08:25 AM


All times are GMT -4. The time now is 03:54 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.1
Copyright © 2009 GeekInterview.com. All Rights Reserved