OnBlur while Applet loads in JSP page

k_murli_krishna
k_murli_krishna used Ask the Experts™
on
I have a jsp page in which applet is present. Now When the applet loads completely onblur() event is fired automatically. I want to stop this onblur() event from being fired as the first editable field in my jsp is losing focus because of the automatic on blur event.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

Author

Commented:
Sorry for little delay in reply. The link suggests that solution lies in JavaScript. Can you give a text or even actual script solution in JavaScript.
Sure!

You can set focus to a textfield like this:

http://lena.franken.de/software/javascript/index.html
See "Setting focus to an input-field" title



In easy words, just do this:
document.forms[0].MyTxtBox.focus();
Exploring SQL Server 2016: Fundamentals

Learn the fundamentals of Microsoft SQL Server, a relational database management system that stores and retrieves data when requested by other software applications.

Author

Commented:
Your suggestions did not work out for the problem faced. Basically onBlur is firing automatically/inherently when applet loads. This needs to be stopped and not that we can have any other solution.
When you got focus on your Applet, then try to focus on your textbox.

Set a timeout, like SetTimeout(yourfocussetterfunction, 2000);

Then you'll be able to focus. There is no other solution available

Author

Commented:
Thanks.

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