When u use the "collection " attribute of the options tag, u must store the bean u r trying to access by the "collection" attribute in some scope. Its not the same bean as the one attributed with your action mapping. It will be some collection like a Vector, ArrayList etc. stored in the some scope
Deepank ----- Original Message ----- From: "Mohan Radhakrishnan" <[EMAIL PROTECTED]> To: "'Struts Users Mailing List'" <[EMAIL PROTECTED]> Sent: Monday, September 30, 2002 4:11 PM Subject: RE: html:form > Hi, > The bean should be associated with the <html:form> tag according to the > struts example. The example > > <html:select property="collectionSelect" size="10" > multiple="true"> > <html:options collection="options" property="value" > labelProperty="label"/> > </html:select> > doesn't specify any bean name. Mine is similar. > > <html:select property="wanLinks" size="1" > > <html:options collection="wanLinkOptions" property="value" > labelProperty="label"/> > </html:select> > bye, > Mohan > > -----Original Message----- > From: deepank [mailto:[EMAIL PROTECTED]] > Sent: Monday, September 30, 2002 4:04 PM > To: Struts Users Mailing List > Subject: Re: html:form > > > This is because u may not have stored the bean wanLinkOptions in "request" > or "session", the scope u may be using in ur application. > u must store this bean in some scope(probably in your action class) > > > > ----- Original Message ----- > From: "Mohan Radhakrishnan" <[EMAIL PROTECTED]> > To: "'Struts Users Mailing List'" <[EMAIL PROTECTED]> > Sent: Monday, September 30, 2002 2:34 PM > Subject: RE: html:form > > > > HI, > > O.K. It is ReportParameterForm. I am checking this because of the > > following error. > > > > >javax.servlet.ServletException: Cannot find bean under name > wanLinkOptions > > > > I am referring to the html select example from the Struts examples > package. > > bye, > > mohan > > > > -----Original Message----- > > From: deepank [mailto:[EMAIL PROTECTED]] > > Sent: Monday, September 30, 2002 1:47 PM > > To: Struts Users Mailing List > > Subject: Re: html:form > > > > > > It will pick up property values from the bean ReportParameterForm and NOT > > 'ReportParameterFormBean' , these two names are different as far as i know > > > > Deepank > > ----- Original Message ----- > > From: "Mohan Radhakrishnan" <[EMAIL PROTECTED]> > > To: <[EMAIL PROTECTED]> > > Sent: Monday, September 30, 2002 1:03 PM > > Subject: html:form > > > > > > > Hi, > > > > name - The attribute name of the bean whose properties are consulted > > to > > > determine which option should be pre-selected when rendering this input > > > >field. If not specified, the bean associated with the enclosing > > <html:form> > > > tag is utilized. > > > The above is the doc. for <html:form ..> > > > If I use the following, > > > <html:form action="mainscreen.action"> > > > </html:form> > > > ------------ > > > <form-bean name="reportParameterForm" > > > type="com.hcl.smartmanage.web.ReportParameterForm"/> > > > <action path="/mainscreen" > > > type="com.hcl.smartmanage.web.action.SetupAction" > > > name="reportParameterForm" > > > scope="request" > > > input="/mainscreen.jsp"> > > > </action> > > > ------- > > > Will it pick up 'ReportParameterFormBean' automatically ? I am asking > this > > > because the following doesn't specify any JSP bean name. So it should > pick > > > it up the bean associated with the <html:form ..> tag. > > > <html:select property="wanLinks" size="1" > > > > <html:options collection="wanLinkOptions" > > > property="value" labelProperty="label"/> > > > </html:select> > > > > > > bye, > > > Mohan > > > > > > > > > > > > > > > -- > > > To unsubscribe, e-mail: > > <mailto:[EMAIL PROTECTED]> > > > For additional commands, e-mail: > > <mailto:[EMAIL PROTECTED]> > > > > > > > > > -- > > To unsubscribe, e-mail: > > <mailto:[EMAIL PROTECTED]> > > For additional commands, e-mail: > > <mailto:[EMAIL PROTECTED]> > > > > -- > > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > -- > To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>