Variables
Add dynamic content to your templates with variables — the building blocks of document automation.
Variables
Variables are dynamic placeholders in your document that get replaced with real data when someone fills the form. They're the core building block of document automation in Crove.
Adding a variable
- Place your cursor where you want the variable to appear
- Click the Variable button in the toolbar
- Enter a name for the variable (e.g., "Client Name")
- Select the variable type
- The variable appears as a highlighted tag in your document
Variables appear inline in your text, like this:
Dear {{Client Name}},
Thank you for your order of {{Quantity}} units of {{Product Name}}
at {{Unit Price}} each. Your total is {{Total Amount}}.Variable types
Choose the right type for each variable to get proper form fields and validation:
Text
Single-line text input. Use for names, addresses, titles, and short text.
Sub-types available:
- Email — Validates email format
- Phone — Phone number formatting
- URL — Validates web address format
Text Area
Multi-line text input. Use for descriptions, comments, notes, and longer content.
Number
Numeric input with optional decimal places. Use for amounts, quantities, percentages.
Date
Date picker field. Use for deadlines, start dates, birthdates.
Dropdown
Single-select from a predefined list. Use for categories, countries, status.
Configure options in the form builder:
Options: ["Option A", "Option B", "Option C"]Multi-Select
Choose multiple options from a list. Use for skills, services, features.
Checkbox
Simple yes/no toggle. Use for consent, opt-ins, boolean flags.
Radio
Choose one option from visible buttons. Use when there are 2-5 options and you want all visible.
File Upload
Allow the respondent to upload files. Use for ID documents, certificates, photos.
Signature
Captures an e-signature. Respondents can draw, type, or upload their signature. See E-Signatures for details.
Computed
Auto-calculated from other variables using JEXL expressions. See Expressions.
Variable properties
Each variable has configurable properties:
| Property | Description |
|---|---|
| Name | Display name shown in the form and document |
| Type | Data type (text, number, date, etc.) |
| Required | Whether the field must be filled |
| Default value | Pre-filled value |
| Placeholder | Hint text shown in the empty field |
| Help text | Description shown below the field |
| Validation | Rules like min/max length, pattern, min/max value |
| Role | Which respondent role fills this variable |
Variable validation
Add validation rules to ensure data quality:
| Rule | Applies to | Example |
|---|---|---|
| Required | All types | Field cannot be left empty |
| Min length | Text, Text Area | Minimum 3 characters |
| Max length | Text, Text Area | Maximum 100 characters |
| Min value | Number | Must be at least 0 |
| Max value | Number | Cannot exceed 1,000,000 |
| Pattern | Text | Custom regex pattern |
Assigning variables to roles
In multi-party documents, different people fill different fields. Assign each variable to a role to control who fills it:
- Create roles in the template settings (e.g., "Sales Rep", "Client")
- Assign each variable to a role
- When the document is sent, each recipient only sees the fields assigned to their role
Role: Sales Rep
- Company Name
- Unit Price
- Payment Terms
Role: Client
- Client Name
- Client Address
- Client SignatureVariable usage tracking
Crove tracks where each variable is used in your document. If you try to delete a variable that's still referenced in the document or form, you'll be warned. Remove all references first, then delete the variable.
Best practices
- Use descriptive names — "Client Full Name" is better than "name1"
- Choose the right type — Use Number for amounts (enables calculations), Date for dates (enables date formatting)
- Set validation — Required fields and format validation prevent incomplete submissions
- Group by role — Organize variables by who fills them for cleaner multi-party workflows
- Use defaults — Pre-fill common values to speed up form completion