On Fri, 24 May 2013 11:26:43 -0700 (PDT), justaguy <
lichun...@gmail.com>
wrote in <
3d37a9e7-b930-4e64...@googlegroups.com>:
>However, the cursor does not go with the above action, that is, the screen remains the same (still at the bottom of the right DIV). What could I do to make the cursor to move to the top of the left DIV?
>My attempt of adding the following statement,
>document.getElementById('leftD').focus();
>prior to clickAction
>OR
>after
>has no effects.
You described:
document.getElementById('leftD').focus();
function clickAction(){code}
OR
function clickAction(){code}
document.getElementById('leftD').focus();
will not get the focus statement executed.
You need:
onclick="clickAction();document.getElementById('leftD').focus();"
OR
function clickAction(){code ;
document.getElementById('leftD').focus(); }
HTH