Skip to content

Instantly share code, notes, and snippets.

@astepchenko
Forked from si-hyeon/key_signal.ps1
Created October 21, 2021 13:27
Show Gist options
  • Select an option

  • Save astepchenko/f042fda5c9a20123ab68f7c1b0a608cc to your computer and use it in GitHub Desktop.

Select an option

Save astepchenko/f042fda5c9a20123ab68f7c1b0a608cc to your computer and use it in GitHub Desktop.
Powershell script to keep the key signal
# Send a key that not used well on your environment
# This way works well for screensaver activated by secure program on Windows 7
# key mapping ref. https://technet.microsoft.com/en-us/library/ff731008.aspx
$myshell = New-Object -com "Wscript.Shell"
while ($true)
{
$myshell.sendKeys("{NUMLOCK}{NUMLOCK}")
Start-Sleep -Seconds 60
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment