you can just add formcomponent to your arraylist in populateitem that will
give you list of formcomponents.
you can then validate them in your custom formvalidator..


On Thu, Jun 3, 2010 at 11:58 PM, fachhoch <[email protected]> wrote:

>
> I tried this code please tell me if this is right  code  to  retrieve to
> formcomponent from a list view
>
>
>
>                List<FormComponent<?>>  formComponents= new
> ArrayList<FormComponent<?>>();
>                for(Iterator<?  extends ListItem<?>> listItemIterator=
>
> ((ListView<?>)form.get(listViewId)).iterator();listItemIterator.hasNext();
> ){
>                        for(Iterator<?  extends Component>
> itemChildrenIterator=
> listItemIterator.next().iterator() ;itemChildrenIterator.hasNext(); ){
>                                Component
>  component=itemChildrenIterator.next();
>                                if(component  instanceof  FormComponent<?>
> &&
> component.getId().equals(id)   ){
>
>  formComponents.add((FormComponent<?>)component);
>                                }
>                        }
>                }
>                return formComponents;
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/validations-in-a-form-with-listView-tp2242009p2242137.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


-- 
regards,
Vineet Semwal

Reply via email to