-
After FLV Plays, Go back to beginning of movie?
I have a simple file that I'm trying to add fuctionality to -- it is basically a button that uses this code to play a video:
Code:
button.onRelease = function() {
this._visible = false;
trace("clicked "+this._name);
};
So, that works great. You click a button, the video plays. My question is, once the FLV is done, how do I get the flash file to go back to the beginning and once again show the Button, and rewind the video? As it stands right now, it just sits on the last frame of the .flv.
THANKS!
-
I've been trying to figure this out, and so far I've got this far:
Code:
var listenerObject:Object = new Object();
listenerObject.complete = function(eventObject:Object):Void {
// what do I put here
};
myVideo.addEventListener("complete", listenerObject);
So what I need to know is this: What do I put in the "what do I put here" section that will basically restart the .swf from the very start ... where the button showed up (see my previous post).
Help?
-
Senior Member
If you want the video to loop you would put
myVideo.play();
If you wanted it to go back to the first frame of the flv
myVideo.rewind();
This is your brain. This is your brain on script.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|