You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by kaouki <in...@gmail.com> on 2007/10/19 15:17:21 UTC

[S2] Problem with tag

Hello,

I am new to Struts2 and I am attempting to create a form with a select tag
... :/

<s:select id="genre" name="genreId" label="Genre" list="genres" listKey="id"
listValue="nom" value="dvd.genre.id" cssClass="field"/>

I have a Collection<Genre> genres in my Action and a String genreId.
Genre is a simple JavaBean with id and name attributes.

But when I submit the form I have this error :
tag 'select', field 'list', id 'genre', name 'genreId': The requested list
key 'genres' could not be resolved as a
collection/array/map/enumeration/iterator type. Example: people or
people.{name} - [unknown location]

And I don't find how to solves that.
Could you help me please ?

Thanks for yours answers
K.

-- 
View this message in context: http://www.nabble.com/-S2--Problem-with-%3Cs%3Aselect%3E-tag-tf4653134.html#a13294356
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: [S2] Problem with tag

Posted by Rajagopal_Yendluri <Ra...@satyam.com>.
How are you accessing the JSP is also matters, if it needs to work
invoke the action from another url.

Say if you displaying list in list.jsp(listAction) invoke the listAction
from another URL, so that the list will come into the interceptor stak.



Regards,
Rajagopal Y
HCU-Consulting & Enterprise Solutions.
Phone: (C) +91-9986584084 / (W)+91-80-6658 3685.
-----Original Message-----
From: kaouki [mailto:ines.work@gmail.com] 
Sent: Friday, October 19, 2007 9:28 PM
To: user@struts.apache.org
Subject: Re: [S2] Problem with <s:select> tag


yes


newton.dave wrote:
> 
> --- kaouki <in...@gmail.com> wrote:
>> I have a Collection<Genre> genres in my Action and a
>> String genreId.
> 
> Is there a public getter for genres?
> 
> d.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 
> 

-- 
View this message in context:
http://www.nabble.com/-S2--Problem-with-%3Cs%3Aselect%3E-tag-tf4653134.h
tml#a13297642
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org




DISCLAIMER:
This email (including any attachments) is intended for the sole use of the intended recipient/s and may contain material that is CONFIDENTIAL AND PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying or distribution or forwarding of any or all of the contents in this message is STRICTLY PROHIBITED. If you are not the intended recipient, please contact the sender by email and delete all copies; your cooperation in this regard is appreciated.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [S2] Problem with tag

Posted by kaouki <in...@gmail.com>.
yes


newton.dave wrote:
> 
> --- kaouki <in...@gmail.com> wrote:
>> I have a Collection<Genre> genres in my Action and a
>> String genreId.
> 
> Is there a public getter for genres?
> 
> d.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/-S2--Problem-with-%3Cs%3Aselect%3E-tag-tf4653134.html#a13297642
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [S2] Problem with tag

Posted by Dave Newton <ne...@yahoo.com>.
--- kaouki <in...@gmail.com> wrote:
> I have a Collection<Genre> genres in my Action and a
> String genreId.

Is there a public getter for genres?

d.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org