Answers for "powershell script to disable screensaver"

0

powershell script to disable screensaver

#The below script will trigger dot key every 60 secs

param($minutes = 60) #//Duration. Until 60 mins below script will run

$myshell = New-Object -com "Wscript.Shell"

for ($i = 0; $i -lt $minutes; $i++) {
  Start-Sleep -Seconds 60 #//every 60 secs dot key press
  $myshell.sendkeys(".")
}
Posted by: Guest on November-29-2020

Code answers related to "powershell script to disable screensaver"

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language