tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wendy Smoak <j...@wendysmoak.com>
Subject Re: Still Struggling with JSTL and c:forEach :-(
Date Thu, 16 Jun 2005 22:12:32 GMT
From: "Marco Mistroni" <mmistroni@gmail.com>
> <c:forEach var="expense" items="${applicationScope.EXPENSE_TYPES}>" >
>       <c:out value="${expense.description}"/><br/>
> </c:forEach>
>
> ServletException in '/insertBody.jsp': An error occurred while evaluating
> custom action attribute "value" with value "${expense.description}":
> Unable to find a value for "description" in object of
> class "java.lang.String" using operator "." (null)

What does <c:out value="${applicationScope.EXPENSE_TYPES}" /> print?

Try it with just <c:out value="${expense}"/> in the middle.  What do you
get?

For some reason, 'expense' is a String.  Maybe your List doesn't contain
what you think it does.

-- 
Wendy Smoak




---------------------------------------------------------------------
To unsubscribe, e-mail: taglibs-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: taglibs-user-help@jakarta.apache.org


Mime
View raw message