I have a similar problem... Try using itemValue="#{product.id}''"  it will
force id to string. I beleive it's a conversion issue, not sure if the
component needs to implement the code to use the standard converters
explicitily.
Regars,
Renato


Beelen, Marco wrote:
> 
> Hello,
> 
> I'm running into some troubles using the selectManyPickList for the
> sandbox ( 1.1.5-SNAPSHOT )
> I use the component to let my users select the products they want for
> the set of available products. 
> 
> <s:selectManyPicklist value="#{backingBean.selectedProductIds}"
> id="productList" size="10">
>       <s:selectItems 
>               value="#{backingBean.availableProducts}" 
>               var="product" 
>               itemLabel="#{product.description}" 
>               itemValue="#{product.id}" />                    
> </s:selectManyPicklist>
> 
> The backingbean stores the selectedId's in a private Long[]
> selectedProductIds.
> 
> In order to improve the usability of the application I pre-populate the
> selectedIds based upon the user-profile.
> When a users adds or removes an item from the PickList the application
> continues perfectly, but when a user only want to use the values aready
> in the selectedIds and directly hits the 'next'-commandButton a
> Validation Error occures and the same page is being rerendered.
> 
> The execution of the program doesn't reach the action assigned to the
> commandButton.
> 
> The really weird thing is that when I remove an item from the
> pre-populated selected list and then add the same item again and hit the
> commandButton, the validation error doesn't occur.
> 
> 
> Can anybody think along about what might cause this strange behaviour
> and how I can get around this?
> 
> I'm using MyFaces 1.1.3 with tomahawk 1.15-SNAPSHOT running on Tomcat
> 5.5.9 and jdk 1.5.0_07.
> My managed-bean is being stored in session-scope and I'm using
> server-side state saving.
> 
> Any help or suggestions are greatly appreciated
> 
> With kind regards,
>    Marco Beelen
> 
> 
> 
> 
> 
> 
> 
> 
> 
> ------------------------------------------------------------------------------
> Notice:  This e-mail message, together with any attachments, contains
> information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station,
> New Jersey, USA 08889), and/or its affiliates (which may be known
> outside the United States as Merck Frosst, Merck Sharp & Dohme or MSD
> and in Japan, as Banyu - direct contact information for affiliates is 
> available at http://www.merck.com/contact/contacts.html) that may be 
> confidential, proprietary copyrighted and/or legally privileged. It is 
> intended solely for the use of the individual or entity named on this 
> message. If you are not the intended recipient, and have received this 
> message in error, please notify us immediately by reply e-mail and then 
> delete it from your system.
> 
> 
> ------------------------------------------------------------------------------
> 

-- 
View this message in context: 
http://www.nabble.com/selectManyPicklist-causes-%27Validation-Error%27-tf2947269.html#a8449959
Sent from the MyFaces - Users mailing list archive at Nabble.com.

Reply via email to