Skip to main content
Known Participant
August 16, 2011
Answered

strange issue using stop() to control a timeline after loadClip

  • August 16, 2011
  • 1 reply
  • 339 views

Hello, i have this strange issue:

i want to control the timeline of a swf loaded with loadClip command.

i wrote this code

var loader:MovieClipLoader = new MovieClipLoader();

loader.addListener(this);

function onLoadComplete(_mc:MovieClip) {

   _mc.play()

}; 

loader.loadClip(swfname,_root.holder)

function pause() {

_root.holder.stop()

}

function pause on a button is used to stop the playback of the loaded movieclip.

strange thing is that stop() works when testing the movie by flash application and playing it from the projector. It DOES NOT WORK when running it from swf directly or by html with swf embedded.

I checked lot of time and the name of the "container" is resolved, but the command is not working for its timeline.

thanx for helping

Daniele

This topic has been closed for replies.
Correct answer kglad

you wouldn't expect that stop() to ever work.  once loading starts, that stop() no longer applies to the target of a loadClip (or loadMovie) method.

to resolve, apply the stop() to the first frame of the loaded swf's timeline.

1 reply

kglad
Community Expert
kgladCommunity ExpertCorrect answer
Community Expert
August 16, 2011

you wouldn't expect that stop() to ever work.  once loading starts, that stop() no longer applies to the target of a loadClip (or loadMovie) method.

to resolve, apply the stop() to the first frame of the loaded swf's timeline.