struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Olasoji Ajayi" <sojibush...@yahoo.com>
Subject error with logic:iterate on dynabeans
Date Tue, 04 Jan 2005 08:18:10 GMT
i get the following error when i run a web application to display the contents of a table.



HTTP Status 500 - 

--------------------------------------------------------------------------------

type Exception report

message 

description The server encountered an internal error () that prevented it from fulfilling
this request.

exception 

javax.servlet.ServletException: Cannot find message resources under key org.apache.struts.action.MESSAGE
 org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:867)
 org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:800)
 org.apache.jsp.formFile_jsp._jspService(formFile_jsp.java:238)
 org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:311)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:305)
 org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056)
 org.apache.struts.action.RequestProcessor.internalModuleRelativeForward(RequestProcessor.java:994)
 org.apache.struts.action.RequestProcessor.processForward(RequestProcessor.java:553)
 org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:211)
 org.apache.struts.action.ActionServlet.process(ActionServlet.java:1158)
 org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:415)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:305)
 org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056)
 org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:388)
 org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:231)
 org.apache.struts.action.ActionServlet.process(ActionServlet.java:1158)
 org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:415)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:305)


root cause 

javax.servlet.jsp.JspException: Cannot find message resources under key org.apache.struts.action.MESSAGE
 org.apache.struts.taglib.TagUtils.retrieveMessageResources(TagUtils.java:1233)
 org.apache.struts.taglib.TagUtils.message(TagUtils.java:1082)
 org.apache.struts.taglib.TagUtils.message(TagUtils.java:1057)
 org.apache.struts.taglib.bean.WriteTag.retrieveFormatString(WriteTag.java:256)
 org.apache.struts.taglib.bean.WriteTag.formatValue(WriteTag.java:362)
 org.apache.struts.taglib.bean.WriteTag.doStartTag(WriteTag.java:234)
 org.apache.jsp.formFile_jsp._jspService(formFile_jsp.java:195)
 org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:311)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:305)
 org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056)
 org.apache.struts.action.RequestProcessor.internalModuleRelativeForward(RequestProcessor.java:994)
 org.apache.struts.action.RequestProcessor.processForward(RequestProcessor.java:553)
 org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:211)
 org.apache.struts.action.ActionServlet.process(ActionServlet.java:1158)
 org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:415)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:305)
 org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056)
 org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:388)
 org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:231)
 org.apache.struts.action.ActionServlet.process(ActionServlet.java:1158)
 org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:415)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
 org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:305)


note The full stack trace of the root cause is available in the Tomcat logs.


--------------------------------------------------------------------------------

Apache Tomcat/5.0.19


 

below is the code i want to use to display the content of a database table.  the rowSet attribute
is a RowSetDynaClass containing the result of the query.

<bean:define id="cols" name="rowSet" property="dynaProperties"/>
   <table border="2">
     <tr>
       <logic:iterate id="col" name="cols">
         <th><bean:write name="col" property="name"/></th>
       </logic:iterate>
     </tr>
     <logic:iterate id="row" name="rowSet" property="rows">
       <tr>
         <logic:iterate id="col" name="cols">
           <td>          
             <bean:write name="row" property="<%= ((DynaProperty)col).getName() %>"/>
           </td>
         </logic:iterate>
       </tr>
     </logic:iterate>
   </table>

when i replace the <%= ((DynaProperty)col).getName()%>   with one of the values of the
column, the program runs correctly (i.e. the entire table is populated with the values of
the column as expected). why is it not working and if it can't what other method can i use
to dynamicaly generate the property value for the tag
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message