943,670 Members | Top Members by Rank

Ad:
  • ASP.NET Discussion Thread
  • Unsolved
  • Views: 2771
  • ASP.NET RSS
Mar 30th, 2008
0

Access key for button and radiobuttonlist

Expand Post »
HI,

I want to define short keys (access key) for button and radiobutton list,checkbutton list in my page.It is working fine for simple radio button and checkbox but it is not working for radiobuttonlist and checkbox list.
How to add access keys for Checkbox list and radiobutton list.


thanks.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
santoo is offline Offline
17 posts
since Nov 2006
Mar 30th, 2008
0

Re: Access key for button and radiobuttonlist

Since CheckBoxList and RadioButtonList are group controls, you can only set an AccessKey for the group as far as I'm aware. In other words, you can set it for the list, but not for items within the list. Hope this helps explain.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
zAndrew is offline Offline
6 posts
since Mar 2008
Mar 31st, 2008
0

Re: Access key for button and radiobuttonlist

Detect the window.keycode event in javascript. If they hit the combination you wish, use javascript to "check" the box or radio button.

Here's a simple link for you. Detect the key codes pressed. If they hit alt and R, then check the correct box:

if (document.getElementById("radiobtnID")) document.getElementById("radiobtnID").checked = true;

Here's the link:

http://www.htmlgoodies.com/beyond/ja...le.php/3471141
Reputation Points: 43
Solved Threads: 68
Veteran Poster
SheSaidImaPregy is offline Offline
1,080 posts
since Sep 2007

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in ASP.NET Forum Timeline: timer
Next Thread in ASP.NET Forum Timeline: "System.Data.SqlClient.SqlException: Login failed for user 'VASANT\ASPNET'."





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC