Link to home
Start Free TrialLog in
Avatar of aidan09
aidan09

asked on

on exit from pop-up loaded .swf, main movie must 'goto and play' - HOW?!!

Hi there

I have a movie that loads an swf above the main interface.
How do I instruct the playhead to go somewhere on the main timeline when i click out of the loaded swf?

thanks
Aidan

Avatar of blue-genie
blue-genie
Flag of South Africa image

you can target the main timeline (i'm assuming you're referring to what you call the main interface) by simply preceding your code with _root.

ie. _root.gotoAndStop(2);

blu.
Avatar of aidan09
aidan09

ASKER

at the moment, I have

on (release) {
    unloadMovieNum(1);
}
on (release) {
    _root.gotoAndStop(framename);
}

but it's just unloading the swf
??


thanks
aidan
Avatar of aidan09

ASKER

make that:

on (release) {
    unloadMovieNum(1);
    _root.gotoAndStop(1945);
}

the movie unloads, but the playhead is still at the same frame where the swf launched from
Avatar of aidan09

ASKER

the button that exits from the loaded swf in level in is contained in that swf rite?

should the exit button call from the main timeline to the loaded swf?

ASKER CERTIFIED SOLUTION
Avatar of blue-genie
blue-genie
Flag of South Africa image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
aah ok, *lightbulb moment*

you have the button inside the swf which is loaded onto the main movie,
so your code then should be (from the button in the loaded swf).

on (release) {
     unloadMovie(this);
     _level0.gotoAndStop(30);
}
have a good weekend, good luck
quick explanation, in the first example where i thought the exit button was in the main movie, using _root will refer to itself, but since your button is in the swf, then you need to refer to the level, which is _level0 as _root will refer to the swf's own main timeline.

:-)

Avatar of aidan09

ASKER

thanks mate - fantastic!!!
u got me thinking linear again - and it worked!!

thanks for the effort!

aidan