I maintain a SharePoint list/site used by members of multiple teams. The overall point of the list and site is for members of team A to add action items that will be assigned and dispositioned by members of team B.
I've added a workflow to the list, running whenever an item is edited. The details of the workflow are not important (or shouldn't be...). However, since I both maintain the list and use it as a member of team A, sometimes I want the workflow to fire (as an end user) and sometimes I don't (when I'm cleaning things up).
In the past I had opened up SPD and simply disabled the worfklow from running on edit, which works. But I live in fear I'll forget to re-enable it when I'm done maintaining and cleaning up. So I'd like to provide a "kill-switch" of sorts that lets me halt a workflow early.
I thought the below picture would work: check to see if "ADMIN" is entered in a certain field. If it is, re-set the field's value to what was previously entered, send me an email notifying me the workflow was overridden (in case someone else accidentally enters "ADMIN," at least I'll know), and then log the override while stopping the workflow. (Non-relevant personal details have been redacted from the screenshot.)
The first time I did this, it worked as intended. I've since done it twice more and both times the rest of the workflow triggered, causing confusion.
Two questions:
- Can anyone diagnose why the workflow is continuing to run even though it should be stopping, and
- Can anyone provide a better "optional over-ride" mechanism? I don't want it to be triggered by anyone else accidentally, so adding a visible checkbox or field on the "Edit Item" form isn't ideal.
Potentially helpful: The "Latest Update" field referenced in the workflow is a full-HTML field with markup allowed, but each of the three times mentioned in the question I have taken care that the only text submitted was ADMIN with no HTML formatting tags.