struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dave Newton <>
Subject Re: [Struts2] problem with <s:select> tag
Date Sun, 16 Dec 2007 01:18:41 GMT
You don't say how you initially populate the select box. In any case, unless
you're populating it via Preparable/prepare() or some other automatic way or
if it's not in application or session scope it won't get automatically
re-populated when you re-visit the page.


--- Raghuveer Rawat <> wrote:

> Hi,
> I have a getting problem in using s:select tag. Need some help if anyone
> used s:select before.
> This dropdown is populated dynamically. When form is loaded initially
> dropdown is getting populated perfectly. No issue here.
> But when we submit the form and some of the validations fail then page is
> not getting displayed correctly. This is because dropdown values are not
> coming back after the form submit. Not sure what need to be done to bring
> back this dropdown values.
> I can see below error in the log.
>  Servlet.service() for servlet jsp threw exception
> tag 'select', field 'list', name '': The requested list key
> 'countryList' could not be resolved as a
> collection/array/map/enumeration/iterator type. Example: people or
> people.{name} - [unknown location]
> Here is my jsp code for this issue:
> <s:select name="" headerKey="-1" headerValue="Select Country"
> cssClass="textbox1"
>                             list="countryList" listKey="code"
> listValue="name" required="true" />
> Pl. let me know if you need some more information.
> Thanks in advance.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message