task_parentid
Previous Topic  Next Topic 

Synopsis:

        task_id=task_parentid()

Arguments:

     none

Description:    This function returns the ID of the task that started this task through a call to task_spawn(), task_exec() or task_chain().       This can be useful for example if a child task needs to communicate with the parent task using Telecom Engine inter-task messaging.


If there is no parent task either because the task was started by the TEX.EXE run-time program or the parent task has stopped or been killed then this function will return -1


Return value:


Either the task ID of the parent task or -1 if there is no parent task or the parent task has stopped or been killed.