Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

problem using struts:select tag  RSS feed

 
Benjamin Pope
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 129
Java Netbeans IDE Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

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
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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:

 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!