Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Cannot Find bean under name productInfo in jsp struts

Santhosh KumarS
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Forum,

Im doing a project using struts and jsp in eclipse.
My problem is, i have two select box(Combo box), if i select a data i.e clientName from second select box, corresponding productName

should be displayed in first select box..

Here for me, second select box is working properly but the problem is with the first select box, im getting following errors..

org.apache.jasper.JasperException: Cannot find bean under name productInfo
Root Cause:<CODE>
Root Cause:<CODE>
<QUOTE>What i am doing in my program is, as you see below my code,

When the user selects the clientName from second select box, i am dispatching a message named "select" from the

"". Then map.findForward function forwards to
In i have written the code to get the data from the database and i have set the attribute Arraylist

productInfo, which has the data in session scope.And one more thing there is no problem in fetching the data from the database

into productInfo arraylist. </QUOTE>
I dont understand where i am doing wrong..please help me...
Thanks in advance..


return map.findForward((String)tForm.getDispatch());

ArrayList productInfo = new ArrayList();
if(ProIdYear != null){
productInfo = bService.getProductName(ProIdYear);

session.setAttribute("productInfo", productInfo);

(First Selectbox: to select the productName)

<html:select property="projectSelection" style="WIDTH: 290px;" onklick="copyText()" onshange="copyText()" >
<html ptions collection="productInfo" property="productClass" labelProperty ="productName" />

(Second SelectBox: to select the clientName)

<html:select property="clientName1" style="WIDTH: 170px;" onshange=document.forms[0].projectSelection[0].selected='1';

document.forms['TourokuForm'].dispatch.value='select';document.forms[0].submit();" >
<html ptions collection="clientInfo" property="clientId" labelProperty="description"/>


<action path="/TourokuAction" type="login.web.action.TourokuAction"
name="TourokuForm" scope="session" input = "/pages/output.jsp">
<forward name="select" path="/" />
<forward name="success" path="/pages/success.jsp" redirect = "false" />
<forward name="failure" path="/pages/Failure.jsp" redirect = "false" />

<action path="/select" type="login.web.action.SetTourokuAction"
name="TourokuForm" scope="request" validate="true" input = "/pages/output.jsp">
<forward name="success" path="/pages/output.jsp" redirect = "false" />
<forward name="failure" path="/pages/Failure.jsp" redirect = "false" />

  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic