Use Any key to activate a button

HI,
I was wondering if there is anyway to activate a button by
hitting any key?
Currently I have this code but it doesnt seem to work,
var keyListener:Object = new Object();
Key.addListener(keyListener);
keyListener.onKeyDown = function() {
processInput();
my_btn.onPress = processInput;
function processInput() {
gotoAndStop("Scene 2", 1);
Any help will be muchly appreciated

EDIT : IGNORE THIS POST
Ahh... so scene 2 is inside your button.... that explains it.
Its working... but what is happening is that inside your
processInput function your gotoAndStop is looking in different
timelines. You can see the difference in the traces between when
the keyListener calls it and when your button onPress handler calls
it.
I had assumed you wanted to move the button's parent timeline
on... but it was the button's timeline that you wanted to change.
(I just re-read your earlier post - you did say that but I missed
it, sorry)
try changing this:
keyListener.onKeyDown = function() {
processInput();
to this:
keyListener.onKeyDown = function() {
my_btn.onPress();
and you can get rid of the timeline variable.
inside processInput:
make it :
this.gotoAndStop("Scene 2", 1)

Similar Messages

  • I purchased lightroom5 but i didn't get any key to activate it

    adobe did not send me any key to activate my lightroom5

    In the meantime, you can download the trial version of Lightroom 5.6 and install it. You will be able to use it for 30 days. Then, when the serial number arrives, you can activate the trial version with that serial number without having to reinstall anything. And you will have full use of Lightroom during that 30 day trial. However, this assumes that you haven't been using the trial version up until now. If you have already used up your 30 day trial, then you will just have to wait for the serial number.
    I'm quite surprised that it is taking so long to receive the number. When I activated my academic version I received the serial number within about 5 min.

  • How to use enter key instead of save button in tabular form?

    Hello,
    is there a way to save data entered into a tabular form by clicken enter instead of "submit/save" button?
    We got it working for normal forms but not for tab. forms
    Regards
    Friedrich

    Hi Friedrich,
    try to enter
    onkeypress="return submitEnter(this,event)"into "Element Attributes" of your tabular form column.
    If you hit enter, the page will be submitted with request set to the id of the tabular form column.
    Regards
    Patrick
    My Blog: http://www.inside-oracle-apex.com
    APEX 4.0 Plug-Ins: http://apex.oracle.com/plugins

  • Using the keyboard to activate a button

    Say I have a JTextfield and a JButton. I want the Enter key to do the same thing as clicking on the JButton. I thought there might be a way to do it by having the JTextfield watch for "/n", but I couldn't figure it out. I searched ActionEvent in the documentation, and I didn't find much help there either.

    Hmm... JTextField supports ActionListeners, the same as a JButton, so if you register an ActionListener with the field, hitting enter is supposed to fire an ActionEvent.
    ActionListener al = new ActionListener() {
    public void actionPerformed(ActionEvent ae) {
    System.out.println(ae.getSource());
    JTextField tf = new JTextField();
    tf.addActionListener(al);
    JButton bt = new JButton("enter");
    bt.addActionListener(al);

  • How to trigger button using shortcut keys

    Hi Friends i want to trigger a button in java swings using keyboard keys.
    for ex: a button called "Enter" either i click mouse or i press ALT+E to trigger it.
    Plz give me sample coding if u have
    By
    vinod

    Try looking at the tutorials...
    http://java.sun.com/docs/books/tutorial/uiswing/events/keylistener.html

  • When trying use any Creative Cloud product on opening an application it attempts to verify my subscription "Membership Expired". I click the button "Try Again" and it says "Thank you, your Creative Cloud is now active. Click Continue to use your product."

    When trying use any Creative Cloud product on opening an application it attempts to verify my subscription "Membership Expired". I click the button "Try Again" and it says "Thank you, your Creative Cloud is now active. Click Continue to use your product." Clicking continue takes me back to the Member Expired prompt. My account and subscription are both active and current.

    Does your Cloud subscription properly show on your account page?
    If you have more than one email, are you sure you are using the correct Adobe ID?
    https://www.adobe.com/account.html for subscriptions on your Adobe page
    If yes
    Some general information for a Cloud subscription
    Cloud programs do not use serial numbers... you log in to your paid Cloud account to download & install & activate... you MAY need to log out of the Cloud and restart your computer and log back in to the Cloud for things to work
    Log out of your Cloud account... Restart your computer... Log in to your paid Cloud account
    -Sign in help http://helpx.adobe.com/x-productkb/policy-pricing/account-password-sign-faq.html
    -http://helpx.adobe.com/creative-cloud/kb/sign-in-out-creative-cloud-desktop-app.html
    -http://helpx.adobe.com/x-productkb/policy-pricing/activation-network-issues.html
    -http://helpx.adobe.com/creative-suite/kb/trial--1-launch.html
    -ID help https://helpx.adobe.com/contact.html?step=ZNA_id-signing_stillNeedHelp
    If no
    This is an open forum, not Adobe support... you need Adobe staff to help
    Adobe contact information - http://helpx.adobe.com/contact.html
    -Select your product and what you need help with
    -Click on the blue box "Still need help? Contact us"

  • When I am using the browser for a while and try to use ANY search bar and hit the "search" button it does a whopping NOTHING is there anyway of keeping this from happening?

    Whenever I am using Firefox mobile - either regular, beta or aurora and go to search for something like through the Google search page and attempt to search for something the search bar does nothing and hitting the enter button instead doesn't do anything either. Is there a way to keep this from happening?

    Hi and thanks to not leaving the firefox user alone.
    Cor-el your answer is right as the madperson is and I already knew all these
    answer and I said that before I don’t use any antivirus and I always turn off my firewall from the moment I installed my Windows.
    I even turn off any automatic update for any of my software and I never let any unknown plugins or any thing like that be install without informing me. And if you know some things like Offline Storage and cookies must be to much more than usual and you have to clear them and delete them and I know so much more
    And if you want to know it fixed now. But I don’t know how?
    For understanding my problem read and research about Ixplorer.exe virus it is the same problem about the speed but the different is it doesn’t show any process in task manager like Ixplorer.exe virus
    Bt I have done some things but still I don’t know that’s why it is fixed or not
    First: I searched my system and removed any files have been crated on my system from two days ago since the problem happened.
    And then I used to go about the article in this page and did like this:
    http://answers.yahoo.com/question/index?qid=20080910101846AAazxN5
    but still I don’t know any thing about the problem.
    I can do so many things to fix but I am just curios if that is a virus why it just cut the speed when I am using the browser.
    Please if any one found the reason send me your information I like to know it will improve my knowledge however my problem is solved fro now.

  • 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

  • I have an error message that won't go away and stops me from using any other buttons in the screen.

    I have an error message reading 'item over 1 byte. Connect to a wifi network or use iTunes on your computer to download 'tv show'.
    When I connect it to iTunes or use a wifi network nothing changes.  The warning remains in place no matter how many times I push 'ok'.  iTunes actually says the show is already fully downloaded.
    I can't use any other button or controls because the only thing responding is the 'ok' button on the error message.
    I've now given up and am just trying to exhaust the battery.  What a joke.  This device is only a week old.
    Anyone else with a suggestion on how to make the error message go away? I'm worried this will happen again.
    Thanks!

    Try this.
    Reset the iPad by holding down on the sleep and home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider - let go of the buttons.

  • Can't use down key because it opens automator. Does any one know how to disable this short cut?

    Everytime I press down on down key it opens automator. It doesn't let me delete the app. I don't know what to do, it is very frustating to fill in a chart when I can't use the down key. Does any one know how to disable this short cut?

    Are you talking about the Down Arrow key? To my knowledge there is no way to use that key as a shortcut for anything. But look in the Keyboard section of System Preferences and the Keyboard shortcut tab.

  • When I go into any app that requires me to use the key board I instantly go back to the home page and can't access anything (not even settings)

    When ever I go into an application that requires me to use the key board the app just closes down and takes me back to the home page.  I can't even get into settings.  Also if I bring up the key pad it just sticks after I press a couple of keys?  Help?  I can't get into fb/pages anything!

    Try This...
    Close All Open Apps...  Perform a Reset... Try again...
    Reset  ( No Data will be Lost )
    Press and hold the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears. Release the Buttons.
    http://support.apple.com/kb/ht1430

  • My iphone keeps freezing when I am texting or using the key pad.  Any suggestions? Already tried resetting.

    When I am typing a text or using my key pad, the typing will freeze and my iphone will hang.  I have tried resetting my phone but it didnt correct the issue.  Any suggestions?

    Hello Alesia,
    The following articles may be helpful in getting your keyboard troubles sorted.
    iPhone, iPad, iPod touch: Troubleshooting touchscreen response
    http://support.apple.com/kb/TS1827
    iTunes: Restoring iOS software
    http://support.apple.com/kb/HT1414
    All the best,
    Allen

  • Whenever I open the editor in Photoshop Elements 12 it does not work. When I try to click open in the application it does not do anything. None of the buttons work. When I open a photo using file at the top it opens but I cannot edit it or use any of the

    Whenever I open the editor in Photoshop Elements 12 it does not work. When I try to click open in the application it does not do anything. None of the buttons work. When I open a photo using file at the top it opens but I cannot edit it or use any of the features on the left side.

    Hi Nealeh
    Thanks i think I got it working of a fashion.
    Except the replace colour, does not seem to end up with the colour I picked using the picker tool. Its as though it hads not replaced the colour but blended in the desired colour with the old incorrect colour!
    Buy trial and error picking not the right colour but close - which when mixed with the existing colour is close.
    Sorry I can't post the pictures as the Lingerie Mfg, has me under non disclosure.
    The scenario is:-  say a blonded mainly tanned model a high cut [at the hips] corsette style basque, with an ultra low bra line.
    Our dear model, has just come back from St Barts with a fabulous Tan, and equally striking bold Tan lines!.
    So we have great tanned legs, then the 'porcelain white band' where her swimsuit was.
    Likewise we have a tanned face, and arms, shoulders etc and a great tan on the top of the cleavage, then it stops, white band to the top of the ultralow cut bra line of the basque.
    She must have lived in like the most conservative bikini on the planet [50's style], for 2 weeks!
    Had she had a normal skimpy bikini on, no problem!
    If i don't solve it, she will get fired!
    Not a lack of interest in your post, but I was out, and tried to log in to this site; which I could do, on my iPad Air / 5 [whatever its the new one]. And tried to 'sign in' - but it just hung at the
    "Join Adobe Community" adobe sign in splash screen! with he little whell spinning around continuously!!!
    I have Safari on this iPad. Guess that is all it runs.
    So technology is not my friend today!

  • Using "delete" key on Apple's wireless keyboard shut down applications on my ipad, such as Mail, in Japanese Font.  Any solution?

    I use Apple's wireless keyboard to type email messages on my ipad.  Often applications, such as Mail, would shut down suddenly after using "delete" key on the wireless keyboard.  This happens when I am typing in Japanese language.  It is really annoying because I will lose all the text that are not saved.  Any suggestions? 

    Sorry but that was a completely pointless post.

  • I have an Icloud backup annopuncement on the screen and I can't get rid of it or use any of the buttons

    I have a message on my Ipad that says there hasn't been a back up and when you puch ok to get rid of it, nothing happens, and you can't use any other buttons either?

    Reset it by holding the power and home buttons at the same time until you see the Apple logo, then release.

Maybe you are looking for

  • ITunes 10.2.1 "encountered a problem and needs to close"

    Just about ready to cease using iTunes permanently. I have installed the latest version of iTunes - 10.2.1.1. It will not open at all, instead giving me an error message reading "iTunes has encountered a problem and needs to close". I have spent a we

  • Who knows how to fix iphone 5s blue screen of death and itunes error 4013?!

    Hi Last day, dec 14th, a blue screen of death appears on my iphone 5s, aparently because I was installing facebook app. After that, the iphone remains restarting over and over non stop, until the battery shutoff. I try to press home and power/sleep b

  • What is variant in ABAP Program Process Block in Process Chain?

    I wrote an ABAP program: REPORT ZTEST, PARAMETERS:  PROC(80) TYPE C. I can test this PORGRAM from SE38, it shows me a pop-up screen for PROC and I can enter a value and execute. Now I want to call this  program ZTEST from a process chain. In Process

  • Weblogic server with tuxedo \Q?

    hi all, i m going to access the TUXEDO8.0 \Q functionality with weblogic7.0. what should i do? if i make use of the WTC, can i pass double-byte character to the tuxedo? if not, what can i do? can i use jolt? or corba? sang

  • IPhone IMAP Gmail mailbox behaviors not saved

    I setup Gmail as an IMAP account so I can send mail from my own domain.  It works, but I cannot get the mailbox behaviors to be saved.  I go into Advanced then under Mailbox Behaviors I set  Deleted Mailbox to All Mail (on the server), but it will no