TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
C# Corner
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Powershell Script to Find Workflow Running Instances in SharePoint Site
Karthik Muthu Karuppan
Jan 27
2015
Code
12.4
k
0
0
facebook
twitter
linkedIn
Reddit
WhatsApp
Email
Bookmark
expand
GetWorkflowRunningIn
#List all workflows Running Instances in SPSite
Add-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue
$siteURL = read-host
"Enter the site URL"
$web=Get-SPWeb $siteURL
$lists=$web.Lists
$wf=foreach ($list
in
$lists)
{
$list.WorkflowAssociations | where {$_.RunningInstances -gt 0}
}
if
($wf)
{
write-host
"Workflow running instance found"
-fore green
$wf | select Name,ParentList,RunningInstances | Format-List;
}
else
{
write-host
"No workflow running instance found"
-fore cyan
}
$web.Dispose();
Hotfixes
SharePoint