Solved it myself after a bit of experimenting. Presetting
="<%=\"problematicOddsList[\"
> + i + \"].sportTypeId\"%> to a valid sportTypeId did the trick.

//Linus


"Linus Nikander" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I'm having trouble pre-selecting one of the <html:options/> entries that
are
> generated by the below jsp code. Which attribute of which bean should i
set
> to which value ?
>
> UnknownSportForm contains two ArrayLists one
> called currentSportsList  and one called problematicOddsList. The
> problematicOddsList is in turn made up of beans with the appropriate
getters
> and setters. currentSportsList also contains beans with getters and
setters
> for its values. What I want to do is preselect one of the sportType
elements
> in the select fields I generate. How do i accomplish this ?
>
> -------- JSP - code -----------
>   <html:select name="UnknownSportForm"
property="<%=\"problematicOddsList[\"
> + i + \"].sportTypeId\"%>" size="3">
>         <html:options collection="currentSportsList"
property="sportTypeId"
> labelProperty="sportType"/>
>     </html:select>
>
> -------- JSP - code -----------
>
> //Linus Nikander - [EMAIL PROTECTED]




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

Reply via email to