Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. How can I create a short cut key any button in .net

How can I create a short cut key any button in .net

Scheduled Pinned Locked Moved ASP.NET
questioncsharpcom
6 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • I Offline
    I Offline
    indian143
    wrote on last edited by
    #1

    Hi all, How can I create a short cut key any button in .net. Suppose I have a button named btClick and button text as "Click". In this I want to keep "C" as short cut key for this button click event. Can I do it in Windows and Web applications too?. If so please tell me how in both type of applications?. Thank you. Regards,

    S/W Engineer Akebono Soft Technologies aleem_abdul@akebonosoft.com.

    C L 2 Replies Last reply
    0
    • I indian143

      Hi all, How can I create a short cut key any button in .net. Suppose I have a button named btClick and button text as "Click". In this I want to keep "C" as short cut key for this button click event. Can I do it in Windows and Web applications too?. If so please tell me how in both type of applications?. Thank you. Regards,

      S/W Engineer Akebono Soft Technologies aleem_abdul@akebonosoft.com.

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      I don't think you can in web apps.  In windows apps, you can certainly catch a keyboard event and call the button click if it's a 'c'.  I am not sure if it's possible otherwise.  In a menu, if you type &, as in &Click, that gives you a shortcut.

      Christian Graus - C++ MVP 'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert

      1 Reply Last reply
      0
      • I indian143

        Hi all, How can I create a short cut key any button in .net. Suppose I have a button named btClick and button text as "Click". In this I want to keep "C" as short cut key for this button click event. Can I do it in Windows and Web applications too?. If so please tell me how in both type of applications?. Thank you. Regards,

        S/W Engineer Akebono Soft Technologies aleem_abdul@akebonosoft.com.

        L Offline
        L Offline
        linpihong
        wrote on last edited by
        #3

        if you want to do it in web application,you must have a focus on something(e.g textbox) and then catch the keyboard code to press

        I 1 Reply Last reply
        0
        • L linpihong

          if you want to do it in web application,you must have a focus on something(e.g textbox) and then catch the keyboard code to press

          I Offline
          I Offline
          indian143
          wrote on last edited by
          #4

          Yeah, ok. Even then too, how. Please give me the details if possible please. Thank you. Regards,

          S/W Engineer Akebono Soft Technologies aleem_abdul@akebonosoft.com.

          C 1 Reply Last reply
          0
          • I indian143

            Yeah, ok. Even then too, how. Please give me the details if possible please. Thank you. Regards,

            S/W Engineer Akebono Soft Technologies aleem_abdul@akebonosoft.com.

            C Offline
            C Offline
            Christian Graus
            wrote on last edited by
            #5

            This means, you can handle a key press in javascript, so long as you require the user to have focus on a specific control.  Or, you can hook the code up for all controls, I guess.

            Christian Graus - C++ MVP 'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert

            B 1 Reply Last reply
            0
            • C Christian Graus

              This means, you can handle a key press in javascript, so long as you require the user to have focus on a specific control.  Or, you can hook the code up for all controls, I guess.

              Christian Graus - C++ MVP 'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert

              B Offline
              B Offline
              blue_arc
              wrote on last edited by
              #6

              use "access key" property of a text box, or button... in web application this will solve ur problem....

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups