How to make a button stop working?

I have a button that I want to only operate when certain conditions are met, and if not, then this button does not work.

I have this on the timeline:

homeMC.gotoSleep_butt.addEventListener (MouseEvent.CLICK, toSleep);

function toSleep(evt:MouseEvent):void
{
dayChange_MC.gotoAndStop("1");
day += 1; Add 1 day var
stat_day. Text = String (day);
}

And I want it to be:

If

dayChange_Mc is the frame 5 then gotoSleep_butt will not work

on the other

dayChange_MC.gotoAndStop("1");
day += 1; Add 1 day var
stat_day. Text = String (day);

So, how can I write above the part in the FI as actionscript 3?

{if(dayChange_Mc.currentFrame==5)}

homeMC.gotoSleepButt.enabled = false;

should fade, too

} else {}

dayChange_MC.gotoAndStop (1);
day += 1; Add 1 day var
stat_day. Text = String (day);

enbalbe your button?

}

Tags: Adobe Animate

Similar Questions

  • ThinkPad Bluetooth Laser Mouse buttons stop working

    My ThinkPad Bluetooth Laser Mouse is a great device, except that very often the buttons stop working; for example, I can click the close X at the top right of a window and nothing happens. I found that cross all possible button clicks, including failover of the scroll wheel, will get running again. My assessment is that the software Lenovo mouse Suite merges very often on the State of the mouse buttons; for example, software problem, not a hardware problem. Frequency is approximately 1 event in 20 hours of use. What must I do to get help?

    Windows 7 x 64 with all updates

    ThinkPad X 220 with built-in Bluetooth

    Mouse Suite Lenovo: 6.47 (upgrade to 6,48)

    UPDATE: just had to happen once again (still ongoing: 6,47). I tried a lot of things with the mouse and the only thing that solved the problem was to tilt the mouse wheel (first to the left then to the right).

    UPDATE: I recently had the left and right tilt scroll wheel assigned to respectively backward and forward, and I don't remember having this problem before I did these assignments, so I changed both of these assignments to disabled to see if that makes a difference. I've also updated the Mouse Suite version 6.48 software.

    For further investigation:

    100% reproducible failure

    When I opened Firefox 11.0 with only one tab, the window control icons (Minimize, Maximize, Close) would correctly highlight on mouseover and works correctly when you click on it. When I then open or switch to another tab, there was no highlight on mouseover and is no longer, they responded to clicks. Other actions of the mouse work properly, including the icons of window control in other apps I tested.

    I uninstalled then reinstalled Firefox 11.0, define a new profile is empty, and the problem persisted. I checked for other reports of this problem in Firefox, and while I found a (very) few similar reports, I found that there was no evidence a general problem in Firefox.

    Successful correction

    I uninstalled ThinkPad Bluetooth Laser Mouse, mouse, Lenovo, ThinkPad UltraNav Utility, ThinkPad UltraNav Driver and rebooted, installed just the TrackPoint with the Microsoft Compatible PS/2 driver, and the problem does not recur. I think only installed two UltraNav packages with system update, then the Lenovo ThinkPad Bluetooth Laser Mouse with mouse Suite, and the problem still does not happen. It continues to operate correctly.

    My assessment

    My assessment is that something subtle had screwed up in Lenovo UltraNav and/or mouse Suite, which has been fixed by uninstalling and then reinstalling everything. I don't think that there is a problem in Firefox.

  • How to make interactive buttons to rollover?

    How to make interactive buttons to rollover?

    Hello

    I think that you are looking to create a button that changes on the mouseover? for this, you can define States of button for each mouse, such as normal action, working capital etc.

    This video explains the steps:

    http://TV.Adobe.com/watch/Muse-feature-tour/Muse-define-object-States/

    Please let me know if I'm missing something.

    Thank you

    Sanjit

  • How to make animated gifs to work in FCPX?

    Hello

    How to make animated gifs to work in FCPX?

    They work in FCP7 (FCS) but not FCPX. Strange.

    assailed

    Elmer

    If you had FCP7, you have Quicktime 7 Pro (upgraded automatically at installation FCP7). Check your Applications > Utilities folder.

    Open the gif in QT7 and export as... (Sequence Quicktime Movie > Open Options)... might as well go with ProRes LT and make sure that you pay attention to the size option (select current if the original is 100%).

  • new tab button stop working

    Since yesterday the new tab button stop working. I tried clicking on the + as usual but nothing happens. It lights up blue when I click but nothing else. So, I tried via file, new tab but also Ctrl + t.
    I tried to restart and update too.

    The Ask toolbar is originally only in versions of Firefox 3.6.13 +. Uninstall this extension.

    There are a few places to check for the Ask toolbar:

  • Satellite A300 - 15K - 2 media buttons stopped working

    Hello.

    I have a problem, the first 2 of my multimedia buttons stopped working...
    I tried to uninstall several times but it didn't help.

    I also have nothing to choose in the list in

    Toshiba Assist-> optimize-> Toshiba Button Support.

    I need help. (there were 2 posts before).

    Hello guys

    Can you please stop crying here, and perhaps tell us what the problem is here?

    Expensive J3... what you are writing about. What operating system do you use? What drivers? What kind of error?
    Multimedia keys are not controlled by drivers. What is - that you already tried?

    Hay metalbullet, the same questions for you - what order, what OS? Sorry, but you didn't offer any relevant information.

    Have you tried with this VAP suggested by Akuma?

  • How to make the button to set the properties of auto-scale one of the Axes on the graphical indicator so I can turn on or off when I press on it. In the Labview web UI designer

    How to make the button to set the properties of auto-scale one of the Axes on the graphical indicator so I can turn on or off when I press on it.

    I need to change the adjustment vaguely Autoscale property for my graphic indicator. Can someone help me please.

    Thank you!

    Hello

    I have confirmed that there is currently no way programmatically enable/disable autoscaling for axes on the LabVIEW graphical indicator generator of the user Web interface. We noted this to possibly be implemented in the future; Sorry for the inconvenience.

  • Family Tree Maker 2012 has stopped working

    We are have installed Family Tree Maker 2012 and have difficulties to enter.  We have been in contact with FTM people several times and have not been able to solve the problem.

    Is the first message we receive and exclamation mark inside a yellow triangle:
    Family Tree Maker 2012 is not properly closed the last time it was used.  You may need to compact your last open file to solve the problems caused by an abnormal termination.  To compact the file, choose 'compact the file... ". "in the Tools menu.   (We went in each file we could find and compacted them and made sure they were closed).

    We click on 'OK' and Family Tree Maker partially opens, then closes.  A Microsoft Windows box appears and says "Family Tree Maker 2012 has stopped working.  A problem caused the blocking of the program works correctly.  Windows will close the program and notify you if a solution is available. »

    "Interestingly, before trying to install FTM 2012 we asked problems with Windows Explorer, message pop up saying Windows Explorer has stopped working" or "Windows Explorer restarts" when we try to open, delete, or rename an attachment that arrived by e-mail.  The attachment opens the first time and recorded with an AOL icon (we have AOL accounts), but the only option that we can do then is to drag the attachment into the trash.

    Where can I find information to shoot evil in Windows Explorer?  or is there a way we can reload the program to fix the problem?  He said that our system is up to date on updates of Windows, so don't know what to try next.

    Hello
    Try this link:
    http://technet.microsoft.com/en-us/library/cc709691 (WS.10) .aspx
    b Eddie

  • How to make a button to Flash a PagSeguro https page.

    How to make a button to Flash a PagSeguro https page. Programming they offer is:

    <! - FORMULARIO ALEXANDER PAGSEGURO INICIO - >

    " < target form = 'pagseguro' action = ' https://pagseguro.uol.com.br/checkout/v2/cart.html?action=Add "method ="post"> "

    <! - NAO EDITE OS COMANDOS DAS LINHAS ABAIXO - >

    < input type = "hidden" name = "itemCode" value = "AC0DD53E5757C9F774629F9937513499" / >

    " < input type ="image"src =" https://p.SIMG.uol.com.br/out/pagseguro/i/botoes/Pagamentos/120x53-comprar.gif "name ="submit"alt =" pay com PagSeguro - rapido e, grátis e seguro! » / >

    < / make >

    <! - FINAL FORM ALEXANDER PAGSEGURO - >

    So I spent this programming in HTML start, I see the white border in my page.

    I wrote a book and this schedule must send to a site secure for sale

    I'm developing my site in Flash 4 and now nc6. Export to Html

    www.escalasdecores.com.br

    Use the urlloader class:

    var urlLoader:URLLoader = new URLLoader();

    var urlRequest:URLRequest = new URLRequest ("https://pagseguro.uol.com.br/checkout/v2/cart.html?action=add");

    var urlVariables:URLVariables = new URLVariables();

    urlVariables.itemCode = "AC0DD53E5757C9F774629F9937513499";

    urlRequest.data = urlVariables;

    urlRequest.method = URLRequestMethod.POST

    urlLoader.dataFormat = pouvez;

    urlLoader.load (urlRequest);

  • How to make the buttons doesn't work in every scene?

    Hello

    I created four separate buttons (actionscript3) and I coded each button so when one is active, it climbs to a different scene. The four buttons are present on all the stages (I copy - paste all the buttons of the original scene at each additional stage) so I was hoping that, whatever the stage, the user can click on each button to operate. Each button works on the first click (the first stage), but the question is when that one is turned on and the buttons, it climbs to a new scene is no longer are clickable (roll over the State remains functional, but none of them work to be clickable to access another scene). I copy / paste my code used below, I hope this question makes sense, I want to just that my buttons to work independently of the scene. Thank you!

    Here are the codes that I used, I placed it on the first frame of the first scene:

    tulip_btn.addEventListener (MouseEvent.CLICK, onClick);

    function onClick(e:MouseEvent) {}

    gotoAndPlay (1, "scene 2");

    }

    rose_btn.addEventListener (MouseEvent.CLICK, onCami);

    function onCami(e:MouseEvent) {}

    gotoAndPlay (1, "scene 4");

    }

    lily_btn.addEventListener (MouseEvent.Click, onLily);

    function onLily(e:MouseEvent) {}

    gotoAndPlay (1, "scene 5");

    }

    poppy_btn.addEventListener (MouseEvent.CLICK, onPoppy);

    function onPoppy(e:MouseEvent) {}

    gotoAndPlay (1, "scene 6");

    }

    When you go to another scene, it's as if it's a new button, which does not have the mouse listener. If you were using a movieclip instead of a button, you can place the script inside the movieclip. It would be wise add the listener when the movieclip is added to the scene and remove the listener when it is removed.

    There is a different way, you may work well. You can name your buttons and the same scenes. Then, in the intro scene, you could have a script like this:

    import flash.events.MouseEvent;

    Stop();

    stage.addEventListener (MouseEvent.CLICK, clicked);

    function clicked (e:MouseEvent) {}

    gotoAndPlay(1,e.target.name);

    }

    Now you can copy the four buttons, which might be called rose, Lily, Tulip, poppy, and clicking on any one of them would you bring to the scene with the same name.

  • The USB headset volume buttons stopped working

    Let's see if a second go make me somewhere...

    I have the Travelite ASUS HS-1000w headset. It is compatible with all versions of Windows. I got this headset special for about two weeks before the volume buttons stopped to change the volume.

    It is plug-and-play 'driver for free', so there is no update driver for him - I checked. It is always set as the default audio device to use when it is plugged. I don't have any Intelli-products (IntelliType, IntelliPoint; someone has suggested that there could be a conflict).

    It worked with no problems whatsoever until one day, I restarted my laptop and ONLY stopped volume keys their functions for an unknown reason. It is not the USB port; change ports makes no difference. It is not the helmet; the buttons work when tested with other computers, PC and Mac. Nothing has been installed during the session before rebooting, not even the updates of Windows.

    Still the volume buttons still don't move the volume slider. I have tried everything I can think of, including uninstalling the driver/restart/connect the headphones back in and let him make his case. My last stations are making a Win7 repair install and if this does not work, reinstall Win7 entirely. But, as we can guess, I don't want to have to basically EVERYTHING (200 + concerts) reinstall on my computer just to get one thing working again which, at this rate and based on past with her, events cannot be guaranteed to stay work again for much longer after that.

    What REALLY bothers me is that seems to be the only person on the planet who is having that kind of question.

    How can I get these buttons work again if it's something on my computer that affects their? If anyone has any clue that could help me somehow, I'll give you $ 1 billion.

    (Well, not really, but darnit, I'm DESPERATE!)

    Hi Tyberious,

    Please see the post below with a similar problem:

    http://VIP.ASUS.com/Forum/view.aspx?board_id=21&model=HS-1000W&ID=20100306223646109&page=1&SLanguage=en-us

    I hope this helps!

    Debra
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think

  • Toshiba control buttons stopped working on Satellite

    "turn off the lights" and "windows media player" media buttons no longer work...
    They did a couple of days. Not sure why they stopped working.

    When I open media player manually, the * play/pause, stop, previous / next buttons * work, just the * LEDs power switch * and * media player * buttons don't.
    If anyone has had the same problem or knows how to solve this problem, would be very grateful if you could let me know...

    Thank you!!!

    Hello

    > If anyone has had the same problem or knows how to solve this problem, would be very grateful if you could let me know...
    Why you n t search in the forum for questions and similar problems?
    There are a lot of threads!

    Just a tip; you need to reinstall VAP

  • Control buttons stopped working

    Hi all

    This is not an important thing, just a pain in the ass and when something is supposed to work I love it to!

    Anyway, the four buttons on the left of the keyboard - internet, Media Player, stop, play etc have stopped working for some reason any.

    Any ideas?

    Thank you

    Liam

    Hello Liam

    Always cela for some reason comments. ;)
    First try to make back the OS to an earlier time using System Restore tool. Maybe solves this problem on an easier and faster way.

    Good luck!

  • create dvd windows movie maker and Windows stopped working

    I've never had a problem with the creation of dvd windows or windows movie maker, but all of a sudden, the two do not work. In windows, creating DVDs when I add items to the dvd maker screen becomes transparent and stops working and I get an error message saying that windows dvd maker has stopped working, windows will notify if a solution is available, etc.. Same thing with windows movie maker. I have already registered the module 'iac25_32.ax' and I installed windows vista service pack 2, but it did not help. Here are the details of the problem:

    Creating Windows dvd;

    Problem event name: APPCRASH

    Application name: DVDMaker.exe

    Application version: 6.0.6002.18005

    Application timestamp: 49e02385

    Fault Module name: xvid.ax

    Fault Module Version: 0.0.0.0

    Timestamp of Module error: 3e86de1e

    Exception code: c0000094

    Exception offset: 0003dd11

    OS version: 6.0.6002.2.2.0.256.1

    Locale ID: 16393

    Additional information 1: fd00

    More information 2: ea6f5fe8924aaa756324d57f87834160

    Additional information 3: fd00

    Additional information 4: ea6f5fe8924aaa756324d57f87834160

    Bucket ID: 1294330809

    Director of Windows: -.

    Problem event name: APPCRASH

    Application name: MOVIEMK.exe

    Application version: 6.0.6002.18005

    Application timestamp: 49e0238f

    Fault Module name: xvid.ax

    Fault Module Version: 0.0.0.0

    Timestamp of Module error: 3e86de1e

    Exception code: c0000094

    Exception offset: 0003dd11

    OS version: 6.0.6002.2.2.0.256.1

    Locale ID: 16393

    Additional information 1: fd00

    More information 2: ea6f5fe8924aaa756324d57f87834160

    Additional information 3: fd00

    Additional information 4: ea6f5fe8924aaa756324d57f87834160

    I've never had a problem with the creation of dvd windows or windows movie maker, but all of a sudden, the two do not work. In windows, creating DVDs when I add items to the dvd maker screen becomes transparent and stops working and I get an error message saying that windows dvd maker has stopped working, windows will notify if a solution is available, etc.. Same thing with windows movie maker. I have already registered the module 'iac25_32.ax' and I installed windows vista service pack 2, but it did not help. Here are the details of the problem:

    Creating Windows dvd;

    Problem event name: APPCRASH

    Application name: DVDMaker.exe

    Application version: 6.0.6002.18005

    Application timestamp: 49e02385

    Fault Module name: xvid.ax

    Fault Module Version: 0.0.0.0

    Timestamp of Module error: 3e86de1e

    Exception code: c0000094

    Exception offset: 0003dd11

    OS version: 6.0.6002.2.2.0.256.1

    Locale ID: 16393

    Additional information 1: fd00

    More information 2: ea6f5fe8924aaa756324d57f87834160

    Additional information 3: fd00

    Additional information 4: ea6f5fe8924aaa756324d57f87834160

    Bucket ID: 1294330809

    Director of Windows: -.

    Problem event name: APPCRASH

    Application name: MOVIEMK.exe

    Application version: 6.0.6002.18005

    Application timestamp: 49e0238f

    Fault Module name: xvid.ax

    Fault Module Version: 0.0.0.0

    Timestamp of Module error: 3e86de1e

    Exception code: c0000094

    Exception offset: 0003dd11

    OS version: 6.0.6002.2.2.0.256.1

    Locale ID: 16393

    Additional information 1: fd00

    More information 2: ea6f5fe8924aaa756324d57f87834160

    Additional information 3: fd00

    Additional information 4: ea6f5fe8924aaa756324d57f87834160

    ==================================
    It looks like the xvid.ax filter might be the problem?

    Might be interesting to try to open Movie Maker and go to...
    Tools / Options / Compatibility tab and disable all the
    filters... or simply click on the button restore all default settings.

    The following links may be also worth a visit:

    DVD Maker has stopped working
    http://social.answers.Microsoft.com/forums/en-us/vistapictures/thread/edcb015f-9431-4d89-95e8-531db1f26c77

    Video filters in Windows DVD Maker: frequently asked questions
    http://Windows.Microsoft.com/en-us/Windows7/video-filters-in-Windows-DVD-Maker-frequently-asked-questions

    Windows Vista-
    Video filters in Windows Movie Maker:
    Frequently asked questions
    http://Windows.Microsoft.com/en-us/Windows-Vista/video-filters-in-Windows-Movie-Maker-frequently-asked-questions

    Volunteer - MS - MVP - Digital Media Experience J - Notice_This is not tech support_I'm volunteer - Solutions that work for me may not work for you - * proceed at your own risk *.

  • How to make the plugin that works in the background?

    Hi, I need to make the plugin working in parallel in the background thread. It should start when Photoshop starts and stops when closing Photoshop. I think that the plugin type should I choose is "Automation" but these plugins are executed only when the user calls the plugin in the menu. How to make the plugin that runs when photoshop works without the need to invoke it manually? I don't want this plugin to be visible in any menu. This plugin is designed to work with the extension of the CEP.

    I ended up making invisible CEP extension that performs background tasks in the timer event handler:
    CEP 5 Extension HTML Cookbook for CC 2014 · Adobe-CEP/CEP-resources Wiki · GitHub

Maybe you are looking for

  • order a "pulsed" LED

    Hello What would be the easiest way to put a LED on and off at a rate that is controlled by a button or something. Which means that I could either leave it turned off the coast or make impulse all three seconds, five seconds, etc.. ?

  • Recovery of a .dbx file

    The Inbox.dbx file used by Outlook Express is more than 2 GB (maximum) and I can't open it or read messages. I renamed and made the OE to create a new. If I try to open my old .dbx file, I get a message saying that another application is used. Google

  • No HELP with OE6 file dbx missing no bak file

    Hi hope someone can help! my computer is old w/decrease storage and OE inbox has suddenly lost most of the emails. I know the old routine in what concerns the use of the .bak folder in the trash, but I did not!  I see the huge dbx file, but I can't r

  • Cannot log on to Windows startup

    Well, this isn't me, it's my best friend, that she cannot connect to windows, she tries to enter his password which is to correct the cause that she was able to get into windows this morning. And now she goes and enters his password and it crashes ev

  • somebody needs to achieve good att.

    on windows xp, version House he needs to know that 2 of her office azul photo albums and rhododendrons are alittle disturbing if you stretch them, it doesn't take long and see youl, he leaves him surprised me, I think that the law should be aware of