A Power Shell Script can be scheduled using the Windows Task Scheduler. Once you have the PowerShell script ready, you could schedule the PowerShell script by launching the Windows Task Scheduler
- On the right click on Create Basic Task
- Then it would open up a small window which has three main tabs that you need to focus on-General, Triggers and Actions.
- On the General tab, select the radio button “Run whether a user is logged in or not”or otherwise depending on whether you want to run the script when the user is logged In.
- On the Triggers tab, specify the time/frequency when the script needs to run.
- On the Actions Tab, Choose the Action “Start a Program” from the Dropdown and enter PowerShell.exe. Then against the parameters specify the Path of the PowerShell script and click OK.
Now your PowerShell script would run at the scheduled time provided the system is powered ON.