pigghost
08-22-2001, 03:57 PM
Hi...I'm trying to set the focus of an swf in an HTML page using JavaScript...
What I've got works great in IE 5.5 on PC...in Netscape 4.7 I get a JavaScript Error...here's what I have in the HEAD...
<script language="javascript">
function focusMovie(){
window.document.mymovie.focus();
}
</script>
...and I'm calling it in the BODY with
onLoad="focusMovie()"
...and of course I've given the movie the ID="mymovie" in the Object and name="mymovie" and swLiveConnect="true" in the Embed.....
I put together a quick little demonstration...if you use IE 5.5 on PC you should be able to, without clicking the movie first, move the box left and right with the arrow keys...but not with Netscape...this is with PC, not sure what happens on a MAC...
http://www.hotgreen3.com/setFocus.html
Anyone have a clue what the problem is?? I've done searches at several boards and seen hints that this should work, but I can't really find any documentation...not even at MM, although I'm still looking...
Thanks for taking a look...
-pigghost-
What I've got works great in IE 5.5 on PC...in Netscape 4.7 I get a JavaScript Error...here's what I have in the HEAD...
<script language="javascript">
function focusMovie(){
window.document.mymovie.focus();
}
</script>
...and I'm calling it in the BODY with
onLoad="focusMovie()"
...and of course I've given the movie the ID="mymovie" in the Object and name="mymovie" and swLiveConnect="true" in the Embed.....
I put together a quick little demonstration...if you use IE 5.5 on PC you should be able to, without clicking the movie first, move the box left and right with the arrow keys...but not with Netscape...this is with PC, not sure what happens on a MAC...
http://www.hotgreen3.com/setFocus.html
Anyone have a clue what the problem is?? I've done searches at several boards and seen hints that this should work, but I can't really find any documentation...not even at MM, although I'm still looking...
Thanks for taking a look...
-pigghost-