Solved

listener to gotoandplay in the loaded swf file and not container swf file on complete

Posted on 2008-10-11
1
263 Views
Last Modified: 2013-11-11
I put the below code in a file called trailer.swf. The trailer.swf is loaded into main.swf. I want the trailer.swf to gotoandstop on frame ten in trailer.swf and not main.swf. What is the necessary syntax..?
this. doesnt work nor does root.

Your Help is appreciated...here is the link to the website

http://btcmovie.com/btcultimate/phase1/


import mx.video.*;

this.attachMovie("FLVPlayback", "my_FLVPlybk", 1, {width:640, height:360, x:147.6, y:-21.5});

 

this.my_FLVPlybk.width = 640;

this.my_FLVPlybk.height = 360;

this.my_FLVPlybk.contentPath = "http://journeybeyondthechair.com/preview/flv/640by360.flv";

this.my_FLVPlybk.skin = "http://journeybeyondthechair.com/flash/ClearExternalPlaySeekMute.swf";

 

var listener = new Object();

listener.complete = function(evt)

{

  removeMovieClip(my_FLVPlybk);

gotoAndStop(10);

}

this.my_FLVPlybk.addEventListener( "complete", listener );

Open in new window

0
Comment
Question by:jmanstorm
1 Comment
 
LVL 39

Accepted Solution

by:
blue-genie earned 500 total points
ID: 22697437
you can't use this because this will refer to the listener object.
so how you target your trailer.swf file will depend on how you loaded it.

i.e. if you used loadMovieNum("trailer.swf", 1);
then you'll target it with _level1.gotoAndStop(10);

etc.

0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

There are times in your Flash CS4 application when you want more than a simple pointer or a hand, and it's hard to find an ideal walk-through to tell you what to do.  I spent a few days recently learning my way around making custom cursors in Flash,…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
The goal of the tutorial is to teach the user how to how to record live broadcast.
The goal of the tutorial is to teach the user how to select which audio input to use. Once you have an audio input plugged into the laptop or computer, you will go into the audio input settings and choose which audio input you want to use.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now