I want to prevent windows from auto locking (unable to change as decided by group policy ). The simplest solution I can think of is getting AHK to auto move the mouse as set intervals, so I've found the following code online to add into my AHK and it just doesn't seem to want to work, I've tried to bind the below to the F8 key by adding 'F8::' to the start. If it matters, I'm using a portable version on version number 1.1.30.03.
Code: Select all
F8::
CoordMode, Mouse, Screen
Loop
{
; Move mouse
MouseMove, 1, 1, 0, R
; Replace mouse to its original location
MouseMove, -1, -1, 0, R
; Wait before moving the mouse again
Sleep, 3000
}
return