Hi
On textbox I am giving en event onfocus anf have set it's handler. When focus comes to the textbox, handler executes but it's execution is never stopped. It's getting invoked automatically.
Is this the bug in platform?
Thanks and Regards,
Suraj Borade
Hi @Suraj Borade ,
After testing the same on my sandbox I have similar behavior, but I think this simply happens because while on debug, the focus will go to your service studio window, and basically when you advance on debug and finish the action flow, the focus goes again back to the browser and to the input field that you had previously focused on, causing the onFocus handler to run again.
This seems to happen everytime you leave a page you're on and come back. To prove this you can do the following exercise:
So yes may be a unexcepted behavior while debugging, however you can confirm that at runtime the Handler does NOT run multiple times (as long as your user stays on the app window), and only runs when input is focused.
My point is: the "bug" you are getting while debugging is justifiable because of what I described above, and should not affect your actual app behavior in runtime
In any case if you really need this behavior to not happen at runtime while going to other tabs/windows, I will try to investigate further if that is possible and will get back to you if I find something!
Kind regards,
Paulo