Additional Events - OnLostFocus or OnExit

First question from a newbie:

My question concerns the screen actions that fire from events.  Specifically, in a textbox, I can create a screen action for the OnChange event, but I'm wondering if there's a way I can fire the action when the textbox loses focus (ie the user tabs to the next textbox or clicks a button).  I am not able to find anything in the help system or in the community concerning an event like OnLostFocus or OnExit for the textbox control.

I am attempting to query the database to ensure that a particular ID number is not already in use, but I'd like to check before the Save button is pressed (optimally when the entire ID number is entered and the user moves onto the next input field).  I don't want it on the OnChange event, obviously, since that would query the database on every key press, which is clearly suboptimal.

Is what I'm asking possible, or is this a pipe dream in the fevered brain of a broken-toothed madman?  (more colorful euphemisms for a "Yes, here's how:" answer)

Thank you for your time and assistance.
Hello Chris.

There's hope :)

This is still a web page so, you can always add the JavaScript (events in this case) as you need. In the extended properties, you can add the name of the event, and then a call to a JavaScript function.

I would have a JavaScript function that would trigger a hidden button.

Hope it helps!
He guys, does one of you both have an exmple of this, since I'm not such a javascript wizzard and struggling with exactly the same challenge ...???

Thanks in advance.
Hello Chris,

First of all, I think you should use the onblur event to solve your issue.
Do to that, you just have to follow Pedro's tips and use the extended properties in the control that you one to use to trigger the event.

@Eric, just an example to show you - Imagine you want to check if an email on an input text control is valid.
You can call the action using for example a (1) javascript function directly or a (2) screen action (using a click on a hidden click):



Hope it helps.

Kind Regards,
Gonçalo M.
Hi Gonçalo,

Nice post..Just a note, I can't see the images width properly, without editing the Html with the browser dev tools.

Thank you for your note..
I already edit the image size to be seen properly in the post frame.

Gonçalo M.