Author Topic: Helpl with autohotkey  (Read 1175 times)

0 Members and 1 Guest are viewing this topic.

Offline Jixr

  • Thread Starter
  • Posts: 864
  • Location: Ireland
Helpl with autohotkey
« on: Thu, 24 October 2013, 13:16:34 »
I'm looking for a way within autohot key to basically disable or turn my "num lock" key into something else.
But I still want num lock to be on so I can use the numbered keypad.

any ideas or anyone have a script?

Offline Daniel Beardsmore

  • Posts: 1874
  • Location: Hertfordshire, England
  • RIP
    • Boring twaddle
Re: Helpl with autohotkey
« Reply #1 on: Thu, 24 October 2013, 16:51:07 »
Convert num lock into the letter A:

NumLock::A

Convert num lock into left shift:

NumLock::LShift

The state of number lock doesn't depend on whether the key is still working; you just can't change the state with that key while the script is running.
Bore Awards
Most Boring Person on the Planet – 2011 Winner

Offline ijprest

  • Posts: 87
  • Location: Ottawa, ON, Canada
Re: Helpl with autohotkey
« Reply #2 on: Thu, 24 October 2013, 21:54:20 »
You can also put this at the very top of the file (in the "auto-execute" section).  It does exactly what it says.

Code: [Select]
SetNumLockState, AlwaysOn
return


Personally, I like to use Num Lock to show/hide an instance of the Calculator app.

Code: [Select]
WinToggle(Title,EXE) {
  DetectHiddenWindows, on
  If WinExist(Title) {
    If WinActive(Title) {
      WinMinimize
      WinHide
    } else {
      WinShow
      WinActivate
    }
  } else {
    Run %EXE%
  }
}

NumLock::WinToggle("Calculator","Calc")

Offline laffindude

  • Posts: 1521
  • ( ̽ ¬ ˳¬)
Re: Helpl with autohotkey
« Reply #3 on: Thu, 24 October 2013, 23:29:56 »
You can also add "SetNumLockState, AlwaysOn" in the autoexec section to lock it on when you run the script.