I've been looking at a PowerShell Script by Aaron Labiosa How to purge items from a large history list safely via PowerShell . The script shows how do delete items from the NintexWorkflowHistory List based on date.
I want to make sure when I purge this list that the items I delete aren't involved with Active Workflows not just date. I see an "Outcome". I want to automate this process in PowerShell.