This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Struts and the fly likes access collection data in s:if Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "access collection data in s:if" Watch "access collection data in s:if" New topic
Author

access collection data in s:if

asif rafique
Greenhorn

Joined: Mar 25, 2007
Posts: 8
hi i m displaying a collection using a s:iterator tag which works fine



here beanList is an ArrayList containing bean objects with properties name and fname
my problem is when i did this



here i m checking if name property is null then display some message but if condition never return true i can't find what is wrong here
please help me out
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

You're calling getName() on beanList--the collection.
asif rafique
Greenhorn

Joined: Mar 25, 2007
Posts: 8
got your point thanks for your reply
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: access collection data in s:if