dcsimg
I have a an arraylist. Each element in this list is an object and has set of properties.I want to display this in a select and corresponding option.
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Guest_User
Posted On:   Thursday, August 14, 2003 01:11 PM

I have a an arraylist. Each element in this list is an object and has set of properties.I want to display this in a select and corresponding option. ArrayList list = Obj.getMap(); // constructing a String[] String[] colMapArray = new String[list.size()]; // for each element in the list I have to obtain the object for (int i = 0; i < list.size(); i++) { ColumnMap colMap = (ColumnMap)list.get(i); // for each object obtain the String I want to display colMapArray[i] = colMap.getTitle(); } Now my question is how to display this String (colMap.getTitle();) in my jsp using Struts Select and Option tags. Thanks    More>>
			I have a an arraylist. Each element in this list is an object and has set of properties.I want to display this in a select and corresponding option.
			

ArrayList list = Obj.getMap();

// constructing a String[]
String[] colMapArray = new String[list.size()];

// for each element in the list I have to obtain the object
for (int i = 0; i < list.size(); i++) {
ColumnMap colMap = (ColumnMap)list.get(i); // for each object obtain the String I want to display
colMapArray[i] = colMap.getTitle();
}

Now my question is how to display this String (colMap.getTitle();) in my jsp using Struts Select and Option tags.


Thanks    <<Less

Re: I have a an arraylist.

Posted By:   gowri_shankar  
Posted On:   Wednesday, August 20, 2003 09:14 PM




Hey,
I m not sure of this just try this.


About | Sitemap | Contact