• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hashmap calling (Collection not found error)

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have defined my hashmap on ActionForm with getter & setter as follow.

private HashMap status;

on jsp am writing follwoing code

<bean efine id="list1" name="FormBean1" type="com.test.testActionForm" />

<html:form action="a1">
<logic:iterate id="items" name="list1" property="status">
</logic:iterate>
</html:form>


It give me error that No collection found.
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Make sure you have populated the status property with data prior to the JSP being displayed, either in an action class that forwards to the JSP or in the reset method of the ActionForm.

By the way, your bean efine tag is unnecessary. Just write:
reply
    Bookmark Topic Watch Topic
  • New Topic