• Post Reply Bookmark Topic Watch Topic
  • New Topic

Enter Key Code

 
Smitha Prasad
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to capture the event on enter key clicked on IE MAC through Javascript. I have called window.event.keycode on keydown. but this returns 0 for all the keys. How do i capture the enter key clicked?
 
Rajeshwari Natarajan
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
keyCode 13 is for 'Enter' key.
try this one...

in JSP
 
Smitha Prasad
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I know it is supposed to be 13 for enter key, but in mac for all the keys it is returning 0!
 
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!