[thelist] FLASH: Stop and Start a Movie

matthew garrett matthew.garrett at snet.net
Mon Mar 18 21:51:01 CST 2002


> From: "Casey Crookston" <casey.crookston at imibevcore.com>

> I'm putting together a little Flash show, and I need to be able to stop the
> show every so often, and then start it up again based on a key stroke.  Making
> the stop is no problem, but I can't figure out how to make it start again when
> the user hits a key - any key.

Hi,
In Flash 5:
I'm semi guessing on this, but i think you need to add a button to each
frame on which you stop (it can be a "blank", or invisible, button). Then
attach an action to that instance of the button object. You can start with
an "onMouseEvent" action, and then select the keyPress option...

on (keyPress "") {
    play ();
}

I don't know what the default is if you don't specify a key (as above). But,
for example, if you want to use the space bar - then it would be:

on (keyPress "<Space>") {
    play ();
}

I'm sure someone more qualified will be along shortly, but maybe this is
enough to get you started.
matt g.






More information about the thelist mailing list