A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: on release question

  1. #1
    Senior Member
    Join Date
    Aug 2000
    Posts
    343

    on release question

    Hi
    Just wondering what the proper syntax is to accomplish "on release, go to this frame and load this movie...

    I know how to do
    Code:
    on(release) {
    	gotoAndPlay(1);
    }
    and

    Code:
    on(release){
    loader.loadMovie("movie.swf");
    }
    Just don't know how to put the 2 into one snippet of code.
    Losse

  2. #2
    Senior Member whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,756
    you cant really..

    once you move to a new frame..all code is 'gone' (more or less)

    You could however do something like:


    PHP Code:
    var target:String;

    button1.onPress = function(){
        
    gotoAndStop(5);
    }

    //and on frame 5 have this code

    loader.loadMovie(target); 
    this is assuming that on frame '5' that there is a container/object with the instance name of loader.. so that the image has something to load 'into'...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center