This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes Struts and the fly likes problem using struts:select tag Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "problem using struts:select tag" Watch "problem using struts:select tag" New topic
Author

problem using struts:select tag

Benjamin Pope
Greenhorn

Joined: Sep 05, 2011
Posts: 10
First of all, I am using struts 2. The page won't load. I get the error: org.apache.jasper.JasperException: tag 'select', field 'list', name 'maxtopics': The requested list key 'maxtopicslist' could not be resolved as a collection/array/map/enumeration/iterator type. Example: people or people.{name}

The code for the action for the page (Preferences.java) is:



The jsp page that uses the maxtopicslist is PreferencesFrame.jsp:



Can anyone see a problem with this implementation?
Nitin Surana
Ranch Hand

Joined: Jan 21, 2011
Posts: 129


System.out.println(getMaxtopicslist());


Does the action prints out a not null maxtopicslist? If yes then the problem might be in how you are accessing your JSP page. I mean to say that you have to call this action which will pass the result as this JSP.

Benjamin Pope
Greenhorn

Joined: Sep 05, 2011
Posts: 10
Thank you. The problem was in the page that was supposed to point to the action, I had pointed it to the jsp page itself like this:

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: problem using struts:select tag
 
Similar Threads
NullPointerException at the SessionFactory create line.
validation in struts2
How to use, struts 1-- struts-config.xml and struts 2 -- struts.xml together?
org.apache.jasper.JasperException: An exception occurred processing JSP page
Problem with the "where" query.