This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes problem in applying onclick and ondblclick for a same element Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "problem in applying onclick and ondblclick for a same element" Watch "problem in applying onclick and ondblclick for a same element" New topic
Author

problem in applying onclick and ondblclick for a same element

yuvaraj KumarAmudhan
Ranch Hand

Joined: Aug 22, 2009
Posts: 110
Is there anyway to apply the onclick and ondblclick events for the same button?

Thanks
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Use, but the onclick event will always fire so you need to build logic into it to wait to see if the dblclick event fires. Use flags and setTimeout.

Eric
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: problem in applying onclick and ondblclick for a same element