Hi,
There is a Workflow process that needs to move a folder at the end of the approval. Sometimes, some users may have PDF documents still open from their Web Client session when they finish their process and the WF will move that folder, but the WF will terminate with following error message:
Multistatus response. [9039] Another operation on which this operation depends failed. [9054] Document locked with a persistent lock. [9167]
FYI, in this process, I can safely cancel any checked out document.
I need to ensure the tasks does complete successfully so I can put a Try-Catch around that Move activity, and I would like to execute an Undo Check Out, just like an administrator account can do within the Laserfiche Client, but within a SDK VB Script.
From the WF activity called Find Entries, I have enabled the additional Property IsCheckedOut but that property doesn’t seem to change state when a document is checked out. The only property I can use is CheckedOutBy where a username will be present if a document is actually checked out.
Then, I have set a SDK Script to run like this:
Using di As DocumentInfo = DirectCast(me.BoundEntryInfo, DocumentInfo) 'If di.IsCheckedOut = True Then di.UndoCheckOut di.Save 'End IF End Using
But I get an error that says... The document must be checked out first... And it's really checked out as I can see with the Windows Client.
Any help would be appreciated.