nuk11888
nuk11888

Reputation: 161

How to create a simple "Expires" workflow to repeat in Sharepoint 2010

I noticed that the "Announcements" web part has the "Expires" feature, but any other links web part I create does not have it. I wanted to add the "Expires" to my custom links web part. So far I got it to delete itself with a simple

If Current Item:Expires is less than Today Delete item in Current Item then Pause for 0 days, 0 hours, 1 minutes

But realized it does not repeat itself, only runs when the item is created. How would I get this workflow to run everyday as a background process?

Update: Workflow I'm trying

Step 1 If Current Item:Expires is less than Today Delete item in Current Item

Step 2 Pause until Current Item:Expires then Pause for 1 days, 0 hours, 0 minutes then Delete item in Current Item

Upvotes: 1

Views: 1802

Answers (1)

Angelo Kee
Angelo Kee

Reputation: 348

for this, I think you could just place it where workflow runs on item creation. Since you have a field that would represent when this item should be deleted, you could do this in the workflow:

enter image description here

if expire date

I'm not sure if the condition is a best practice though, i do this so that it goes to the action every time

in the "this time" value, place in the field "expire" then it would proceed to deleting the item

What happens here is that the item is left pending until the date you specified in your "expire" field, then it automatically deletes the item.

Upvotes: 1

Related Questions