VB.NET - disable default behavior of backspace button

Asked By Arvind Narayan on 30-Mar-06 05:14 PM
How can I disable the default behavior of the backspace button of going back to the previous page on the browser?

I still want to use it inside certain controls like dropdown to delete the previous character entered (I know how to get this to work using onkeydown). 

arvind

Links - Asked By F Cali on 30-Mar-06 05:19 PM

Here's a few links that may be able to help you using javascript:

http://www.faqts.com/knowledge_base/view.phtml/aid/10465
http://www.experts-exchange.com/Web/Web_Languages/JavaScript/Q_20276433.html
http://www.webmasterworld.com/forum91/4699.htm

use javascript - Asked By Venkat K on 30-Mar-06 11:29 PM

[CODE]
<body onLoad="history.go(+1)">
[/CODE]

check keycode for backspace button - Asked By Amit Khurana on 31-Mar-06 08:30 AM

<script>
function checkShortcut()
{
                  if(event.keyCode==8 || event.keyCode==13)
         {
               return false;
         }
}
 </script>
<body onkeydown="return checkShortcut()">
thanks - Asked By Arvind Narayan on 31-Mar-06 09:18 AM
for all your replies - it works now.