Переглянути джерело

Add 'KBRemover-TaskAdder.bat'

Ethan 2 роки тому
джерело
коміт
f7d0a46e60
1 змінених файлів з 12 додано та 0 видалено
  1. 12
    0
      KBRemover-TaskAdder.bat

+ 12
- 0
KBRemover-TaskAdder.bat Переглянути файл

@@ -0,0 +1,12 @@
1
+@echo off
2
+
3
+rem Escalate to administrator privileges
4
+powershell -Command "Start-Process cmd -Verb runAs"
5
+
6
+rem Add Task Scheduler entry
7
+schtasks /create /tn "KBRemover" /tr "powershell -File C:\MCW\KBRemover.ps1" /sc DAILY /st 07:00 /ru System
8
+
9
+rem If the task fails to run, it will run on the next computer startup
10
+schtasks /create /tn "KBRemover" /tr "powershell -File C:\MCW\KBRemover.ps1" /sc ONSTART /ru System
11
+
12
+echo Task Scheduler entry created successfully.

Powered by TurnKey Linux.