aspose file tools*
The moose likes JSP and the fly likes help in JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "help in JSP" Watch "help in JSP" New topic
Author

help in JSP

Mukesh Dubey
Greenhorn

Joined: Mar 19, 2004
Posts: 4
Hi,

I have a bean like this:

class WorkOnExpense{
private String inventory;
private Double amount;
private String check;
private String voucher;
private List items;
private List accountNo;
}

and i am setting all this values after getting it from datbase.

Now i am able to print values of inventory, amount check in jsp page but not able to print List type properties. How to print this using <logic:iterate> or using nested tag.

for printing other values i am writing like this

<jsp:useBean id="workOnExpenseVO" type="com.ci.prize.view.vo.releaseexpense.WorkOnExpenseVO" scope="session"/>

<bean:write name="workOnExpenseVO" property="amount" />

and i am getting the list also using this.

<bean:write name="workOnExpenseVO" property="items" />
Now how can i iterate this list and print all the values in jsp page.


Please help me on this..

Thanks in advance!!

Mukesh.


Mukesh
Kj Reddy
Ranch Hand

Joined: Sep 20, 2003
Posts: 1704
Mukesh you posted in wrong place. Post your query in JSPs category
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61764
    
  67

The JSTL <c:forEach> tag will allow you to iterate through the List.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: help in JSP