OnfocusOut/onlick() in javascript

theartha used Ask the Experts™
Hi There,

I have a question regarding onFocusOut/Onclick in javascript.

I have an onclick function, which works fine when I clicked the button after entering the values in the fields and display the results.

How can I call the onlclick function when my focus is out from the input fields.?

Instead of writing new events for onfocusout, I want to simulate the onClick function by losing the focus(without clicking the button) to display the results.

any clues?


Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Systems architect
Top Expert 2006
Check this:

<title>Zvonko &#42;</title>
<input type="text" name="myText" onBlur="this.form.myButton.click()" >
<input type="button" name="myButton" value="Show" onClick="alert(this.form.myText.value)" >

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial