Keyboard "Delete" Key

Hi eveyone, how are all of you? I have a little problem. I am using Keyboard event to call a function i-e, when user press the Delete key, the selected object will be deleted. Now the problem is that when I press only Delete key, nothing happens but if I press "TAB+Delete", it works 100% fine.
If am using condition "if(event.keyCode == 46)". I want it to work on pressing "Delete" key instead of "Tab+Delete".
If anyone of you has any idea about this issue, please let me know .... I'll be really really thankfull to you.
Thanks ...
.:.WAHAB

Hi there,
This is quoted from here: http://livedocs.adobe.com/flex/3/html/help.html?content=events_11.html
A common way to handle global key presses is to create a listener for the KeyboardEvent.KEY_DOWN or KeyboardEvent.KEY_UP
event on the application. Listeners on the application container are
triggered every time a key is pressed, regardless of where the focus is
(as long as the focus is in the application on not in the browser
controls or outside of the browser). Inside the handler, you can
examine the key code or the character code using the charCode and keyCode properties of the KeyboardEvent class. 
It works when you press TAB because TAB essentially gets a child from the display list and focuses on it. Once your application/object has focus ( because you pressed TAB ) the keyboard listener can react. If your application is out of focus then it won't react to any keyboard events.
In case your object is selected and your application has focus and it's still not reacting then you could try using event.preventDefault(); to prevent default behavior; if that's not helping either then you need to recheck your code because the problem is in your code somewhere.
With best regards,
Barna Biro
Blog: http://blog.wisebisoft.com

Similar Messages

  • Wireless Keyboard Delete Key not working properly

    Recently, my wireless keyboard's delete key has been malfunctioning. Instead of erasing right to left, it deletes left to right. This is without pressing other buttons such as the fn key. Also, the left and right keys do not move the cursor properly such as in the address bar. They only move the page up and down. It works normally right at start up and after I restart the computer but after a few minutes it goes back. Is there a problem with my settings or the keyboard itself? Thank you for your help!

    Hello:
    I do not know of a setting that would do that - especially intermittently.
    I would suspect the KB is failing/has failed.
    Barry

  • A1314 Keyboard delete key backwards only?

    I just purchased an Apple A1314 bluetooth keyboard, and the delete key will only delete to the right as if the function key is pressed. I have paired it with 3 different macs, all with the same results. Opening the Keyboard Viewer does not show the delete key as being pressed ever, but it does indeed delete to the right both when pressed alone or with the function key. Also, if I have a window selected that has no fields for text selected and I hold down the delete key, it begins making the key repeat sound, so I would say it is certainly making some kind of input. I've made sure the Accessibility preferences to make sure the "Enable Mouse Keys" isn't checked. I've paired and re-paired it with multiple machines. I'm running OS 10.9.1 on all machines I tested it with. If it turns out to be a defective product, is there a way to map the eject key to function as the delete key? Thanks for any input.

    Hi there,
    This is quoted from here: http://livedocs.adobe.com/flex/3/html/help.html?content=events_11.html
    A common way to handle global key presses is to create a listener for the KeyboardEvent.KEY_DOWN or KeyboardEvent.KEY_UP
    event on the application. Listeners on the application container are
    triggered every time a key is pressed, regardless of where the focus is
    (as long as the focus is in the application on not in the browser
    controls or outside of the browser). Inside the handler, you can
    examine the key code or the character code using the charCode and keyCode properties of the KeyboardEvent class. 
    It works when you press TAB because TAB essentially gets a child from the display list and focuses on it. Once your application/object has focus ( because you pressed TAB ) the keyboard listener can react. If your application is out of focus then it won't react to any keyboard events.
    In case your object is selected and your application has focus and it's still not reacting then you could try using event.preventDefault(); to prevent default behavior; if that's not helping either then you need to recheck your code because the problem is in your code somewhere.
    With best regards,
    Barna Biro
    Blog: http://blog.wisebisoft.com

  • Bluetooth keyboard delete key

    I have used three different Bluetooth keyboards with my ipad2 and on everyone of them the delete key performs like a traditional back space key, deleting anything to the left of the cursor, not to the right of the cursor.  Am I missing something here? Is there a way to make the delete key operate like the one on a traditional keyboard?

    Skydiver, you are right in the movements of the two keys on traditional keyboards; and, when I looked, the Logitech bluetooth keyboard does NOT have a backspace key, only a Delete key that operates like a traditional backspace key (deletes from right to left).  However, the Kensington ipad portfolio with a built-in/detachable bluetooth keyboard DOES have both keys, but they both operate like a backspace key.  The Vivitar brand ipad portfolio with built-in bluetooth keyboard ALSO had both keys, but operated only like a backspace key.  I was just wondering if it had something to do with my ipad (which apparently it does since it's an Apple product based on further research), or if I was just missing something.  This was just an issue I ran into while typing on my ipad with the bluetooth keyboards and I found it a bit frustrating.  I am not a Mac user/owner so I was not aware that at first Apple computers did not even have a delete key, only a backspace key.
    Thanks for the dialogue on this issue.  I consider it closed.

  • Delete key in on screen keyboard for Dell Venue Pro 8 tablet?

    Using Windows 8.1 on a Dell Venue Pro 8 tablet. The software, onscreen keyboard does not have a Delete key. That makes it very hard to do any editing after highlighting a block of text. Hitting the backspace key takes it out of the block edit mode and
    just deletes on letter at a time. Anyone know if this is a general Windows tablet problem or possibly some unique to the Dell Venu Pro 8 tablet? I would like to change the keyboard layout to include the Delete key. Also, is there setting so it could recognize
    when to capitalize a word? I would think that my Sumsung phone would not have a better software keyboard, but it has a much, much better version in SwiftKey.

    I guess you mean the "touch keyboard" ?
    There is a "keyboard selector" key in the bottom right hand corner, which allows you to select alternative layouts - have you tried that?
    Don
    (Please take a moment to "Vote as Helpful" and/or "Mark as Answer", where applicable.
    This helps the community, keeps the forums tidy, and recognises useful contributions. Thanks!)

  • Forward and Back Delete Keys on Wireless Keyboard (short)?

    Hello, All:
    My new Apple wireless keyboard (short version) has only the delete key on it. Is there a way to program the additional delete key, allowing me to delete in the right-hand direction? The current delete key deletes only the in the left-hand direction.
    Thank you,
    Dean

    I've just been setting up a new Wireless Keyboard for a client using a MacBook with Tiger - on which the Fn+Delete combination works - and have found that it doesn't work on her Wireless Keyboard like everyone says it should! It just gives an error beep. Help!

  • 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.

  • Why does the delete key on the keyboard go backward?  How can I make it go the other way?

    I'm used to a PC keyboard that enables me to delete characters from where my cursor it to the next space to the right.  The keyboard I have with my Mac, alas, is frustrating for me to use because it goes backwards from what I am used to.  Is there a fix to this?  My PC keyboard has a backspace button in addition to the delete button, so it is very straightforward for me that way.

    The delete key, if the cursor is placed mid sentence, will remove letters etc forwards from that cursor point.   If you are deleting from the end of a sentence, the backward facing long arrow above the return key will delete backwards from that point.
    For groups of letters or sentences, highlight them and press delete.
    It is one of those situations where you should learn the new approach because the rest of the system is geared to it.
    Message was edited by: seventy one

  • Wireless keyboard spacebar & delete key

    wireless keyboard spacebar & delete key are locked/do not work. Any suggestions?

    Hello "BDAqua".
    .. I'm experiencing the same problem.
    ... and, where checking, with clicking on both my spacebar and delete function keys, along with in my own case, additionally, my ["/'] key, ... in a Text Edit document, .. each, does in fact work.
    What does this tell me in fact. ?
    — Typing this, part and part, on both my main keyboard, together along with a "USB" plug-in.
    — This on a 2009 "iMac", running Mac OS X v.10.6.8.
    Appreciate your time.

  • When I use my Delete key to delete a song, I get a pop-up.  This is OK, except the Keep File button is defaulted and I cannot tab or arrow to the "Move to Trash" button, and so i need to use my mouse.  How can I do this only with keyboard?

    When using iTunes on my iMac, I use my Delete key to delete a song and I get a pop-up.  This is OK, except the Keep File button is defaulted and I cannot tab or arrow to the "Move to Trash" (or Cancel) button, and so I need to use my mouse.  How can I do this only with keyboard?

    Huh.. Interesting. I went back to check these proceedures and found there is a difference between using the return key or the space bar as the action command.
    tabbing the blue ring moves the selection and then spacebar takes that action. The return key takes action of only the blue collored button.
    .... learn somting new every day, even if it is somthing I previously forgot

  • Brand new 15" MacBook Pro Retina - unplugged from Thunderbolt Display and Keyboards today find keyboard alpha-numerics not working; except the function keys, delete key, tab key, command/ctrl/shift/alt/fn and arrow keys; and 7/8/9/u/o/j/l nudge cursor

    Brand new 15" MacBook Pro Retina - unplugged from Thunderbolt Display and Keyboards today find keyboard alpha-numerics not working; except the function keys, delete key, tab key, command/ctrl/shift/alt/fn and arrow keys; and 7/8/9/u/o/j/l produce cursor nudges.

    It's a new machine - and the Thunderbolt Display is meant to work with it. You need to just make an appointment at your local Apple Store and have them fix whatever is wrong.
    If you like, you could always try a SMC reset and a PRAM/NVRAM reset to see if either of those will get your keyboard back in working order...
    Clinton

  • Delete key + Keyboard issue

    Hey, I have a MacBook from mid 2007 that I use for Boot Camp. I was wondering if there was any way to have some key that would be the equivalent of the delete key on Windows (I am running XP).
    Additionally, on XP, for whatever reason it likes to go to the French keyboard, which is annoying since I will go for a "?" and get a capital "é". Anyone know what to do?

    Sounds like you have a French keyboard selected. In Control Panel select the Regional and Language Options. Now click on the Languages tab and select the Details box. Here you can control which keyboards are available under Installed Services.
    If you poke around a bit you will be able to address the French keyboard issue.

  • Delete Key Not Working on Bluetooth keyboard

    i just purchased an aftermarket Bluetooth keyboard recently and i only used it for about 2 hours and now the delete key won't work. what happened?

    It is a personal preference, but I always buy Apple products.  IMHO, the amount I might save on third party devices is not wither the trouble.
    Barry

  • HT3226 Delete key is not working on the keyboard. What should I do?

    The delete key is not working on the wireless keyboard. What should I do?

    If it ever worked before then do 2-3 SMC resets back to back. You can find instructions at https://discussions.apple.com/docs/DOC-3603

  • Why doesn't my forward delete key work on my apple keyboard with numeric keypad?

    I bought a wired apple keyboard with numeric keypad to pair with my Mac Pro (late 2013) and when I try to use the forward delete key, it does nothing. I have even tried to use the fn + delete shortcut and that doesn't work either. I'm using OS X Yosemite 10.10.3. Anyone have any ideas how to fix this?

    Again, waking up an old thread:
    I first used an air compressor, set around 50psi, to "air out" all the ports.
    Then I used a clean cloth to dab a bit of alcohol on an SD card's contacts... slid it in and out several times, dabbing a little more alchol each time... and voila!
    All of our SD cards now seem to work fine... recognize, read, eject...
    Also used alcohol to clean the contacts on all the cards.

Maybe you are looking for