You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by eugenebalt <eu...@yahoo.com> on 2010/12/22 17:25:56 UTC
Select All / Clear All Checkboxes in CheckBoxMultipleChoice
Is there an easy way to select all/clear all checkboxes in
CheckBoxMultipleChoice?
My Model of that field is an ArrayList.
I wish there was a method called "setModelValue(..)" where I could set the
string "0;1;2;3;4;5;6;..." to select all the values, but it's deprecated.
--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Select-All-Clear-All-Checkboxes-in-CheckBoxMultipleChoice-tp3160873p3160873.html
Sent from the Users forum mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Select All / Clear All Checkboxes in CheckBoxMultipleChoice
Posted by Pedro Santos <pe...@gmail.com>.
There is the setModelValue(final String[] value) not deprecated.
you can also do:
CheckBoxMultipleChoice c;
((Collection)c.getDefaultModelObject()).addAll(c.getChoices());
On Wed, Dec 22, 2010 at 2:25 PM, eugenebalt <eu...@yahoo.com> wrote:
>
> Is there an easy way to select all/clear all checkboxes in
> CheckBoxMultipleChoice?
>
> My Model of that field is an ArrayList.
>
> I wish there was a method called "setModelValue(..)" where I could set the
> string "0;1;2;3;4;5;6;..." to select all the values, but it's deprecated.
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Select-All-Clear-All-Checkboxes-in-CheckBoxMultipleChoice-tp3160873p3160873.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
--
Pedro Henrique Oliveira dos Santos