Results 1 to 13 of 13

Thread: SendKeys - Hold Down a Key

Hybrid View

  1. #1

    Thread Starter
    Addicted Member HunterTTP's Avatar
    Join Date
    Jul 2012
    Posts
    146

    Re: SendKeys - Hold Down a Key

    I've tried to do this as many ways as I can. I figured out how to use the code I posted originally. It doesn't show any errors but it simply doesn't work. Oh and I want this to simulate me holding down a key on my keyboard. So I want any application on my computer to be able to think that I'm constantly holding that key.

  2. #2
    PowerPoster dunfiddlin's Avatar
    Join Date
    Jun 2012
    Posts
    8,245

    Re: SendKeys - Hold Down a Key

    Quote Originally Posted by HunterTTP View Post
    I've tried to do this as many ways as I can. I figured out how to use the code I posted originally. It doesn't show any errors but it simply doesn't work. Oh and I want this to simulate me holding down a key on my keyboard. So I want any application on my computer to be able to think that I'm constantly holding that key.
    That doesn't actually make any sense. If you physically hold down a key, it repeats the relevant character continually until you stop, as in your Sendkey loop (the speed can obviously be regulated using a timer instead). If you hold down one of the modifiers (Ctrl, Alt etc.) it does nothing at all. There is nothing in between that simply says I'm holding this key but I don't want anything to happen as a result.
    As the 6-dimensional mathematics professor said to the brain surgeon, "It ain't Rocket Science!"

    Reviews: "dunfiddlin likes his DataTables" - jmcilhinney

    Please be aware that whilst I will read private messages (one day!) I am unlikely to reply to anything that does not contain offers of cash, fame or marriage!

  3. #3

    Thread Starter
    Addicted Member HunterTTP's Avatar
    Join Date
    Jul 2012
    Posts
    146

    Arrow Re: SendKeys - Hold Down a Key

    Quote Originally Posted by dunfiddlin View Post
    That doesn't actually make any sense. If you physically hold down a key, it repeats the relevant character continually until you stop, as in your Sendkey loop (the speed can obviously be regulated using a timer instead). If you hold down one of the modifiers (Ctrl, Alt etc.) it does nothing at all. There is nothing in between that simply says I'm holding this key but I don't want anything to happen as a result.
    You actually make a fantastic point. I didn't think about it really. So if I do the send key loop, how long should I set the time between sends?

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width