Administer > Workflows > WaitForChild Block Does Not Execute

WaitForChild Block Does Not Execute

Sometimes it appears that the WaitForChild workflow block does not execute. This can happen if a child business object does not meet the needed criteria.

For example, if you have created a workflow called Wait Until All Tasks Completed, you would define the block to be in wait state until all tasks are set to completed, rejected, or canceled, at which time the workflow would continue.

However, the WaitForChild block also waits for any child objects included.

For example, say your WaitForChild block is defined as follows:

Wait For Child Block Properties

Notice that the child object ChangeAssocTaskAssignment has been included. The block checks this relationship to see that it is in the necessary state before continuing.

However, if you manually create a task from the workspace using a relationship:

Manually Creating a Task Using a Relationship

... then the WaitForChild block fails to detect the new manually-created task and remains in the waiting status.

The moral

Both relationships need to be the same for the Wait For Child block to work.