You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Sibgha Nazir <si...@gmail.com> on 2019/05/20 14:13:30 UTC

Wicket DropDown Change event

Hi,

I am not able to trigger the on change event of the drop down in the
wicket.

In the class DPanel,java, I am simply trying to print on the console when
the change event has occured.

        dropdown.add(*new* AjaxFormComponentUpdatingBehavior("onchange") {

            /**

             *

             */

            *private* *static* *final* *long* *serialVersionUID* =
-6744838136235652577L;


            *protected* *void* onUpdate(AjaxRequestTarget target) {

                System.*out*.println("Changed");


            }

        });

Need Help. Following is my quick start application.
https://github.com/Sibgha360/dropdownexample.git

Thanks

Re: Wicket DropDown Change event

Posted by Ernesto Reinaldo Barreiro <re...@gmail.com>.
Look at OnChangeAjaxBehavior

On Mon, May 20, 2019 at 4:13 PM Sibgha Nazir <si...@gmail.com> wrote:

> Hi,
>
> I am not able to trigger the on change event of the drop down in the
> wicket.
>
> In the class DPanel,java, I am simply trying to print on the console when
> the change event has occured.
>
>         dropdown.add(*new* AjaxFormComponentUpdatingBehavior("onchange") {
>
>             /**
>
>              *
>
>              */
>
>             *private* *static* *final* *long* *serialVersionUID* =
> -6744838136235652577L;
>
>
>             *protected* *void* onUpdate(AjaxRequestTarget target) {
>
>                 System.*out*.println("Changed");
>
>
>             }
>
>         });
>
> Need Help. Following is my quick start application.
> https://github.com/Sibgha360/dropdownexample.git
>
> Thanks
>


-- 
Regards - Ernesto Reinaldo Barreiro

AW: Wicket DropDown Change event

Posted by "Drummer, Matthias" <ma...@iqtig.org>.
Hi,

use "change" instead of "onchange".

dropdown.add(new AjaxFormComponentUpdatingBehavior("change") {

This works for me on Wicket 8.4.0

Greetings Matthias

-----Ursprüngliche Nachricht-----
Von: Sibgha Nazir <si...@gmail.com> 
Gesendet: Montag, 20. Mai 2019 16:14
An: users@wicket.apache.org
Betreff: Wicket DropDown Change event

Hi,

I am not able to trigger the on change event of the drop down in the wicket.

In the class DPanel,java, I am simply trying to print on the console when the change event has occured.

        dropdown.add(*new* AjaxFormComponentUpdatingBehavior("onchange") {

            /**

             *

             */

            *private* *static* *final* *long* *serialVersionUID* = -6744838136235652577L;


            *protected* *void* onUpdate(AjaxRequestTarget target) {

                System.*out*.println("Changed");


            }

        });

Need Help. Following is my quick start application.
https://github.com/Sibgha360/dropdownexample.git

Thanks

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org