Professional Web Applications Themes

whats wrong here? - Macromedia Flash Sitedesign

I have the following code. the trace and if arent working properyl. The loadmovie is happening onrelease, instead of after the frame 36. Anyone know about this? on (release) { gotoAndPlay(transition=2); } on (release) { trace("transition._currentframe"); if (transition._currentframe =36) { loadMovie("flash/contact.swf", "holder"); } } Thanks, mj...

  1. #1

    Default whats wrong here?

    I have the following code. the trace and if arent working properyl. The
    loadmovie is happening onrelease, instead of after the frame 36. Anyone
    know about this?



    on (release) {
    gotoAndPlay(transition=2);
    }
    on (release) {
    trace("transition._currentframe");
    if (transition._currentframe =36) {
    loadMovie("flash/contact.swf", "holder");
    }
    }



    Thanks,
    mj


    Bionicegg Guest

  2. #2

    Default Re: whats wrong here?

    ok, well, your first on release should be like this:

    on(release){
    _root.transition.gotoAndPlay(2);
    }

    and second, if youre trying to check if the clip has reached frame 36, your
    code wont work, because it is only executed when the user presses the button,
    and so, transition will reach frame 36 and nothing will happen because the
    button isnt clicked.

    to solve your problem, create an empty movie clip, frame 1 actions will be:
    stop();

    frame 2:
    if(_root.transition._currentframe = 36){
    loadMovie("flash/contact.swf", _root.holder);
    gotoAndStop(1);
    }

    frame 3:

    gotoAndPlay(2);


    now, what this clip will do is check to see if the transition movieclip has
    reached frame 36, and if it does, load the movie, and go to frame 1 and stop
    (not the loaded movie though)

    now, give the recently created movie clip an instance of "checker" and place
    it on the root timeline.

    on your button, to make everything work, put:

    on(release){
    _root.checker.gotoAndPlay(2);
    }


    hope that helped you!

    fasterthanlight Guest

  3. #3

    Default Re: whats wrong here?

    Thanks man, I got it to work by adding another = before 36. Now I just have
    to create a checker for each button and Im set. Thank you so much!

    MJ

    "fasterthanlight" <com> wrote in message
    news:caij5i$t3j$macromedia.com... 
    your 
    button, 
    be: 
    has 
    stop 
    place 


    Bionicegg Guest

Similar Threads

  1. hmm whats wrong ??
    By mak999 in forum Macromedia Flash Flashcom
    Replies: 0
    Last Post: February 16th, 10:05 PM
  2. whats wrong with my sql?
    By loofa in forum Coldfusion Database Access
    Replies: 3
    Last Post: July 25th, 08:47 AM
  3. Anyone know whats wrong with this?
    By Mike M in forum ASP Database
    Replies: 5
    Last Post: February 17th, 11:56 PM
  4. [PHP] Whats wrong?
    By Ryan A in forum PHP Development
    Replies: 0
    Last Post: September 13th, 01:07 PM
  5. Replies: 0
    Last Post: July 10th, 03:39 PM

Bookmarks

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139