aaron.labiosa@nintex.com

Duplicate and Orphaned Workflow Menu Items

Blog Post created by aaron.labiosa@nintex.com Champion on Oct 1, 2014

Products: Nintex Workflow 2013, Nintex Workflow 2010, Nintex Workflow 2007

 

Summary

Duplicate or orphaned menu items are present when a workflow is started from item dropdown.

menuitem.png

Cause

Duplicate item: The workflow was imported from another environment/site/list multiple times with the menu item enabled.

Orphaned item: The workflow was deleted without first disabling the menu item in Workflow Settings.

 

Resolution

The below PowerShell snippet can be run on a SharePoint (Including SharePoint 2007) Server as a Farm Administrator to list all menu items where ‘WebURL’ is equal to the URL of the site and ‘ListTitle’ is equal to the list:

 

[void][System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint")

$($($(New-Object -TypeName Microsoft.SharePoint.SPSite('http://WebURL')).OpenWeb()).lists['ListTitle'].UserCustomActions)

 

Once you have run the above script, you can target the menu item by its index and delete it by running the below snippet:

 

$($($(New-Object -TypeName Microsoft.SharePoint.SPSite('http://WebURL')).OpenWeb()).lists['ListTitle'].UserCustomActions[0]).Delete()

 

Note: The above example will delete the first item in the collection of menu items (index 0).

 

Alternatively, SharePoint Designer can be used to perform the same cleanup by navigating to the list and viewing Custom Actions under List Settings:

 

sharepointdesigner.png

Outcomes