PnP Script to remove/delete workflows from SharePoint List

Shone Karthanal 21 Reputation points
2020-07-10T19:23:38.607+00:00

Hi everyone! Can someone help me with how to remove workflows from a SharePoint list? I have a lot of SharePoint Designer 2010 workflows that I need to remove from lists and I cannot figure out how to do this. I have tried using Remove-PnPWorkflowSubscription and Remove-PnPDefinition but it wasn't working. I am not very familiar with PowerShell.

Thanks.

Community Center | Not monitored
0 comments No comments

Answer accepted by question author

Anonymous
2020-07-10T21:51:07.94+00:00

Sharepoint is not currently supported here on QnA. They're actively answering questions in dedicated forums here.
https://social.technet.microsoft.com/Forums/sharepoint/en-US/home?category=sharepoint
https://social.technet.microsoft.com/Forums/sharepoint/en-US/home?forum=onlineservicessharepoint
https://techcommunity.microsoft.com/t5/sharepoint-developer/bd-p/SharePointDev

--please don't forget to Accept as answer if the reply is helpful--


Regards, Dave Patrick ....
Microsoft Certified Professional
Microsoft MVP [Windows Server] Datacenter Management

Disclaimer: This posting is provided "AS IS" with no warranties or guarantees, and confers no rights.

Was this answer helpful?


1 additional answer

Sort by: Most helpful
  1. Marilee Turscak-MSFT 37,396 Reputation points Microsoft Employee Moderator
    2020-07-10T21:51:12.87+00:00

    This is more of a SharePoint or regular PowerShell question than an Azure AD question, and these products are supported on Microsoft Answers. I would suggest checking there for this. https://answers.microsoft.com/en-us

    I would also check out this similar thread here, which says:

    To remove a workflow association from a list or document library

    1. Verify that you have the following administrative credentials:

    You must be a member of the Site Owners group on the SharePoint site that you are configuring.

    1. Browse to the list or library from which you want to remove a workflow.
    2. Do one of the following:

    For a list, on the List Tools tab, click List.

    1. In the Settings group, click List Settings.

    For a library, on the Library Tools tab, click Library.

    In the Settings group, click Library Settings.

    On the List Settings or Library Settings page, in the Permissions and Management section, click Workflow Settings.

    1. On the Workflow Settings page, click Remove a workflow.

    Note - The Remove a workflow link is not displayed if no workflows are associated with the list or library.

    1. On the Remove Workflows page, find the workflow that you want to remove and choose from the following options:

    Select No New Instances to prevent new instances of this workflow from running but still allow for running instances to finish.

    After all running workflows are finished, you can return to this page to completely remove the workflow association.

    Select Remove to prevent new instances of this workflow from running and remove all instances of this workflow. This option removes instances that are already running.

    1. Click OK.

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.