Administration
Background tasks

Configuring Windows Task Scheduler

6min

Task Scheduler is an inbuilt utility that allows you to automatically run programs or scripts on a set schedule or when specified conditions occur. In Passwork starting from version 5.1.0 there is a special script that synchronises users:

PowerShell


It can be run manually or set up to run using Windows Job Scheduler.

We recommend that you first test the script in manual mode. To do this, run the following cmdlet in PowerShell:

PowerShell


If errors occur, they will be written to a log file. After the test, make sure that there are no errors in the following file:

PowerShell


Make sure that the user on whose behalf the script is executed has write permissions

Configuring Task Scheduler

Run PowerShell as Administrator:

  • Right-click on the Start icon in the lower left corner of the screen;
  • Select Windows PowerShell (Administrator) from the context menu.

Create a task in the Scheduler to run the script:

PowerShell


The following parameters should include details of the user on whose behalf the task will run:

  • -User — Username;
  • -Password — User's password.

We recommend using the local Administrator account to avoid any problems with permissions.

Testing and troubleshooting

Open Passwork under an administrator's account and open the Background tasks page.

If you see a message that the scheduler is not configured, check for errors in the log file at:

PowerShell


Forward it to our technical support if you need help with troubleshooting.

Task Scheduler logs

You can view the scheduler log in the Event Viewer at Application and Services logsMicrosoftWindowsTaskSchedulerOperational:

Document image