Button script not working

I'm using Flash CS4, AS2. I'm trying to navigate to a new scene from within a moviescript. I created a nav bar with a drop down menu. The menu is within a Movieclip. I've added buttons to the drop down menu and added the following script to one of button to go to a new scene.
on (release) {
     gotoAndPlay("Scene 2", 1);
I tried a get url function on one of the buttons which seems to work.
But the go to and play function doesn't work.When I click on the button, nothing happens. Any Ideas what could be the problem.
Thanks for any help

yes, the output shows your button code is executing.  but you should not use the goto methods and you should not use scenes in navigation. 
you should use the goto methods and frame labels:
on (release) {
     _root.gotoAndPlay("Scene2_frame1");  // and label this frame. 

Similar Messages

  • Simple button script not working

    I am using AS2 and need help figuring out why this simple button script is not working:
    stop();
    buttonWS1.onRelease = function(){
                        gotoAndStop("Stage1and2_Boss",4);
    buttonWS2.onRelease = function(){
                        nextFrame();
    //end
    My buttons are the square letter-puzzles below. They are images that I converted to "symbols" (specifically, buttons). I put their names as above (buttonWS1, buttonWS2, etc.) in the "instance names" boxes.
    I have no idea what is going on. Please help!

    Hi -
    1. Yes, buttonWS2 is the instance name
    2. The only code attached to it is the code I pasted above.
    3. onRelease does not execute because my trace statement does not appear in the output
    Here is the modified code for buttonWS2:
    buttonWS2.onRelease = function(){
                        trace("clicked!");
                        nextFrame();
    Question: It shouldn't matter if I have commented-out code within that set of codes should it?:
    buttonWS2.onRelease = function(){
              //if (puzzleschosenarray[0] == 2 || puzzleschosenarray[1] == 2) {
              // cannot be chosen -- make button non-functional
              //else{
                        //puzzleschosenarray[roundnumber-1] = 2;
                        trace("clicked!");
                        nextFrame();

  • Simple button scripts not working in AS2

    Hi there,
    I am at my wits end. I've tried about 2 dozen tutorials word for word and they don't work and I just keep getting lots of strange errors.
    I have a very simple 4 frame scent with a forward and backward arrow on each frame to link them together. I have an artwork layer, a button layer and an action script layer. The action script layer contains stop(); and the following script in the buttons layer. I adjusted the gotoAndStop frame number accordingly for each frame. Below is an example of one frame. I ran them from frame 5 to 9 as the stop feature wouldn't work on the first keyframe.
    leftButton.onRelease=function(){
    trace("gotoAndStop(9)");
    rightButton.onRelease=function(){
    trace("gotoAndStop(6)");
    When I test the movie (publish it) the buttons don't work at all. I've tried many times to no avail. It just remains frozen on frame 5 and the arrows do nothing.
    Here is a screen shot of my file.
    http://marthalodge.com/Picture2.png
    Thanks for any help.

    Regarding the numbers, I was referring to instance/variable names, not frame labels.
    As far as errors go, the following is errant in that it is missing a closing parenthesis, but it also doesn't make much sense.  What are you expecting it to trace?
    trace(gotoAndStop("eight");

  • Button scripts not working

    I don't think we're in Kansas any more, Toto.  I've been programming with Director ever since version 3.0, and I can't make my buttons work in Director 11.  I realize they are now Flash components, and I realize that may present a whole new set of rules for the game.  Right now, I have a test movie set up to experiment with the Buddy API xtra for desplay resolution set and reset.  The first movie has a button labled "Continue".  It has a sprite script that says,
    on mouseUp me
       go to movie "nextMovie2"
    end
    The movie entitled "nextMovie2" has a button with a sprite script that says,
    on mouseUp me
       quit
    end
    Neither of those scripts works.  The buttons highlight when you click them (as long as the mouse is down), and unhighlight when you release the mouse, just as they should.  But nothing happens.
    There is no manual, of course, and the help files are, well, shall we say, a bit unrewarding to search through?
    Can someone tell me what I'm missing, please?
    Thanks!
    Dewey

    First of all, some advice.  Don't.  Just don't.  It is very bad form to change someone's screen resolution. It is super annoying when your program crashes and fails to bring the normal resolution back... which then messes up all the desktop icons and other system settings.  Also, you have no idea what kind of monitor people have.  In the old days, it was usually a choice between 640x480, and 1024x768 or something.  Now there are loads of options, with different width-to-height ratios (widescreen), some HD capable, some not, some LCD monitors (like mine) which will ONLY work at one specific resolution.  If I ran your program and it tried to change my screen res, it would probably just go black and I would be pissed.  Widescreen monitors will stretch your image if you set it to the wrong width.  And that is only the tip of the iceberg.  Things get even more complicated for folks (like myself) who have multiple monitors hooked up. 
    Just.  Don't.
    But that said, in an attempt to actually answer your question, the "temp" option is not what you think.  It will change it until the computer is rebooted, at which point it <should> go back to the original.  If you want to change the resolution back to the original yourself, do so in a stopMovie handler.
    And here is the docs for baSetMultiDisplay()
    http://www.mods.com.au/budapi_docs/baSetMultiDisplay.htm

  • I bought my iphone 5s a week before and now its volume "up" button is not working when pressed.Does anybody know what to do to make it work?I have a one year warranty.Should i give it to apple retail shop or is there any way to solve this problem?

    I bought my iphone 5s a week before and now its volume "up" button is not working when pressed.Does anybody know what to do to make it work?I have a one year warranty.Should i give it to apple retail shop or is there any way to solve this problem?

    IF it is a manufacturing defect and you bought the device from Apple or an authorized Apple retailer, then take it into Apple.

  • TA44551 My 1-year ipod nano locked up and would not start overnight. The on/off button will not work and stopped holding charge. No water damage, no fall, nothing unusual. I restored it (twice) but it will still not hold charge and on/off does not work.

    My 1-year ipod nano locked up and would not start overnight. The on/off button will not work and stopped holding charge. No water damage, no fall, nothing unusual. I restored it (twice) but it will still not hold charge and on/off does not work. I tried to restore it again and charged it in three different locations with different cables. etc but nothing. Suggestions?

    - After charging for 1/2 hour or so, does iTunes see the iPod?  If yes, restore the iPod from backup.
    - If no, se if placing the iPod in recovery mode will make it visible so you can restore the iPod.  For recovery mode see:
    iPhone and iPod touch: Unable to update or restore

  • Why cant I add contacts on the iphone4? the mail contacts calendars button unders settings, the contacts button, the add a contacts button under message and the phone button will not work to add a contact.

    Why cant I add contacts on the iphone4? the mail contacts calendars button unders settings, the contacts button, the add a contacts button under message and the phone button will not work to add a contact.

    Have you attempted a restore?

  • VS2005 Crystal Report Print Report Button is not working on Windows 7 x64

    Hi There,
    My application is written in VS2005 C# on x86 machine. It runs smoothly on XP pro and Vista x86 machine.
    I deployed the same to windows 7 x64 machine with CRRedist2005_x64.msi and found that the Print Report button is not working.
    So, I re-compiled my application to x64 target platform, and reinstall the application to the same machine. But nothing changed. I have surf for answer over the web but nothing found.
    Please help urgently. Any helps is much appreciated. Thks in advance.
    Edited by: chanpyvivian on Mar 26, 2010 11:14 AM

    I follow your instruction as below:
    1) download the sample app vbnet_win_printtoprinter.zip to dev computer and compile it to .NET 2005.
    - Run from my dev computer
    - Click "Print Report" button
    - Error message display - please see below
        The error was due to the default printer name hard coded in the program was not found. I have edited to my printer name and it can be printed out with no error.
    2) Use a "saved data" report so that you do not have to worry about database logon.
    can't find the "saved data", please elaborate
    3) Then copy the exe to the 64 bit box and try to print using this sample app.
    -do you mean copy the exe to the 64 bit computer for testing ?
    ERROR Message
    CrystalDecisions.CrystalReports.Engine.InvalidArgumentException:
    Invalid printer specified. ---> System.Runtime.InteropServices.COMException (0x80000201):
    Invalid printer specified.
       at CrystalDecisions.ReportAppServer.Controllers.PrintOutputControllerClass.ModifyPrinterName(String newVal)
       at CrystalDecisions.CrystalReports.Engine.PrintOptions.set_PrinterName(String value)
       at CrystalDecisions.CrystalReports.Engine.PrintOptions.Copy(PrintOptions src)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob)
       --- End of inner exception stack trace ---
       at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob)
       at CrystalDecisions.CrystalReports.Engine.ReportClass.Load(String reportName, OpenReportMethod openMethod, Int16 parentJob)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.EnsureLoadReport()
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.get_FormatEngine()
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.PrintToPrinter(Int32 nCopies, Boolean collated, Int32 startPageN, Int32 endPageN)
       at PrintToPrinter.Form1.Button1_Click(Object sender, EventArgs e) in C:\Crystal\CRNET\vbnet_win_printtoprinter\vbnet_win_printtoprinter\Form1.vb:line 91
    OK  
    Edited by: chanpyvivian on Mar 30, 2010 6:18 PM

  • My G4 powerbook starts up but with a black screen. The reset button does not work. Does anyone know the keys to press on restart please ?

    My G4 powerbook running OSX 10.3.9 starts up with  a black screen. The reset button is not working. Does anyone know which keys to press on restart please.?

    Try holding the shift key while booting to get Safe mode if possible.
    See links for more info.
    http://support.apple.com/kb/ht1564
    http://support.apple.com/kb/ht1455

  • Froze on black screen and power button does not work

    my sons ipod touch is stuck on a black screen when plugged into the computer got a spinning wheel and will not connect now spinning wheel will not go away the power button does not work so can not reset it manually
    any suggestions would be appreciated

    - iOS: Not responding or does not turn on
    Neglect the reset and when it says place the iPod in recovery mode use one of thes programs
    - If not successful and you can't fully turn the iOS device fully off, let the battery fully drain. After charging for an least an hour try the above again.
    - Try on another computer          
    - If still not successful that usually indicates a hardware problem and an appointment at the Genius Bar of an Apple store is in order.
    Apple Retail Store - Genius Bar       

  • Is there anyway to power off an I-phone 4s if the power button is not working?

    Is there anyway to power off the phone if the power button is not working?

    Assistive Touch. Tap Settings App > General > Accessibility > Assistive Touch > ON > at bottom of screen tap button > Device > press and hold Lock Screen icon > when slide to power off appears > slide it. To turn iPhone ON connect to Power Source with USB cable, charger or USB port of computer.
    All iPhone 4S have full Warranty Coverage. Make Genius Reservation and take iPhone to Apple for resolution.

  • I have unabled 5 fingure gesture now not able to perform any task,also my power button is not working,please help me in removing this gesture,using I phone 4

    I have unabled 5 fingure gesture now not able to perform any task,also my power button is not working,please help me in removing this gesture,using I phone 4

    I have unabled 5 fingure gesture now not able to perform any task,also my power button is not working,please help me in removing this gesture,using I phone 4

  • With version 5 of Firefox, if I open more than 1 session, most of the time I cannot see anything in the navigation bar and my back and forward buttons do not work.

    I open 1 session of Firefox 5.0.1 and everything seems to work fine. Then I open a second session of Firefox and most of the time the navigation bar does not show the page that I am on and the back and forward buttons do not work. When this happens, the first session always remains working. I am an internet marketer so I have at least 2 or 3 sessions going at any given time.

    A possible cause is a problem with the file places.sqlite that stores the bookmarks and the history.
    *http://kb.mozillazine.org/Bookmarks_history_and_toolbar_buttons_not_working_-_Firefox
    Start Firefox in <u>[[Safe Mode]]</u> to check if one of the extensions is causing the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > Appearance/Themes).
    *Don't make any changes on the Safe mode start window.
    *https://support.mozilla.com/kb/Safe+Mode
    *https://support.mozilla.com/kb/Troubleshooting+extensions+and+themes

  • Firefox did an automatic update to 6.01, and now my middle mouse button is not working in the browser. It doesn't close tabs, it doesn't open new tabs by middle clicking a link, it doesn't allow me to middle click to scroll the page...

    Firefox did an automatic update to 6.01, and now my middle mouse button is not working in the browser. It doesn't close tabs, it doesn't open new tabs by middle clicking a link, it doesn't allow me to middle click to scroll the page..

    [BUG FIXED, see "EDIT 2" at the end of my post]
    I'm on Firefox 3.6.21, and I got this problem today after a Greasemonkey update (To version 0.9.10, apparently).
    Disabling Greasemonkey solved the problem, and re-enabling it reproduced the problem (middle-clicking links to open in new tab did not work, merely highlighted the link).
    I should also note that while Greasemonkey was enabled and the bug was affecting me, Ctrl+Click to open links in new tabs was also broken.
    I hope this helps!
    EDIT: It appears this is a known incompatibility/conflict bug between current versions of Greasemonkey and Tab Mix Plus. Read more here:
    https://github.com/greasemonkey/greasemonkey/issues/1406
    EDIT 2: GREASEMONKEY HAS NOW BEEN UPDATED with a workaround to fix the problem. Go to https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/versions/ to install the update manually. It hasn't been reviewed by Mozilla yet, so it won't be an automatic update for another day or two. All credit to "cannonfodder" below for noticing this; please mark his post as helpful!

  • Help button is not working in Infoview

    Hi All ,
    I am working on BO XI R2 environment and help button is not working properly in my infoview.
    I can get help files from Admin console but the same is not true with infoview.I got two different server installations, one of them its working fine but not for the other.
    I checked for help files in IIS and they are there , even I verified web.config file as well for infoview and it also seems to be correct.
    Please advice what could be the reason.
    Thanks,
    Vivek.

    CLOSED

Maybe you are looking for

  • Workflow Tasks NOT expiring!

    Hi guys, I've bumped lately with an issue building a workflow on SP2010, as you mostly already have figured out from the title, workflow tasks are NOT expiring. I've tried to take this on my own, but no more as I have to move on. Here's the details;

  • Bug in ADF installer 10.1.3.2?

    I am running IAS 10.1.3.0 and since I am developing in Jdev 10.1.3.2 and I was getting the following error: java.lang.NoSuchMethodError: oracle.adf.share.perf.StateTracker.isActive()Z when deploying and running my application so I figured I needed AD

  • Data tuncated in file adapter scenario

    Hi, File adapter scenario - Sender systems passes a file (csv format) to PI which has one of field as 0001. This field is received at PI without the prefix 000. But, the target systems requires the data to be in the same format as the sender. How to

  • Creative CMV video format used by Zen MX

    Do we know of anything other than the "Creative Centrale" application that can convert video files to the CMV format used by the Zen MX Or if there's anything in the pipeline? It's just that Centrale's video conversion is slow and, so far as I can ma

  • Install SCVMM2008 error in sql server

    Hi, I am new to SCVMM, I tried install the SCVMM2008 and I get the error: I am sure my sql server version is 2012. Why the error message is about sql server 2008? How do I fix it. Please help me. Thanks