Clear Timeout
<html> <body> <script language="javascript"> var intValue = 0 function myMethod(){ alert('Hello'); } </script> <button onclick="intValue=window.setTimeout('myMethod()', 1000);">Start timeout</button> <button onclick="intValue=window.clearTimeout(intValue);">Stop timeout</button> </body> </html>