Skip to main content

Graph automation reference

A Graph visually coordinates Objects, Queries, and Variables. Use it for multi-step automation with branches, waits, timeouts, and breakpoint validation.

When to use this page

  • You are unsure whether a requirement belongs in a Page method, Graph, or C# Script.
  • Node ports do not connect, or Build reports a type, reference, or parameter error.
  • You need a wait, timeout, operator confirmation, or error-recovery path.
  • Debug does not pause at the intended breakpoint, or you are unsure what to do after it pauses.
  • A change is saved, but the runtime still executes the old workflow.

Entry point and core objects

Create or open a Graph under Resources → Graphs. Drag an Object from the Object tree to create a call node, or use the canvas context menu to choose a node from the insert menu.

ObjectPurpose
MethodA callable Graph entry point; one Graph can have several methods
Control portExecution order, including the branch that follows a completed step
Value portA string, number, Boolean, object, or structured value passed between nodes
BreakpointA location where Debug pauses before the selected node
Graph VariableTemporary state owned by one Graph instance

After a Graph is bound to an Object, its methods extend that Object and can be called by a Page, another Graph, or the runtime lifecycle.

Node reference

NodePurpose
MethodDefine entry parameters, return values, and the first execution step
FunctionCall an Object or standard-library method
QueryCall an HTTP Query defined in App Settings
If / SwitchSelect a branch from a condition or value
ForeachProcess each item of a collection in order
ConcurrentRun several branches concurrently and continue after all finish
Get Variable / Set VariableRead or write a Graph, App, or Saved Variable
Wait UntilRecheck a condition with separate Success and Timeout outputs
ConfirmWait for an operator to confirm, cancel, or time out on a runtime page
SubgraphCall another Graph method on the same Object

A control port means “what runs next.” A value port means “where this input comes from.” Connected types must match. Set a default in node Properties when appropriate instead of forcing an incompatible connection.

When should you use a Graph?

RequirementRecommended location
One button calls one Object method and shows a messagePage Flow method
Multi-step equipment order, branch, wait, timeout, and recoveryGraph
Protocol, complex algorithm, or equipment capability missing from the standard libraryAn Object method in a C# Script, called by a Graph
Screen layout, display formatting, and navigationPage / Component

Wrap stable actions in domain-oriented Object methods such as Home or Read barcode. A Graph coordinates those capabilities and should not repeat low-level addresses or protocols.

Variable scope

ScopeDefined inLifetime
graphCurrent Graph propertiesIsolated per Graph instance; use for temporary workflow values
appApp Settings → VariablesShared across Pages and Graphs in the current loaded runtime; starts from its initial value after reload or redeployment
savedApp Settings → VariablesCurrent value is kept by the Runtime target across restarts

Choose an explicit scope and Variable in Get Variable or Set Variable. Do not use a Graph Variable for a parameter that must survive an App restart.

Waits, timeouts, and lifecycle

  • Every site wait needs an explicit completion condition and an acceptable timeout policy.
  • Connect Wait Until Success to the normal path and Timeout to alarm, retry, cancel, or safe stop. Do not leave Timeout unhandled when an infinite wait is unacceptable.
  • Confirm waits for a runtime-page response. When several clients are open, only the first valid response is applied.
  • Use Object-bound Init for startup preparation and Dispose for shutdown cleanup.
  • Update is part of the periodic scan path. Keep its work short and bounded. Put long waits or external I/O in asynchronous Object methods or an explicit state workflow.

Build and Debug

A saved Graph must produce valid build outputs. An explicit Build finds problems before startup. Start and Debug also prepare and deploy the current runtime package as needed.

Debug workflow:

  1. Set a Breakpoint on a node you need to observe.
  2. Confirm that the App is stopped and the correct Runtime target is selected.
  3. Select Debug.
  4. When the breakpoint is reached, the status becomes Paused and the Graph locates the current node.
  5. Inspect Variables, Object state, Problems, and Console, then choose Continue or Stop.
  6. Stop before changing the workflow. Paused still occupies the runtime and does not allow a new Build.

Key rules

  • A Graph owns workflow, not screen layout or device protocol.
  • Queries come from App Settings. Do not duplicate URLs, authentication, or request bodies inside a Graph.
  • Object, method, Variable, and Query references must resolve to real resources in the current App.
  • Every error, cancel, and timeout path needs an explicit result.
  • Theseus does not replace the live Object tree while the App is Running, Debugging, Paused, Starting, or Stopping.
  • Save success is not Build success, and Build success is not site acceptance.

How to validate

  1. After Save, check Problems for missing ports, type mismatches, and invalid references.
  2. Run Build and resolve every blocking diagnostic.
  3. Use Debug with simulated Objects or in a safe test environment first.
  4. Test the normal condition, False branch, Timeout, cancellation, and equipment error separately.
  5. Confirm that Pause, Continue, and Stop converge to the expected state.
  6. Perform a low-risk trial on real equipment only under the approved site test plan.