Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Keyboard Shortcuts

Status
Not open for further replies.

virtualranger

Technical User
Sep 14, 2001
115
GB
I'm experimenting with ASP/VB.net. The application I'm building is to replace an old dos-based foxpro database application. I found that I can navigate the old system much faster than the new asp replacement as it was all keyboard based.

Is it possible to set up keyboard shortcuts for hyperlinks in an ASP page? E.g. press 'F2' to take me to the home page, 'F3' for site search etc.

Thanks

Jamie
 
Its ok, I discovered that using javascript I can use the keypress event for adding shortcuts. I'm amazed more websites do not use keyboard shortcuts, its so much quicker.

Jamie
 
Hmmmm.... interesting thought. Could you drop a sample snippet of code to see how we could do that? Thanks.
 
Check this out:

Look at the code snippet in the margin and try out the 'hot keys', it works a treat. I'm going to use it for my navigation bar and incorporate the relevant shortcut into the button image so that users can see it at a glance and use either the mouse or keyboard.
Also check out the section at the bottom about controlling all the keypresses using a function.
Hope this helps.
Jamie
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top