Monday, August 27, 2012

Delete/Purge Files in Document Library with Workflow Using Specifc Duration


Delete/Purge Files in Document Library with Workflow Using Specific Duration

This is a Out-of-Box workflow in MOSS, to automatically delete files from a document library 120 days after they were uploaded. The doc library was being used strictly as a transfer point and needed to be kept clean.

Please fallow the below steps to create a WF.

1. Start a new workflow using SharePoint Designer by going to File -> New -> Workflow.

2. Give the Workflow a name and select the target doc library or list.

3. Set the start event. I set mine to automatically start when the item is created or changed. Click Next.

4. Enter a name for Step 1 such as `Pause for 120 days'

5. Do not select a condition because we want it applied to all items.

6. Under Actions select `Pause for duration'.

7. Change to 120 days, 0 hours, and 0 minutes.

8. On the right choose to `Add workflow step'

9. Once again, give the step a name and no condition.

10. Select Delete Item under Actions and set it to Current Item.

11. Click Finish to save the workflow.



No comments:

Post a Comment