Conroe ISD Knowledge Base

Page 6: Field Rules & Lookup Rules

Laserfiche Forms provides two powerful automation engines within the Form Designer to create dynamic, responsive forms: Field Rules (for dynamic visual/form behavior) and Lookup Rules (for dynamic database/data integration).

⚡ 1. Field Rules

Field Rules dynamically alter the behavior, visibility, and requirements of form fields based on user input or field selections.

⚙️ Supported Rule Actions

When specified conditions are met (IF), Field Rules can trigger the following actions (THEN):

Action

Details

Show / Hide:

Displays or conceals fields or entire sections.

Require / Optional:

Dynamically toggles mandatory input validation.

Read-Only / Editable:

Locks fields to prevent modifications or unlocks them for input.

Enable / Disable:

Activates or grays out actionable fields.

Skip to Page:

Redirects users to a specific page in multi-page forms based on their selections.

🔧 How to Configure a Field Rule

  1. Open your form in the Form Designer and click the Rules tab in the top navigation bar.

  2. Select Field Rules from the left pane and click + Add Rule.

  3. Set a descriptive Rule Name (e.g., Show IT Hardware Options).

  4. Define the Condition (IF):

    • Select a target field variable (e.g., varDepartmentType).

    • Select an operator (equals, contains, is filled, is greater than, etc.).

    • Specify the comparison value (e.g., IT).

  5. Define the Action (THEN):

    • Select the action (e.g., Show).

    • Select the target field(s) or section(s) (e.g., varRequestedHardware).

  6. (Optional) Toggle Else logic to automatically reverse the action when conditions are not met.

EXAMPLE RULE LOGIC:
IF varDepartmentType == "IT"
THEN Show varRequestedHardware AND Require varRequestedHardware
ELSE Hide varRequestedHardware AND Make Optional varRequestedHardware

⚠️ Best Practice: Avoid creating conflicting field rules where two separate rules attempt to control the same field simultaneously (e.g., Rule A shows a field while Rule B hides it).

Also, you can apply field rules by simply click on any Field within your form and follow these instructions

  1. Click on Rules on the right panel

  2. Click on Field Rules

  3. Click the +Add Rule button

  4. Set the Field rules explained above

🔍 2. Lookup Rules

Lookup Rules auto-populate form fields by querying external SQL databases, internal data tables, or web services based on a trigger field entered by the user.

💡 Common Use Cases

Use Case

Description

Autofilling employee information

Autofilling employee information (First Name, Department, Manager) after an Employee ID is typed.

Populating dropdown choices

Populating dropdown choices dynamically based on a prior selection (e.g., selecting State populates City).

Querying dynamic data

Querying dynamic inventory rates or budget codes in real time.

🔖 How to Configure a Lookup Rule

  1. Open the form in the Form Designer and select the Rules tab.

  2. Select Lookup Rules from the left pane and click + Add Rule.

  3. Name your lookup rule (e.g., Lookup Employee Details).

  4. Select Data Source: Choose your configured database connection and specify the target database view/table.

    1. The main Data Source used for Forms is LF_CustomTables

    2. If you need a table/view built, please reach out to twolf@conroeisd.net and explain what columns you need for the table/view.

  5. Configure Trigger & Input Parameters (Lookup Criteria):

    • Select the form variable that triggers the lookup (e.g., when varEmployeeID changes).

    • Map the form variable to the database column (e.g., DB_Employee_ID = varEmployeeID).

  6. Configure Output Parameters (Fill Fields):

    • Map database result columns to the target form variables:

Database Column

Form Variable

DB_First_Name

varFirstName

DB_Last_Name

varLastName

DB_Email

varEmailAddress

DB_Department

varDepartment

Also, you can apply lookup rules by simply click on any Field within your form and follow these instructions

  1. Click on Rules on the right panel

  2. Click on Lookup Rules

  3. Click the +Add Rule button

  4. Set the Lookup rules as explained above

🗂 Table & Collection Lookups

Lookup rules can also populate entire Tables or Collections in a single execution:

Type

Details

Single-Row Lookups:

Fill standard individual fields.

Multi-Row Lookups:

Query a dataset returning multiple records and dynamically generate new rows in a form Table or Collection (e.g., pulling all open tasks assigned to a selected project).

💡 Pro-Tip: Always index your lookup columns in the underlying SQL database to ensure fast form performance when running lookups against large datasets.