cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Error: "task is currently locked by a running workflow and cannot be edited"

Currently we're experiencing a mysterious error on Nintex, where certain group of users' (with Full control)  task remain pending.

The task is complete but then it remains pending and when try to respond again it says "This task is currently locked by a running workflow and cannot be edited".

Any ideas ?

Labels: (1)
Tags (2)
0 Kudos
Reply
7 Replies
Workflow Hero

Re: This task is currently locked by a running workflow and cannot be edited

Hi Grace,

just to make sure i understood you correctly: the task can be completed, but afterwards it gets the status "pending" again and can not be completed again, because the user gets the error you provided?!

Sounds like the workflow gets restartet, as soon as the task gets completed. The workflows starts again and creates a new task with the status pending and this seems to mess the task up. You can check the workflow history of the item that is related to this task and see which workflows are running on this item.

I would suggest that after the task completion the workflow updates your list item (maybe by setting a comment field)? So maybe you just need to tell your workflow not to start when an item is edited. If you, however, need this behaviour you maybe need to redesign your workflow to let it restart correctly.

Can you maybe show or explain the process of your workflow more detailed at this stage?

Accept as Solution Reply
Not applicable

Re: This task is currently locked by a running workflow and cannot be edited

Hi Philipp,

What I meant with the Task is complete, I can see that the user approved. But the status is still Pending.

And when they try to Approve again, they get that errror.

And looking at the workflow it is stopped at the Task Action never going into any branch.

Strange because it only happens with a certain group of people , with Full Control at that.

Accept as Solution Reply
Workflow Hero

Re: This task is currently locked by a running workflow and cannot be edited

Do you have a workflow on your Workflow Tasks list? Or another workflow that updates a task? When a nintex workflow starts on an item, there is a lock.

Check this very good article if it can help you : https://community.nintex.com/docs/DOC-1256

Accept as Solution Reply
Not applicable

Re: This task is currently locked by a running workflow and cannot be edited

Hi Damien,

You're right! I forgot I have a workflow under my Task. But that wasn't a proble before and it starts manually.

Let me delete and check.

Accept as Solution Reply
Highlighted
Not applicable

Re: This task is currently locked by a running workflow and cannot be edited

Hi Grace M

I have had a similar issue

All that is happening is the task has been delegated to me -

As soon as I go the approval URL and try to approve / reject the item the item it errors on me.

I tried again and the item became "locked" - I am not sure if SharePoint was still trying to do something or if it recognised I was trying to access it.

I am not sure but I was wondering if this was to with an issue that I encountered previously -

Nintex Workflow Error - Sharepoint

Basically the approver was clicking on the URL and having an issue with the link, however the second time they clicked the link no error was there.  It was an issue with my SharePoint environment - it was slow in creating the workflow task and the email was issued before the task had finished being created.

I was wondering if this was a similar issue?    Have you been able to resolve your problem?

Thanks

Karen

Because when I tried again a few hours later I was able to approve the item without any problems.

Accept as Solution Reply
Workflow Hero

Re: This task is currently locked by a running workflow and cannot be edited

If you still are receiving the message regarding blocked tasks, this PowerShell Script should unblock all of them:

[system.reflection.assembly]::LoadWithPartialName("Microsoft.SharePoint")

$siteUrl="https://yourSubSiteURL"

$site=new-object Microsoft.SharePoint.SPSite($siteUrl)

$web=$site.OpenWeb()

$web.url

$i=0

write-host $web.lists

foreach($list in $web.lists){

    foreach($item in $list.items | where {$_[[Microsoft.SharePoint.SPBuiltInFieldId]::WorkFlowVersion] -ne 1}){

    

            if($item["Status"] -eq "Not Started")

            {

                  Try

                  {

                        Write-Host Unlocking workflow on $item.name

                        $item[[Microsoft.SharePoint.SPBuiltInFieldId]::WorkFlowVersion]=1;               

                        $item.SystemUpdate()

                        $i++

                  }

                  Catch [System.Exception]

                  {

                        Write-Host Caught error trying to unlock workflow -ForegroundColor Red

                  }

            }        

      }

}

Write-Host Unlocked $i workflows within $web.url

$web.dispose()

$site.dispose()

Accept as Solution Reply
Workflow Hero

Re: Error: "task is currently locked by a running workflow and cannot be edited"

Hi Pedro Jiménez hopefully you've resolved this outdated problem.

could you post a resolution and close the question by marking it answered?

 

#BRGreview

Accept as Solution Reply