Skip to main content
Version: 7.9

Pause, Resume, and Cancel

Inductive University

Pause, Resume, and Cancel

Watch the video

How to Pause, Resume, and Cancel a Chart

This page details manual state changes that can be enacted on a Chart after it has started. These state changes can be triggered via scripting (usings some of the system.sfc functions listed on this page), or via the SFC Monitor component.

Security Considerations

Charts can run silently on the Gateway, but being able to interact with the chart from a Client (ie: pausing a Chart) can be useful. Since a Chart can be executing some critical process, we highly recommend utilizing security settings to restrict access to components that are able to modify the state of a Chart.

State Changes - Scripting

Pausing and Resuming

Any running Chart can be paused by using the system.sfc.pauseChart function. When pausing a chart, any currently executing action steps must finish before the Chart will transition to a paused state. As a result, it may take some time before the Chart fully transitions into the Paused state.

Once the chart is paused, it can then later be resumed. This can be done using the Resume button in the chart control when testing the SFC Monitor Component, or using the system.sfc.resumeChart function.

Canceling

Canceling a chart works similarly to pausing a chart in that it must first wait for any currently running action steps to finish execution before the chart will cancel. A chart can be canceled from a script by using system.sfc.cancelChart. Normal rules for canceling apply, thus the Chart's On Cancel event will trigger, but not the On Stop event.

State Changes - SFC Monitor Component

Changing the state of a Chart can easily be accomplished without scripting from the SFC Monitor component. From the Client you can simply right-click on a running chart, and click the state you wish the Chart to transition to.

Note that the Chart Lifecycle is still in effect, so only charts in a Paused state may be resumed.

" "