Javascript syntax
for(i in x)
{
x[i].focus();
}
This works properly in Mozilla and Chrome but gives error in IE.
Error displayed is
Message: Can't move focus to the control because it is invisible, not enabled, or of a type that does not accept the focus.
I tried using try catch block as below
for(i in x)
{
try { x[i].focus(); }
catch(err){ }
}
It worked properly, but My system has more than 100 pages and dont know how many times i have used .focus
Kindly help me get rid of this IE problem.