Cicode Programming Reference > Performing Advanced Tasks > Controlling Tasks

Controlling Tasks

You can use the Task functions to control the execution of Cicode tasks, and use the Citect SCADA Kernel at runtime to monitor the tasks that are executing. Since Citect SCADA automatically creates new tasks (whenever you call a keyboard command, etc.), schedules them, and destroys them when they are finished, users rarely need to consider these activities in detail.

Sometimes it is desirable to manually 'spawn' a new task. For example, suppose your Cicode is polling an I/O Device (an operation which need to be continuous), but a situation arises that requires operator input. To display a form would temporarily halt the polling. Instead you can spawn a new task to get the operator input, while the original task continues polling the device.

Note: The TaskNew Cicode function is used to spawn new tasks.

See Also

Published June 2018