dcsimg
A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: Button Problem/Question

Hybrid View

  1. #1
    Junior Member
    Join Date
    Jan 2003
    Posts
    18

    Button Problem/Question

    I have buttons with on release handlers telling them to go to a specific frame label. They work fine - but if you click them twice (consecutively) - on the second click the page goes blank - if you click it again - the data reappears.

    I've tried a couple of things - making the section more than a frame long - updating after event - but noothing seems to work - any advice?

    You can see what I am talking about at:

    http://www.maniacalworld.com/new/

    CLick on Maniacal and after the interface loads you can click on the Our Company button or the Our Advocates button to see what I mean.

    Thanks!

  2. #2
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    So whats the code on the button?

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

  3. #3
    Junior Member
    Join Date
    Jan 2003
    Posts
    18
    on release go to and play "whatever"

  4. #4
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    The first time I click Our Company nothing shows, second time it shows, and the other way around for Our Advocates.

    So its all in the same timeline, buttons and labels, images and text?

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

  5. #5
    Junior Member
    Join Date
    Jan 2003
    Posts
    18
    The reason for the reverse is that when you get to the movie you are already at the Company label.

    The button is actually two levels down - it is in a menu movie clip which is in a header movie clip. The AS on the Company button is:

    on (release) {
    tellTarget ("_root") {
    gotoAndPlay("Company");
    }
    }

    The AS on the Advocate button is:

    on (release) {
    _global.advocateLogo = "cognosLogo.swf";
    _global.advocateNameData = "- Ivanka Jotic, Marketing Manager";
    _global.advocateTextData = "Maniacal Marketing has been our promotional marketing company for over a year. I have had jobs that require very expedient service and they have been done on time - every time! I feel extremely confident in their ability to provide outstanding solutions for my marketing needs as well as making it enjoyable to work with.";
    tellTarget ("_root") {
    gotoAndPlay("Advocates");
    }
    }

    Thanks for your assistance

  6. #6
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    What happens if you use gotoAndStop ( I see no reason for using play as theres no animation )?
    And while you are at it you can change the depricated TellTarget with the more space saving ......

    _root.gotoAndStop("Company");

    ( for fun you can check which frame the timeline goes to when its blank, you can paste the code below on any mc in the timeline and make a textfield called showFrame )

    onClipEvent(enterFrame){
    _root.showFrame=_root._currentframe;
    }

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

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