You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Diego Fincatto <di...@gmail.com> on 2010/02/11 14:28:28 UTC
Re: Problem with RadioGroup / Ajax
I'm having the same problem when using two RadioGroup with
AjaxFormChoiceComponentUpdatingBehavior in the same page.
On Thu, Jul 2, 2009 at 6:07 AM, Mathias Nilsson
<wi...@gmail.com> wrote:
>
> I've made a sample page.
>
> public class HomePage extends WebPage {
>
> private static final long serialVersionUID = 1L;
>
> public HomePage(final PageParameters parameters) {
>
> String[] choices = new String[]{ "Wicket", "Spring", "DB4O" };
>
> final RadioGroup<String> group = new RadioGroup<String>("group", new
> Model<String>());
> ListView<String> groupView = new ListView<String>( "groupView" ,
> Arrays.asList( choices )){
> private static final long serialVersionUID = 1L;
>
> @Override
> protected void populateItem(ListItem<String> item) {
> item.add( new Radio<String>( "radio", new Model<String>() ));
> }
>
> };
> group.setOutputMarkupId( true );
> group.add( new AjaxFormChoiceComponentUpdatingBehavior(){
> private static final long serialVersionUID = 1L;
>
> @Override
> protected void onUpdate(AjaxRequestTarget target) {
> // TODO: Check this
> System.out.println( "Here" );
> }
>
> });
>
> group.add( groupView );
>
> Form<Void> form = new Form<Void>( "form" );
> form.add( group );
> add( form );
>
>
> }
> }
> --
> View this message in context: http://www.nabble.com/Problem-with-RadioGroup---Ajax-tp24300010p24302858.html
> Sent from the Wicket - User 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
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org