0

The workflow I have sends an email to a user depending on the number of days left until a document expires (90, 60, 30, <10) in a custom list.

Is there a way to schedule a workflow to run at a designated time every day in SharePoint 2010 without having to do i manually? Thanks for the help.

UPDATE

Here is my proposed workflow. What do you think enter image description here

3
  • 1
    This sounds like it would work better as a timer job. They are easier to schedule. A workflow needs a trigger Nov 5, 2014 at 16:25
  • @Colbs is there a way ti implement a timer job without accessing SharePoint Central Administration?
    – PT_C
    Nov 5, 2014 at 20:31
  • you don't have access to CA? You can deploy and activate through Visual Studio Nov 5, 2014 at 20:33

2 Answers 2

1

You can have a powershell script that runs on a task scheduler for the server that runs on the server everyday. You will need to load the powershell snapin at the beginning of the script and then kick off the workflow in the script. This is an example of starting a workflow on every item in the list.

Add-PSSnapin microsoft.sharepoint.powershell
$list = $web.Lists["Shared Documents"]

$assoc = $list.WorkflowAssociations.GetAssociationByName("Workflow Name","en-US")

$data = $assoc.AssociationData
$items = $list.Items
foreach($item in $items)
 {
 $wf = $manager.StartWorkFlow($item,$assoc,$data,$true)
 }

Reference: http://www.thesysadminhimself.com/2013/09/sharepoint-start-workflow-all-items-powershell.html

How to create a task scheduler to run powershell: http://community.spiceworks.com/how_to/show/17736-run-powershell-scripts-from-task-scheduler

2
  • Does this work on SharePoint 365?
    – Humble Val
    Nov 6, 2018 at 20:56
  • no, you must use SharePoint Online PowerShell -- this is for onprem.
    – Mike
    Dec 8, 2018 at 19:02
0

You could create a powershell script like this one http://www.thesysadminhimself.com/2013/09/sharepoint-start-workflow-all-items-powershell.html and schedule the script to run using Task Scheduler on the server. Scheduling workflows is not an option out of the box. Alternatively, you can use third party software such as Nintex Workflow. A free solution could be HarePoint Workflow Scheduler.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.