views:

559

answers:

1

I've made an interactive tour. Which can be seen here:

http://www.92YTribeca.org/Tour

The main swf is the nav at the top. And I load 4 external swfs into the main (About, Rentals, Floorplan, Neighborhood).

I need a button in Floorplan.swf to load Rental.swf AND gotoAndStop("CAFE") - a frame within Rental.swf.

This is the code that I am working with right now..

btnFLRcafe.onRelease = function(){

var loader:MovieClipLoader = new MovieClipLoader(); loader.addListener(this);

function onLoadComplete(loadedClip) { loadedClip._root.mcRENTALS.gotoAndStop("CAFE"); }

loader.loadClip("maps_92Tri_RentalsMain.swf", 1); }

The code will load the swf, but it DOES NOT gotoAndStop. I've rearrange and rewrote - nothing worked. When I put traces on the code, it seems that onLoadComplete isn't even being called. I am at a loss. Please help!!

I can send files if needed.

Thanks!

A: 

Instead of having a method for onLoadComplete, try adding one called onLoadInit(loadedClip)

Hope this helps!

--

Here is some basic code for what I think you are trying to do. I have a main swf which has a button on the stage. On the button, I had the following actions...

on(release) {

    var loader:MovieClipLoader = new MovieClipLoader();
    loader.addListener(this);

    function onLoadInit(loadedClip:MovieClip) {
     _root.contentArea.gotoAndPlay("ANIMATE");
    };

    loader.loadClip("Loaded.swf", _root.contentArea);
}

In the main move, I have another clip on the stage named contentArea where the Loaded.swf file will be loaded in to. Loaded.swf has a frame label called "ANIMATE" which starts a small animation on the timeline.

Hope this helps!

Chris Gutierrez
I've tried this... doesn't work? Any more suggestions?
jecca411