Home
Paste
Show Key
Listed
Keep Editing
#Init param($minutes = 60) Add-Type -AssemblyName System.Windows.Forms $host.ui.RawUI.WindowTitle = "Prevent Screensaver" #Main for ($i = 0; $i -lt $minutes; $i++) { Write-Host "." -NoNewline Start-Sleep -Milliseconds 59999 #59,999s $Pos = [System.Windows.Forms.Cursor]::Position [System.Windows.Forms.Cursor]::Position = New-Object System.Drawing.Point((($Pos.X) + 1) , $Pos.Y) Start-Sleep -Milliseconds 1 #0,001s $Pos = [System.Windows.Forms.Cursor]::Position [System.Windows.Forms.Cursor]::Position = New-Object System.Drawing.Point((($Pos.X) - 1) , $Pos.Y) }
#Init param($minutes = 60) Add-Type -AssemblyName System.Windows.Forms $host.ui.RawUI.WindowTitle = "Prevent Screensaver" #Main for ($i = 0; $i -lt $minutes; $i++) { Write-Host "." -NoNewline Start-Sleep -Milliseconds 59999 #59,999s $Pos = [System.Windows.Forms.Cursor]::Position [System.Windows.Forms.Cursor]::Position = New-Object System.Drawing.Point((($Pos.X) + 1) , $Pos.Y) Start-Sleep -Milliseconds 1 #0,001s $Pos = [System.Windows.Forms.Cursor]::Position [System.Windows.Forms.Cursor]::Position = New-Object System.Drawing.Point((($Pos.X) - 1) , $Pos.Y) }