All templates
Flow ControlAdvanced
Use Labels to Check if File Exists
Robomotion•Updated 9 months ago

Overview
Uses Label and GoTo to structure a loop that rechecks file existence — a non-sequential flow pattern useful for polling.
Use Labels to Check if File Exists
Although flows run sequentially by default, transferring the running point is essential for many automation scenarios. Labels act like anchors and allow users to jump to them from anywhere in the flow.
What Use Labels to Check if File Exists can do
- Input Dialog titled
Check if file exists, messagePlease populate a file name to check if it exists in your desktop folder., defaultFileName->msg.user_input. - Branch on cancel (
Core.Programming.Function,outputs: 2) — empty input short-circuits toCore.Flow.Stop. - Build path (
Core.Programming.Function) —msg.candidate_path = global.get('$Home$') + '\Desktop\' + msg.user_input. Core.FileSystem.PathExistsonmsg.candidate_path->msg.exists.- Branch on existence (
Core.Programming.Function,outputs: 2) — true goes toCore.Flow.GoToFile_Exists, false toCore.Flow.GoToFile_Does_Not_Exist. File_Existslabel -> buildmsg.dialog_text = "Filename: '<name>' exists in your desktop folder."->Core.Dialog.MessageBoxtitledFile found!->Core.Flow.Stop.File_Does_Not_Existlabel -> buildmsg.dialog_text = "Filename: '<name>' doesn't exist in your desktop folder."->Core.Dialog.MessageBoxtitledFile not found!->Core.Flow.Stop.
Behind the scenes
- This is functionally identical to
use-conditionals-to-check-if-file-exists; the flow teaches Label + GoTo as an alternative to inlineIF/ELSE. Keep the label nodes prominent — they are the teaching point, not incidental. - Because
Core.Flow.GoTois terminal, the Designer layout is two parallel label-rooted chains; the main chain up to the GoTo is one sub-graph, and each label + MessageBox + Stop is its own disconnected chain that the GoTo jumps into.
More flow control templates
See all 7 →- Denial Worklist TriageWorks a clinic's denied insurance claims, choosing a different action for each denial code: fix and resubmit the ones missing a field the chart already has, write off what the payer will never cover, void duplicates of already-paid claims, and escalate the ones that need a human to call the payer. Waits for the resubmitted claims to be re-adjudicated, then reads each claim's real status back off the table and writes denial-actions.csv.
- Leave Request PolicingProcesses the pending leave requests in an HR system by policy: approves the ones that are clean and denies the ones that break a rule - an insufficient balance, an overlap with a teammate already off, or a request inside the month-end blackout - writing the reason into the required comment box. Brings only the edge cases to a human. Writes a decision CSV.
- Use Conditionals to Check if File ExistsChecks whether a given file is present on disk and routes the flow accordingly. A textbook conditional branching example.
- Use Subflows to Check if File ExistsEncapsulates a "does this file exist?" check inside a reusable subflow so the main flow stays linear and readable.
- Use the AND Operator in ConditionalsShows how to branch a flow only when two conditions are both true using a Switch node with a combined predicate.
- Use the OR Operator in ConditionalsCombines two conditions with a logical OR and branches the flow based on the result. Complements the AND-operator variant.