Why not have your singleton hold a reference to the bean object that carries the data?
This is a classic case of "any problem in computer science can be solved with an additional layer of abstraction." James. > -----Original Message----- > From: Roland Carlsson [mailto:roland.c@;swetravel.se] > Sent: Thursday, October 24, 2002 5:12 AM > To: Struts Users Mailing List > Subject: Re: <html:options /> > > I found whats wrong... my bean aren't a bean... since a bean have to have > a > public no argument constructor and my is a Singleton... so I'll guess that > I > have to live with a little ugliness in the view. > > <% > request.setAttribute("parts", > demo.DBApplication.getInstance().getAllParts()); > %> > > Thanks for the fun and the help > > Regards > Roland > > ----- Original Message ----- > From: "deepak" <[EMAIL PROTECTED]> > To: "Struts Users Mailing List" <[EMAIL PROTECTED]> > Sent: Thursday, October 24, 2002 1:51 PM > Subject: Re: <html:options /> > > > > Yes you can. > > > > for e.g. > > > > <bean:define id="carriers" name="CarrierForm" property="carrierVector"/> > > > > ----- Original Message ----- > > From: "Roland Carlsson" <[EMAIL PROTECTED]> > > To: "Struts Users Mailing List" <[EMAIL PROTECTED]> > > Sent: Thursday, October 24, 2002 5:04 PM > > Subject: Re: <html:options /> > > > > > > > Can't carriers be a collection that I can get from the ActionForm? > > > > > > Regards > > > Roland Carlsson > > > > > > ----- Original Message ----- > > > From: <[EMAIL PROTECTED]> > > > To: "Struts Users Mailing List" <[EMAIL PROTECTED]> > > > Sent: Thursday, October 24, 2002 1:11 PM > > > Subject: Re: <html:options /> > > > > > > > > > > > > > > <html:select property="carrier" > <%-- The form's property to be > > > > populated --%> > > > > <html:options collection="carriers" property="id" > labelProperty > > > > ="name"/> > > > > </html:select> > > > > > > > > carriers is a list of Carrier objects in my Session Context > > > > > > > > > > > > > > > > > > > > > > > > "Roland > > > > Carlsson" To: "Struts > Users > > > Mailing List" <[EMAIL PROTECTED]> > > > > <roland.c@swetra cc: > > > > vel.se> Subject: > <html:options > /> > > > > > > > > 24/10/2002 01:04 > > > > PM > > > > Please respond > > > > to "Struts Users > > > > Mailing List" > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Hello! > > > > I'm trying to use <html:options/> but the only thing I get get into > > > > the list > > > > are Object.toString() values witch is not very useful for the user. > > > > > > > > What I like to do is the equal to > > > > > > > > <option value="<%= myObj.getId() %>"><%= myObj.getName() %></option> > > > > > > > > Can this be done? > > > > > > > > Thanks in advance > > > > Roland Carlsson > > > > > > > > > > > > -- > > > > To unsubscribe, e-mail: < > > > > mailto:struts-user-unsubscribe@;jakarta.apache.org> > > > > For additional commands, e-mail: < > > > > mailto:struts-user-help@;jakarta.apache.org> > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > To unsubscribe, e-mail: > > > <mailto:struts-user-unsubscribe@;jakarta.apache.org> > > > > For additional commands, e-mail: > > > <mailto:struts-user-help@;jakarta.apache.org> > > > > > > > > > > > > > -- > > > To unsubscribe, e-mail: > > <mailto:struts-user-unsubscribe@;jakarta.apache.org> > > > For additional commands, e-mail: > > <mailto:struts-user-help@;jakarta.apache.org> > > > > > > -- > > To unsubscribe, e-mail: > <mailto:struts-user-unsubscribe@;jakarta.apache.org> > > For additional commands, e-mail: > <mailto:struts-user-help@;jakarta.apache.org> > > > > > -- > To unsubscribe, e-mail: <mailto:struts-user- > [EMAIL PROTECTED]> > For additional commands, e-mail: <mailto:struts-user- > [EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@;jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@;jakarta.apache.org>