473,503 Members | 1,685 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Disabling default button behavior

If a user is viewing an ASP.NET page in the browser and presses Enter, the
first button the page is "pushed" even if not selected. We are finding the
novice users are pressing Enter (thinking it will bring them to the next
field) and getting very confused. Advancing to the next field would be
nice, but I would settle for doing nothing.

Is there a way to disable this behavior? I suppose I could override the
"onkeydown" event in JavaScript for every single field. Is there any better
solution?
Nov 17 '05 #1
1 1108
better is relative, this is probably the solution with the least pain
eventkey code = 13 for enter if i remember correctly

--
-----------
Got TidBits?
Get it here: www.networkip.net/tidbits
"Stephen Walch" <sw****@proposion.com> wrote in message
news:eP*************@tk2msftngp13.phx.gbl...
If a user is viewing an ASP.NET page in the browser and presses Enter, the
first button the page is "pushed" even if not selected. We are finding the novice users are pressing Enter (thinking it will bring them to the next
field) and getting very confused. Advancing to the next field would be
nice, but I would settle for doing nothing.

Is there a way to disable this behavior? I suppose I could override the
"onkeydown" event in JavaScript for every single field. Is there any better solution?

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1633
by: Jon | last post by:
I have written a custom event handler for the mousewheel event, but in addition to my custom event handler code, the default event handler behavior is still being executed. For the mousewheel...
4
4140
by: Steve | last post by:
I have the MDI MFC application ported to .NET. Now this application include mixed managed/unmanaged code. The application displays progress dialog with the cancel button during lenghtly...
12
2232
by: Nalaka | last post by:
Hi, I suddenly started getting a lot of errors from html validation (some CSS) so I followed the following instructions to disable it. If you'd rather not have these types of HTML validation...
9
2154
by: Paul Keegstra | last post by:
Hi, I am currently working on an asp.net 2.0 web site that is a replacement of a classic asp web site. The current web site uses a Commerce Server 2002 database for storing user information. ...
0
7202
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7086
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7280
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6991
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7460
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
5014
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3154
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
736
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
380
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.