Replay does not work on the first click

I have a single layer of Flash Action script and I have a BACK button, but it takes 2 clicks to replay. Anyone know why?

buttonReplay.addEventListener (MouseEvent.CLICK, playAgain);

function playAgain(event:MouseEvent) {}

removeEventListener (Event.ENTER_FRAME, moveGift);

onSnow.removeEventListener (MouseEvent.CLICK, decorationsOn);

star.removeEventListener (MouseEvent.CLICK, lightsOn);

bowButton.removeEventListener (MouseEvent.CLICK, surprise);

myChannel.stop ();

gotoAndPlay (1);

}

Don't you have something or stop() on the first image too? I am convinced that the problem is NOT the button. If you add trace ("PLAY AGAIN!"); in the playAgain() function, I am sure that it will trace every time that you click. If you have any scripts to initialize on frame 1, you should not go back to repat the animation because all the initializations will run again. Try to replace gotoAndPlay (1) gotoAndPlay (2) for beginners. It might work.

If not, isolate the code in the first frame initialization and everything that is related at the beginning of the animation, place in box 2.

Tags: Adobe Animate

Similar Questions

  • Click event does not work for the first choice of object field index

    Hello

    In my application, there is a ObjectChoiceField inMainScreen

    I want to get change Listner of ObjectChoiceField after clicking on index 0. When I am clicking on the second element of the choice field, I am able to move to another screen. But for the first selection of the element, it does not move on the screen.

    if(field == mOcfVehicle)
                {
                    Logger.out("MyProf", "vehicle choice field touched ");
                    int index = mOcfVehicle.getSelectedIndex();
                    Vector vecVID = store.getVehicleID("VehicleID");
                    final String strVehId = vecVID.elementAt(index).toString();
                    UiApplication.getUiApplication().invokeLater(new Runnable() {
    
                        public void run() {
                            // TODO Auto-generated method stub
                            UiApplication.getUiApplication().popScreen(MyProfScreen.this);
                            UiApplication.getUiApplication().pushScreen(new AddNewCarScreen(1, strVehId));
                        }
                    });
    //
                }
    

    Please help me...

    Here it happens little differently. I explain the requirement properly. Suppose that the I am A screen where I have the ObjectChoiceField. I added a choice of X. Now, when I am pressing on the field of choice and selection, it must pass on the screen (B) but that the choice of the field is choice (X) only one, it is not mobile. Now if, after the addition of the choice of two X and Y, if I select go, it's going to screen B. But when again, the field of choice has 2 options X and Y with X as the default selection. There is therefore no chance for me to choose the X.

    Therefore, I have added a Select called default choice. Now, if X is added, field of choice is the choice of towing display: Select and X. And while choosing X, it moves on the screen B.

    Hopefully now, it is good for understanding.

    And can help me please to this: http://supportforums.blackberry.com/t5/Java-Development/How-to-on-the-Camera-Flash-for-a-long-time-l...

    Thank you.

  • Replace with After Effects Composition does not work in the first

    I get the message "the importer reported a generic error.  I tried it on clips without effects and normal rate 23.98, and it still does not work.  I installed CC cloud and it's a brand new IMac, so I am at a loss as to why it does not work.    For any help or suggestion would be greatly appreciated!  Thank you very much

    Don't use tracing with AE CC 2014.  It doesn't help.  It is preferable to use C4D Lite, which now comes with AE and is much better... and it does more.

  • BrowserField loads pages initially, but does not work after the first load

    My app displays pages within a BrowserField. The app is basically a wrapper for a Web site, so a lot of navigation should take place within the browser. When the page first loads, it loads the site very well, but if you click on one of the links, it never loads the page.

    Unknown, the entire application works fine in the Simulator, the first page and all other pages load fine. You can click on any link, and it will.

    I have a BrowserFieldListener and a BrowserFieldController to detect when a page is loaded (at the end of the animation to load and display the browser) and when the user clicks on a link (to start the loading animation and hide the browser). Breakpoints in both of these functions (handleNavigationRequest and documentLoaded) show that the first time, the two are achieved, but when the user clicks on a link, handleNavigationRequest is in the race, but never documentLoaded.

    Does anyone have any idea on this? She was driving me crazy. I don't understand why it works in the Simulator, but not a real device.

    -Thank you

    Solved my problem. A BrowserField won't do anything if it's not attatched to a Manager. Why it loads the original page without being a manager is a mystery, but keep it on the page can load very well.

    Who knows.

  • Drag - move does not work on the first extension

    Hi all

    I'm a new user in Flex. And now, I am trying to create the first plugin.

    -the problem is that I use drag and drop to the desktop application event, works fine, when I debug it to first Extension, access the extension on the creation and the event does not properly.

    The error is Error #1034: Type coercion failed: cannot convert mx.events::DragEvent@7fff8465a19 in mx.events.DragEvent.

    The same two events and already worked in desktop application. Is this a bug or what Miss me?

    Thanks in advance

    Drag-n-drop works fine; See SDKPanel/src/ImportFilesDlg.mxml:handleFileDragStart ().

    I recommend starting a project Panel (based on SDKPanel), then pull in your office room by room application code.

  • Check for new messages at startup does not work in the first period of 10 minutes after v38 updated. Work at the end of 10 minutes. CAUSE unknown - went away after reinstall

    After the 38.0.1 of 31 thunderbird update does not check for messages at startup, tried on two workstations, mail for a single account on each account, one was pop and other imap. The check box in the accounts-> server settings has no effect. Or not safe mode or the option advanced messages "include this server when getting new messages". "." Activity Manager shows not even he is trying to connect. The question mark function still works well so if I wait 10 minutes he gets messages automatically...

    said rafikiphoto

    I reinstalled the program once more and it works OK but it's already happened and it fails once more.

    The last installation permanently solve this (so far)?

  • by clicking on the apple logo, menus and check boxes do not work on the first click

    Strange behavior from El Capitan OS X 10.11.1.

    When I click on the Apple Logo, menus, and check boxes, the action does not stick.

    To open the Apple Logo, the menu appears quickly but then folds upwards, as if I had not clicked.  Pretty well, click on the third, the menu opens.

    In the Finder, when I click on a menu like file, edit, or display, the menu appears, and then restores upward. Again, after three clicks in opens.

    In Safari, on a page Web, clicking on a checkbox does not stick. I need to click three times.  I when in Safari settings to clear the cache, I also checked the box to request the site "don't follow me." And even in the actual application of Safari, the box wouldn't fit.  I clicked it three times before the box stuck.

    Installation program:

    iMac 24 - early 2008

    4 GB

    El Capitan 10.11.1

    I changed the mouse, and this has solved the problem.

  • Keyboard shortcut tab does not work on the first cc pro trial version.  Is this normal?

    Downloaded a trial version of the first cc pro on my new iMac 5 k.  Don't really know why I've bothered I'll get the full package anyway.  Thought I run and pop in some "dailies" to another project, everything worked fine until I tried to customize the keyboard shortcuts.  I press the tab and nothing happens.  Is it because it is a trial version?

    Sorry for the slow response.  Recently, I've been up to my eyeballs in work! (not a bad thing).  Ronin thanks for your help.  I had a quick glance at this link, and there are some useful things there.

    It turns out that I solved the problem otherwise.  All I had to do was clear my settings synchronized and then re-sync! can you believe that!  Now when I select shortcuts keyboard in the window menu opens and I can customize it further.  Before, nothing happened when I chose keyboard shortcuts in menu drop down!

    Maybe it's a weird solo bug that only happened to me, I hope that no one else suffers this infuriating thing!

    See you soon

  • Firefox does not start at the first click

    Whenever I try to open Firefox by simply double click on it, it won't work. Open I double click on it several times. I get always a few Firefox Windows, but not the exact amount as well as the time I double clicked on it. Help please.

    Hello

    Your Firefox profile may have a problem that prevents Firefox from opening too quickly that it is seized.

    The reset Firefox feature can solve a lot of problems in restaurant Firefox to its State default factory while saving your bookmarks, history, passwords, cookies and other essential information.

    Note: After Firefox reset, you will lose all extensions, toolbar customizations, and certain preferences. See article Firefox Refresh - reset modules and parameters for more information.

    To reset Firefox:

    1. Open the troubleshooting information page using one of the following methods:

      • Click the menu button

        click Help

        and select troubleshooting information. Should open a new tab containing your troubleshooting information.

      • If you are unable to access the Help menu, type Subject: support in your address bar to bring up the troubleshooting information page.
    2. At the top right of the page, you should see a button that says "Reset Firefox" which looks like this:

      . Click on it.

    3. Firefox will close and reset. After it's done, Firefox will display a window with information that is imported.
    4. Click Finish and reopen Firefox.

    This corrects the problem? Please report to us!

    Thank you.

  • Atomos Shogun 4 K video does not work with the first

    Hi guys,.
    I bought the new Atomos Shogun. It works fine with my Sony A7s, but I can´t matter first Clips I did with her.
    A I made a mistake, or is it just a firmware issue?

    Thank you

    What first version are you on? If it is an earlier version, you may have installed Quicktime.

  • "back" button does not work and the home page does not display on startup

    My buttons next and previous no longer work. They show just gray and I cannot click on them.
    Also my home page does not appear when I launch firefox.
    I reinstalled firefox 4 and then I went back to firefox 3.6.16 and have the same problem in both versions.
    Don't know what to do anymore
    I just found out that when I opened a second window everything works well in the second window, but it still does not work in the first window.
    The same thing happens when I close both windows. The first window of my home page does not appear and the back button does not work, but the second window is operating normally. Including my home page.

    Try:

    Start Firefox in Firefox to solve the issues in Safe Mode to check if one of the Add-ons is the cause of the problem (switch to the DEFAULT theme: Tools > Modules > appearance/themes).

    • Makes no changes on the start safe mode window.

    See:

  • loads of YouTube but then when I click on a video it doesent play. It worked fine the other day and it does not work in the past and suddenly. Help, please!

    loads of YouTube but then when I click on a video it doesent play. It worked fine the other day and it does not work in the past and suddenly. Help, please!

    Clear the cache and cookies from sites that cause problems.

    "Clear the Cache":

    • Tools > Options > advanced > network > storage (Cache) offline: 'clear now '.

    'Delete Cookies' sites causing problems:

    • Tools > Options > privacy > Cookies: "show the Cookies".

    Start Firefox in Firefox to solve the issues in Safe Mode to check if one of the extensions or if hardware acceleration is the cause of the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > appearance/themes).

  • My Readyboost does not work. When I click on dedicate to Readyboost, it gives me an error: failed to create the cache.

    ReadyBoost - Cache problem!

    My Readyboost does not work.  When I click on dedicate to Readyboost, it gives me an error: failed to create the cache.  The process cannot access the file because it is being used by another process.  Help!

    Hello

    Did you change your computer?

    (a) click on the 'Start' button, then click on 'computer '.

    (b) right click on the USB drive or flash memory card that uses Windows Ready Boost, then click 'properties '.

    (c) click on the tab "Ready Boost" in the 'Properties' window to the memory card or the USB drive.

    (d) select the title radio button "do not use this device ' then click on 'OK '. This step should remove automatically the Ready Boost cache on the device. If you are unable to use the full capacity of the device, proceed to the next step.

    (e) double-click the memory card or the USB drive.

    (f) right click on the file 'ReadyBoost.sfcache' and then click 'remove '.

    (g) click 'Yes' to remove the ReadyBoost cache.

    Reconnect the device ready boost which allows the service to boost loan which will create the new cache.

    I suggest you to follow the links and check out them.

    Check your hard drive for errors

    http://Windows.Microsoft.com/en-us/Windows-Vista/check-your-hard-disk-for-errors

    Turn ReadyBoost on or off for a storage device

    http://Windows.Microsoft.com/en-us/Windows7/turn-ReadyBoost-on-or-off-for-a-storage-device

    Using memory in your storage device to speed up your computer

    http://Windows.Microsoft.com/en-us/Windows7/using-memory-in-your-storage-device-to-speed-up-your-computer

  • Brush control with CTRL + ALT + click right + mouse/pen movement does not work with the tool liquify (photoshop cc 2015): what should I do?

    Brush control with CTRL + ALT + click right + mouse/pen movement does not work with the tool of liquefy; I can't change the size of the brush or hardness. OS win 7 Professional 64 bit, wacom tablet intuos 6.3.14 - 1 driver s pro, Photoshop 2015 CC worm.  2015.0.1 20150722.r.168

    What are your settings of GPU acceleration?  As I understand it, the Alt right click size and hardness adjust needs acceleration GPU to be turned on, but I have a feeling Brush hardness is always set to easy when using fluidity.  You can still see the quick mask as representation of the soft brush when Alt right click, but you can't change the hardness.

    Is that you can change the brush size and pressure (framed in red in my screenshot) Alt right click drag left and right changes size and down to pressure changes, and you can see what is happening in real-time by looking at the sign on the right.  It works independently of your acceleration GPU (IME) settings, but you don't get the effect of soft red quick mask.

    Does this fit with what you see, or you are not able to change things at all?  If not, then I've always found that fluidity consumes system resources, if you could check the Task Manager > Performance tab to see what kind of RAM and CPU use is using the fluidity.  That's what I see after direction the lens above with a big brush continuously for 10 seconds.  Note This is on a fairly quick NLE System.

  • FRM-10142 the http listener does not work on the name of the computer to the port 80

    Hello

    During the race, the oracle 12 c form a following error message

    FRM-10142 the http listener does not work on the name of the computer to port 80. Please start the receiver or check your preferences of runtime.

    Sandy

    First, you will need to check the SST is running.

    go to admin server url in your browser, click on the target icon that is left top of your admin home go to the http server and then start your ohs1.

    and open your generator of forms go to the updated runtime default url like e.g. OSH, you can find your url such as http://localhost:7777 or http://localhost:7779.

    your full url looks like this format http://localhost:7777/forms/frmservlet or http://localhost:7779/forms/frmservlet.

    Localhost can be your default ip 127.0.0.1 or any static ip 192.0.0.10 address in this format.

Maybe you are looking for

  • AppleScript/Pages can not find the open document

    This very simple script will not work: Tell application "Pages". activate say the document before name tell the end tell the end All of this has to do is give the name of the opened document. It says: "cannot get document 1. Invalid index. "And, Yes,

  • Create log of three screws - sometimes the data are missing

    Hello I have three screws measure in parallel in a loop Three results are saved permanently to the global network and also in a text file. The berries-global has always all the data, but in the text file is missing some data. I think it is because th

  • Bluetooth missing in Control Panel devices

    Originaltitle: Control Panel / Printers and other devices I have not see a bluetooth option?I'm trying to solve a computer problem, and it might be my bluetooth mouse.  When I go to control panel of configuration/Printers and other devices, I don't s

  • Unable to forward Port 5900

    Hi, I think I tried everything I could think to forward port 5900 with no luck. I have e4200. This is for the purposes of RealVNC. I followed the steps from here: http://PortForward.com/English/routers/port_forwarding/Cisco/Linksys-E4200/RealVNC.htm

  • How to block a number in M4 aqua?

    Someone working for calling and texting me messages very unlikely. I want to block his phone number. How in M4 aqua? Thank you