Well,

in that case I would put into some scope a collection with beans containing the values 
and labels and access like this:

<html:options collection="myCollection" property="value" labelProperty="label"/>

or, if you want to retrieve from the Form, you can try this:

<html:optionsCollection name="myForm" property="arrayList" value="value" 
label="label"/>

where the collection is obtained from myForm.getArrayList(), and the beans in the 
collection having getLabel() and getValue()

Henrique Viecili
  ----- Original Message ----- 
  From: Samuel Rochas 
  To: Struts Users Mailing List 
  Sent: Friday, May 28, 2004 2:47 PM
  Subject: Re: <html:options> only with bean?


  Hello Henrique,

  Thanks for your answer.

  Your solution suppose I maintain two lists of objects, one for the 
  labels and one for the values.
  Is it not possible to give a list of object, and to use the object 
  properties for the value and for the label?

  Samuel



  ---------------------------------------------------------------------
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to