views:

177

answers:

1

I am creating a workflow for a document library that needs to be approved by up to three individuals and have been trying to use the default Approval workflow. For most cases only one approval will be needed but given certain arguments more than one is required. My problem is that the workflow that calls 'Start Approval(10) on Current Item...' ends immediately after completion. I had assumed that I could run Approval within the context of another workflow then change program flow based on the results. Is this incorrect?

Here's some pseudo code:

`start Approval process with Person1
if CurrentItem:ApprovalStatus is Approved:
DO SOMETHING OR CHECK SOME VALUE
start Approval process with Person2
if CurrentItem:ApprovalStatus is Approved:
DO SOMETHING OR CHECK SOME VALUE
fi
fi'

I identified the "start X process" activity as something close to running a subroutine. Is that not the case? Or is early termination just a side effect of the Approval process?

A: 

Workflows cannot be directly dependent on each other like this. The best you can hope for is to have the dependent workflow loop and poll for a status change in the other WF.

-Oisin

x0n