JavaScript Reference/Javascript Properties/altLeft
"altLeft" Example
<source lang="javascript">
<html> <head> <script language="JavaScript">
function function1() { var m = event.altLeft; if (m == false) { alert("The Left Alt Key is not pressed"); document.all.myButton.value = "Click here while pressing the Alt key"; } else if(m == true) { alert("The Alt Key is pressed"); document.all.myButton.value = "Click here"; } }
</script> </head> <body> <input id="myButton" type="button" value="Click here" onClick="function1();"> </body> </html>
</source>
"altLeft" is applied to
<source lang="javascript">
+----------------+--------------------------------------------------------------+ | Applied_To |event | +----------------+--------------------------------------------------------------+
</source>
"altLeft" Syntax and Note
<source lang="javascript">
Note: Read-only property. Whether or not the left ALT key is being held down.
Syntax:
window.event.altLeft
</source>