3.2.0

Halt Backspace key press on IE

Hi,
Having problem with Backspace key. When user hit the Backspace key, my code should just display message and stop the action. But, instead the browser go to previous page (I think this is standard behavior for backspace).

Following is my code:-
obj.onKeyBackspace = function(event){
alert("Backspace key pressed");
return 1;
}

Any help, please?
TIA

lcs
September 27,
Any help?

thanks
lcs
September 28,
Ics,

try this.

document.onkeydown = haltBackspace;
function haltBackspace() {
if (window.event && window.event.keyCode == 8) {
return false;
}
}
raymone
September 28,
It works! thanks.
lcs
September 28,

This topic is archived.

See also:


Back to support forum