All templates
Desktop AutomationBeginner
Open a Folder
Robomotion•Updated 11 months ago

Overview
Launches the system file explorer pointed at a given path. Minimal template demonstrating the Application.Launch node.
Open a Folder
Interacting with the file system is essential in most home and business automation scenarios. Using Robomotion, you can automatically open specific folders in File Explorer and directly interact with their content.
What Open a Folder can do
- Build Documents Path (
Core.Programming.Function) — setsmsg.documents_folder_pathto<$Home$>\Documents. - Input Dialog titled
Open a folder, messageSelect the folder to open..., defaultmsg.documents_folder_path→msg.selected_folder. - Branch On Cancel (
Core.Programming.Function,outputs: 2) — routes toCore.Flow.Stopwhenmsg.selected_folderis empty/whitespace. - Build Args (
Core.Programming.Function) — setsmsg.explorer_args = [msg.selected_folder]. - Launch Explorer (
Core.Process.StartProcess,optBackground: true,continueOnError: true) —inFilePath: explorer.exe,inArguments: msg.explorer_args→msg.app_process_id, thenCore.Flow.Stop.
Behind the scenes
explorer.exeis launched with the folder path as its sole argument, so Windows opens a new File Explorer window rooted at that folder.continueOnError: truekeeps the flow from aborting if the path is invalid or explorer is unavailable; the flow simply falls through toCore.Flow.Stop.- To port to Linux/macOS, swap
explorer.exeforxdg-open/openand dropmsg.app_process_id— those shells typically exit immediately after dispatching to the desktop environment.
More desktop automation templates
See all 17 →- Every customer from a CSVThe Windows Recorder's customer task run for every row of a CSV file, each typed value replaced by the row's field, with a Catch that logs a row the app will not take and goes on with the next.
- Putting it togetherOne flow over three systems. Headless Chrome reads today's web orders from Acme ERP Web, the finance system is asked about each customer over Remote Desktop, and the orders with nothing overdue are entered into Acme ERP for Windows, line by line, with a report at the end.
- Reading from a Java applicationA flow that signs in to Acme ERP (Java Edition), reads a customer's credit limit and the fasteners in the product table, works out how many boxes of each the limit covers, and writes the answer to a CSV file.
- Reading over Remote DesktopA flow that logs on to Acme ERP over Remote Desktop, reads the outstanding and overdue totals off the Invoices screen with OCR, each anchored to its label, and writes the overdue share to a CSV file.
- Slow sessionsA flow recorded on a good Remote Desktop session that logs on and updates a customer's email, phone and notes in Acme ERP, and still gets every value right on a slow session that loses keystrokes.
- Windows dialogs and gridsA flow that signs in to Acme ERP for Windows, waits for its orders grid, reads it with Get Table Data, exports the orders on hold through the Save As dialog, and closes the app answering its "Save changes?" question.