aspose file tools*
The moose likes Struts and the fly likes Strange Struts error with logic iterate bean. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Strange Struts error with logic iterate bean." Watch "Strange Struts error with logic iterate bean." New topic
Author

Strange Struts error with logic iterate bean.

Todd Nine
Greenhorn

Joined: Oct 28, 2004
Posts: 5
OK everyone, I'm stumped so any help would be greatly appreciated.

This is the error I recieve within my browser

Error 500: No getter method for property groups_id.name of bean org.apache.struts.taglib.html.BEAN


This is the full exception.

[10/28/04 14:21:32:266 EST] e770e77 WebGroup E SRVE0026E: [Servlet Error]-[No getter method for property groups_id.name of bean org.apache.struts.taglib.html.BEAN]: javax.servlet.jsp.JspException: No getter method for property groups_id.name of bean org.apache.struts.taglib.html.BEAN
at java.lang.Throwable.<init>(Throwable.java)
at java.lang.Throwable.<init>(Throwable.java)
at javax.servlet.jsp.JspException.<init>(JspException.java:87)
at org.apache.struts.taglib.TagUtils.lookup(TagUtils.java:1031)
at org.apache.struts.taglib.html.BaseFieldTag.renderInputElement(BaseFieldTag.java:153)
at org.apache.struts.taglib.html.BaseFieldTag.doStartTag(BaseFieldTag.java:96)
at org.apache.jsp._profile._jspService(profile.jsp )
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java:89)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:344)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.serviceJspFile(JspServlet.java:662)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.service(JspServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:974)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:555)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:200)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:119)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:276)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.cache.invocation.CacheableInvocationContext.invoke(CacheableInvocationContext.java:114)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:186)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:618)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java)



Now here the iterate code that fails.



However, this does work.



I'm not sure why, since Struts is using BeanUtils to invoke "getName()" on the object it is iterating over which is an instance of "GroupVO". BeanUtils should be dynamically invoking the code that I gave in the second example. The only thing I can possibly think of, is that GroupVO extends BaseGroupVO, and the method getName() resides in the BaseGroupVO class. Does BeanUtils not recurse to parent classes if the property does not exist on the current class?

Thanks,
Todd
Todd Nine
Greenhorn

Joined: Oct 28, 2004
Posts: 5
Nevermind, I just figured out my error. It should be



Not



My mistake, I assumed that WSAD generated correct struts code. How I miss MyEclipse.....
 
 
subject: Strange Struts error with logic iterate bean.