Search code examples
automationautohotkey

How can I send comma before down in Autohotkey (AHK)?


I want to make an AHK script to do the following:
After writing a hotstring, repeat for ever:
Send a comma
Send down arrow
My current code is this:

::startthisthingnow::
while True
    Send, {,}
    Send, {Down}

But it only sends unlimited commas after each other, like:
,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,


Solution

  • Either place all sends in one line:

    Send, {,}{Down}
    

    or include the second Send in the loop:

    while True{
      Send, {,}
      Send, {Down}
    }