Simple button does not?

I was looking at this code for an hour. Maybe I need a break? It is a very simple button that does not accept my touch events.

I have a clip. Its instance name is "boardA." The name of the symbol is "letterA" and it is linked to a class file called 'Letters' (which is connected correctly, I checked).


This is the code in the class file:

public void Letters() {}
this.addEventListener (TouchEvent.TOUCH_BEGIN, createLetter);
trace (this.letter);
}

public void createLetter(e:TouchEvent): void {}
trace ("you clicked on it!");
trace ("eName =" + e.target.letter);
}

Yet, nothing happens when I click on the button. The constructor for the file never runs.

I moved even the touch event to bed "(TouchEvent.TOUCH_BEGIN, createLetter) boardA.addEventListener ' and it still doesn't work. Nothing when I hit the button.

What I'm missing here?


Thank you
Amber

I see letters is the base class for the letter,... etc.

the package of letters and the location of Letters.as must be the same.

Tags: Adobe Animate

Similar Questions

  • Simple button does not properly?

    The button works correctly, but for some reason when I run the flash page, the button looks with the alpha to 50%. I reduced to var elasticTween3:Tween = new Tween (my_box, "alpha", Strong.easeOut, 0.5, 1, 1, true);  line of code, but I need this line to fade the alpha of 50% to 100% when the mouse over occurs. Am I missing something?

    Here is my code:

    Import fl.transitions.Tween;

    Fl.transitions.easing import. *;

    Import fl.transitions.TweenEvent;

    import flash.events.MouseEvent;

    var myTween:Tween = new Tween (my_box, "alpha", Strong.easeOut, 1, 0.5, 1, true);

    myTween.stop ();

    var elasticTween1:Tween = new Tween (my_box, "x", Elastic.easeOut, 35, 45, 1.5, true);

    var elasticTween2:Tween = new Tween (my_box, "x", Elastic.easeOut, 45, 35, 1.5, true);

    elasticTween1.stop ();

    elasticTween2.stop ();

    my_btn.addEventListener (MouseEvent.MOUSE_OVER, hover);

    function hover (e:MouseEvent) {}

    myTween.start ();

    elasticTween1.start ();

    elasticTween2.start ();

    }

    var elasticTween3:Tween = new Tween (my_box, "alpha", Strong.easeOut, 0.5, 1, 1, true);

    elasticTween3.stop ();

    my_btn.addEventListener (MouseEvent.MOUSE_OUT, out);

    function on {(e:MouseEvent)}

    elasticTween3.start ();

    elasticTween1.start ();

    elasticTween2.start ();

    }

    Make sure that the code runs only once.  That is to say, this image should not be reinstated.  Use the trace() function to confirm, if you think that you have prevented the re-entry.

    :

    Import fl.transitions.Tween;

    Fl.transitions.easing import. *;

    Import fl.transitions.TweenEvent;

    import flash.events.MouseEvent;

    var myTween:Tween = new Tween (my_box, "alpha", Strong.easeOut, 1, 0.5, 1, true);

    myTween.stop ();

    var elasticTween1:Tween = new Tween (my_box, "x", Elastic.easeOut, 35, 45, 1.5, true);

    var elasticTween2:Tween = new Tween (my_box, "x", Elastic.easeOut, 45, 35, 1.5, true);

    elasticTween1.stop ();

    elasticTween2.stop ();

    my_btn.addEventListener (MouseEvent.MOUSE_OVER, hover);

    function hover (e:MouseEvent) {}

    myTween.start ();

    elasticTween1.start ();

    elasticTween2.start ();

    }

    var elasticTween3:Tween = new Tween (my_box, "alpha", Strong.easeOut, 0.5, 1, 1, true);

    elasticTween3.stop ();

    my_btn.addEventListener (MouseEvent.MOUSE_OUT, out);

    function on {(e:MouseEvent)}

    elasticTween3.start ();

    elasticTween1.start ();

    elasticTween2.start ();

    }

  • Equium L300 - 17Q - "Enter" button does not

    As read you on the title my TOSHIBA EQUIUM L300 - 17Q enter button does not.

    screen-on the built-in keyboard works is that all the other keys work.
    I have reinstalled the keyboard from the device manager driver, then perform full system recovery and still does not.

    Hello

    It looks like a malfunction of the simple keyboard in this case, you will need to replace the internal keyboard. Otherwise, you can use the USB keyboard

  • Laptop computer HP mouse left button does not

    I'm not a computer person, so I apologize in advance if I get words wrong. Information about the specifications are the HP Support Assistant.

    I have a HP Pavilion laptop G6 (product number A4A93UA #ABA)

    I am running Windows 7 (64-bit)

    My microprocessor (if it's important) is an Intel (r) Core i5 - 2430 M CPU @2. 40 GHz

    I have 4 GB of system memory

    The pointing device is Synaptics PS/2 Port TouchPad

    I hope that I didn't miss something important.

    I'm having some problems, mainly the left button of the mouse does not work. I searched and searched for an answer, but I can't seem to find a. The touchpad itself works perfectly. I can double-tap to click, press on and drag the highlight, etc.. The right button of the mouse works fine as well. It brings up a menu each time as it is supposed to. The left button on the other hand, does not at all. I had the computer for about 6 months, so my warranty is still in tact. I was hoping just to find a simple solution, before passing through the process of return to HP or Best Buy.

    At first, the left button seemed to lag. It works sometimes and not others. Then it stopped completely (all within a period of a few days), what happened a month ago. Since then, I was looking for answers and dealing with just. even if it is super boring!

    Another thing I noticed is around the time that the mouse itself has stopped working, my Start menu was allowed out entirely. When I searched the HP Support Assistant, he didn't. I had to go through the program files for access. Nothing is displayed in the start - menu it is empty with the exception of Norton, Internet Explorer, Google Chrome and the menu accessories (but inside she, notebook, Run and command prompt, are the only things that appear.

    So overall - my Start menu is almost empty, and my left mouse button does not work.

    I tried to install the new drivers, but no luck.

    I mean it's a hardware problem, but the thing on the part of the menus disappearing makes me wonder if it's a virus. I would try a Windows CD as Hiren PXE environment and see if the mouse works with different software. But it's a longshot and the likely answer is that the mouse circuit is bad. The only other thing you could try is a factory restore.

  • The ARC mouse left button does not properly

    The other day, I bought a mouse Arc.  My right button works fine, but my left button does not respond unless I have push down hard and hold the button for one second.   Simple click, it translates the button press then to click but nothing happens.  I guess it's just a bad mouse and not a systematic design problem?

    * original title - Arc 'hard click' buttons *.

    Hello

    · Do you remember the latest changes on the computer before the show?

    · What is the service pack installed?

    Try the steps listed in the link below: troubleshooting failures in the response to the mouse or wireless keyboard: http://support.microsoft.com/kb/838398

  • Factory settings Resinstalling when blue Thinkvantage button does not work

    Last year, I panicked when I thought I had a virus. Rather than rely on my own multiple back-up system, I guess someone knew more about computers that I do and let someone else in my computer. My X 60 has not worked properly since. The Thinkvantage button does not work, and it is hit and Miss as to if I can get the thinkvantage functions to work. My wireless radio buttons don't work at all, and the indicator wireless lights turn on and turns off at will.

    I tried to reinstall the application and the update of all implement the Lenovo site, but nothing worked, so I think I'll have to reinstall the orginal factory settings and start over again to clarify these issues.

    I backed up all my data, and made discs (just in case) recovery... now my question is, how do I start to "rescue and recovery" / 'reinstall factory settings' when the blue button does nothing when I push at the start?

    (Works under XP - if that makes a difference).

    Thank you

    Problem solved.

    I managed to get into Rescue and Recovery manually and found that I had a backup on my C drive that existed prior to my problems. I just restore to that date and "presto!" the blue button works again!

    I'll have to spend the rest of the day, re-installing everything that has been added or upgraded from a year, but this simple step seems to have solved my problem. Who would have thought that I had a copy of backup to disk C - I thought I backed everything up to an external drive!

    Tip for any staff of Lenovo, reading this - if your security people knew more about Thinkvantage program, I could have solved this problem months ago - these are them who sent offshore to find updates to day and re - install Thinkvantage to try to get the blue button works again.

    Thank you all.

  • iPhone 5 home button does not work after ios 10

    My 5 Iphone Home button does not work after update final IOS version of 10.

    The home button works on the first push to wake the phone but it will not open the phone the second button.

    I activated the assist button, which does not work either. But what I discover is if I open device for assistance then touch and lock screen click on the button home will work once to open the phone. If I open any app I can't close it unless I go through the same routine.

    You attempted to restart your phone?

    You can do so by holding the sleep/wake button and the Home button simultaneously until the Apple logo appears

  • I'm locked out of my iphone5 not connected to my wifi at home and my home button does not work, any ideas on how to fix?

    I'm locked out of my iphone5 not connected to my wifi at home and my home button does not work, any ideas on how to fix?

    < re-titled by host >

    Take it to an Apple Store for repair or replacement.

  • My mute button does not work

    The button does not work everytime I try to put my phone on silent. I turn it down and it will automatically return to the sound, it activates again upward. What can I do?

    Hello Jackie101foever,

    Thank you for using communities Support from Apple!

    As I understand it, you can't silence your iPhone.  I have a suggestion that should help you with this.

    The first thing we want to do is to make sure that you have a current backup of everything on your iPhone.  If you follow this link, you will find instructions on how to make a backup:

    The backup of your iPhone, iPad and iPod touch

    If the silent button moves upward on its own, so you must do this checked by a service representative.  You can find the nearest one by looking here:

    Find locations

    If the button is stay down, but do not silence the iPhone then we want to restore all settings.

    Reset preference files resets all parameters that may be problems. This step will not delete your contacts, photos or personal information. It deletes all your preferences for Wi - Fi, Bluetooth, do not disturb, Notifications, general, sounds, brightness & wallpaper and privacy and removes your Touch ID & password.

    Do you this by clicking on settings > general > reset > reset all settings.

    Once you have done this, restart the iPhone and see if you are able to turn off the sound.

    Have a great day!

  • iPhone6 the wifi button does not illuminate.  I want to download the new update.  I restarted the phone, my router is active.

    iPhone 6 with iOS9.3.4.

    WiFi button does not illuminate.  I rebooted the phone.  How can I make this button of the device?

    You can always update your firmware with iTunes. But it seems you might have a larger, likely hardware problem with your phone.

    Try to restore the firmware with iTunes. If this does not help, make an appointment with a genius at the Apple Store.

  • By pressing the home button does not take me to the home screen of iOS 9.3.3

    I have recenly updated upgraded to iOS 9.3.3 and I noticed that pressing the home button does not take me to the home screen. The only way to get there is by using the creature of multitasking. (double pressing the home button) Also, some applications seem to freeze if turn my phone off and then turn it back on, or when I access it via the multitasking function. Can someone please help?

    Try a forced reboot. Hold down the Home and Sleep/Wake buttons at the same time for about 15 seconds, until the Apple logo appears. You won't lose anything.

    If a force restart does not help, try a system restore. First save your device via iTunes. Also import your photos on your computer and copy all the important data. Reconstruction of the support first test and test. If this does not help, you may need to restore as a new and reconfigure from scratch as the backup may be damaged. It is important to have your photos and your saved data separately from the backup. Here are the steps for a restoration:

    https://support.Apple.com/en-us/HT201252

  • When I return from the page of google search for a link then button does not return return

    When I return from the page of google search for a link, then button does not return back. Instead, the same page refills. I need to go back click back button twice or even more. How to fix? I cheked it it another browser and there is no such behavior. It seems completele Firefox problem.

    the problem was resolved after remooving extenshion «user agent overrider»

  • Hello Firefox button does not appear.

    Hello, Firefox has been added in Firefox Beta 34.0. However, the Firefox Hello button does not appear in either Firefox, or using the Customize menu. Am I missing something or is this only available for select people?

    In the window customize, you can click on "restore default settings". You will then need to configure things again if you use no default provision.

    Bug 1083525 - Hello button does not appear in the palette so personal before FFx34

    Bugzilla is not a forum, so please do not comment in bug unless it is something useful such as patches, cause or difficulty as 'Me too' comments are spam email/bug.

  • "Back" button does not work and lost bookmarks

    I followed the instructions that Firefox has been extremely slow. He said my favorites would be saved and everything should work as usual. However, I lost all my precious Favorites, and now the back button does not work. She is pale grey all the time, and itls drives me crazy, that I can't go back to the search page. I have to type everything in full again.
    If I can't change it, I'll have to switch to another web browser, after being with Firefox for more years than I care to remember.
    I liked using Firefox and have recommended it to all my family and friends.
    I'm very angry on my favorites, because I used these regularly and had a few coordinates links and important model for my sewing and knitting, as well as time-saving links. Now, I'm completely lost without them.
    If this isn't the page said it would be saved, then I would not have changed anything.
    It's very frustrating and annoying, after spending months, where I wanted and now he lost get it all because of the wrong information. I am very anxious.
    Lesley

    You can check for problems with the database places.sqlite file in the Firefox profile folder.

    You can see if you can restore bookmarks to a JSON or a compressed backup of JSONLZ4 in the bookmarkbackups folder in the "Old data Firefox" folder on the desktop.

  • the 'Clear now' button does not not on web content caching

    I clicked on tools > option > advanced > caching of content, then clicked on the "Clear now" button > ok, nothing has shown that if the button does not work and there was no clear action.

    This button to clear the cache is probably broken because the current version of Firefox 32 has switched to a new service named Cache2 cache.

    This change will result in extensions that use the old cache service to stop working and its developer must update the extension.
    You can see the site of Add-ons to see if there is already a version available that maybe is not approved yet.

Maybe you are looking for