BPM, Workflow, and Case

 View Only
  • 1.  Type ahead text input

    Posted 8 hours ago
    I'm using Type Ahead Text on a screen. I want to get the event (On Input) when a value is entered from the keyboard. Unfortunately, the On Input event is not available in Type Ahead Text like it is in the Plain Text object. I add the HTML attribute 'oninput,' but I cannot access the value from here.
     
    Does anyone have any ideas?


    ------------------------------
    MEHMET SELİM ARLI
    ------------------------------


  • 2.  RE: Type ahead text input

    Posted 3 hours ago

    I have had success adding event handlers to views by access the view.context.element. 

    So you could add the following in your "on load" for the typeahead. If me.context.element doesn't work, you can try getting the actual input element which is:  me._instance.text. 

    // adding to the view element
    me.context.element.oninput = (e) => {
      const inputData = e.data; // this is the value of the input event 
      const value = me.getData(); // this is the value of the view (probably won't have the value you want)
      // do what you want with the value
    }
    
    // adding to the input itself
    me._instance.text.oninput = (e) => {
      const inputData = e.data; // this is the value of the input event 
      const value = me.getData(); // this is the value of the view (probably won't have the value you want)
      // do what you want with the value
    }



    ------------------------------
    Julie Garza
    ------------------------------