Type Text
Types text into the active window.
Common Properties
- Name - The custom name of the node.
- Color - The custom color of the node.
- Delay Before (sec) - Waits in seconds before executing the node.
- Delay After (sec) - Waits in seconds after executing node.
- Continue On Error - Automation will continue regardless of any error. The default value is false.
If ContinueOnError property is true, no error is caught when the project is executed even if Catch node is used.
Input
- Text - The text to be typed into the active window
Options
- Characters per Minute - The typing speed in the number of characters per minute. (Default is 945, Range: 0-1000)
- Press Enter - If true, the 'Enter' key is pressed after the text is typed.
How It Works
The Type Text node simulates human-like typing by entering text character by character into the currently active window. The execution follows these steps:
- Delay Before - Waits for the specified delay before execution (if configured)
- Text Retrieval - Retrieves the text value from the input (can be a variable or direct value)
- CPM Validation - Validates that the Characters Per Minute value is between 0 and 1000
- Delay Calculation - Calculates the delay between characters based on CPM (60 seconds / CPM)
- Character-by-Character Typing - Types each character with the calculated delay using the robotgo library
- Enter Key Press - If "Press Enter" is enabled, presses the Enter key after typing
- Delay After - Waits for the specified delay after execution (if configured)
The typing speed can be controlled dynamically using variables, allowing for adaptive typing speeds based on automation context.
Requirements
- Robomotion Deskbot - This node only works with Robomotion Deskbot (desktop automation)
- Active Window - The target window/application must be active and in focus to receive the typed text
- Text Input Field - The cursor must be positioned in a text input field or text-accepting area
- Operating System Support - Compatible with Windows, macOS, and Linux
- Permissions - May require accessibility permissions on macOS and some Linux distributions
Error Handling
| Error Code | Description | Common Cause |
|---|---|---|
Core.Desktop.Keyboard.ErrOnCreate | Configuration parse error | Invalid node configuration or corrupted flow |
Core.Desktop.Keyboard.ErrOnMessage | Message parse error | Invalid input message format |
Core.Desktop.Keyboard.ErrTypeText | CPM validation error | Characters Per Minute value is outside the valid range (0-1000) |
Usage Examples
Example 1: Fill Login Username
Type a username into a login form:
Text: john.doe@example.com
Characters per Minute: 600
Press Enter: false
This will type the email address at a moderate speed without pressing Enter, allowing you to tab to the password field.
Example 2: Submit Search Query
Type a search query and submit:
Text: {{searchTerm}}
Characters per Minute: 945
Press Enter: true
This will type the search term from a variable at maximum speed and press Enter to submit the search.
Example 3: Slow Typing for Autocomplete
Type slowly to trigger autocomplete suggestions:
Text: New York City
Characters per Minute: 120
Press Enter: false
Slower typing (120 CPM) gives time for autocomplete dropdowns to appear between characters.
Example 4: Fill Multi-line Text
Type multi-line text into a text area:
Text: Line 1
Line 2
Line 3
Characters per Minute: 500
Press Enter: false
The text will be typed exactly as provided, including line breaks.
Usage Notes
- CPM Range - Valid range is 0-1000 characters per minute. Values outside this range will cause an error
- Default Speed - The default of 945 CPM is very fast and suitable for most automation scenarios
- Human-like Speed - For realistic human simulation, use 200-400 CPM
- Variable Support - Since version 24.1.5, CPM can be set dynamically using variables
- Special Characters - All characters including newlines, tabs, and special symbols are supported
- Empty Text - If the text input is empty, the node will complete without typing anything
- Clipboard Alternative - For very long text, consider using clipboard paste (Ctrl+V) instead for better performance
Tips
- Focus First - Always ensure the target input field is focused before typing (use Mouse Click node if needed)
- Speed Selection - Use faster speeds (800-945 CPM) for form filling, slower speeds (200-400 CPM) for human simulation
- Autocomplete Handling - Reduce CPM to 100-200 when working with fields that have autocomplete to allow time for suggestions
- Error Recovery - Enable "Continue On Error" when typing into potentially unstable UI elements
- Dynamic Text - Use variables for the Text input to make your automation flexible and reusable
- Enter Key - Enable "Press Enter" for single-field forms or search boxes to auto-submit
- Delay Before - Add a delay before typing if the target application needs time to initialize the input field
Related Nodes
- Send Keys - For sending keyboard shortcuts and special keys
- Mouse Click - For clicking input fields to focus them before typing
- Application In - For launching applications before typing