jQWidgets Forums

jQuery UI Widgets Forums Angular how to bind input value change event

This topic contains 2 replies, has 2 voices, and was last updated by  steelman 6 years, 9 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • how to bind input value change event #102049

    steelman
    Participant

    the input is created by jqwidgets.createInstance,code is below:

    this.inputOfEditor = jqwidgets.createInstance(‘.flag’, ‘jqxInput’, options);
    this.inputOfEditor.addEventListener(‘change’, (event: any): void => { console.log(‘this.inputOfEditor value chage’); });

    the code of second line is error,how to do?
    thanks

    how to bind input value change event #102060

    Martin
    Participant

    Hello steelman,

    You should add the event listener on this.inputOfEditor.input as this is the HTMLElement.

    this.inputOfEditor = jqwidgets.createInstance(‘.flag’, ‘jqxInput’, options);
    this.inputOfEditor.input.addEventListener(‘change’, (event: any): void => { console.log(‘this.inputOfEditor value chage’); });

    Best Regards,
    Martin

    jQWidgets Team
    http://www.jqwidgets.com/

    how to bind input value change event #102068

    steelman
    Participant

    thanks very much

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.