top of page

Bypass Required Fields by Capturing Action Button Values

Updated: 8 hours ago

Introduction: Sometimes you need to submit a form without filling in all the required fields—like when rejecting a form or quickly testing submission logic. By capturing which action button was clicked, you can conditionally bypass required fields for specific actions, such as Reject or Test Submit, while keeping validation intact for normal submissions. This approach gives you flexibility without breaking the form’s overall validation rules.


Test Version: Laserfiche Forms Professional Version 12.0.2503.10378


Code Provided by: Matthew Tingy with American United Federal Credit Union


Setup: Download codes from Bait and Tackle.


Capture Action Button Value and Bypass Required Fields - Modern Designer


1. Add a Single Line field to your form.

This field will store the Action Button value after a user clicks a form action button.


2. Configure Field Rules to manage required fields.

Create a Field Rule that sets your required fields to Optional when the Single Line field’s value is not blank.

This allows the script to bypass required-field validation when a specific action button is clicked.


3. Open the form’s JavaScript editor.

In Laserfiche Forms Modern Designer, click the JS tab in the upper-right corner.


4. Insert the Day 2 script from the Bait and Tackle library.


5. Update the field IDs in the script to match your form.

Replace any placeholder IDs in the provided script with the actual ID of:


  • the Single Line field that stores the Action Button value


  • any fields referenced in your Field Rule logic


This ensures the script binds to the correct form elements.


Pro Tip:

When using multiple action buttons, configure each button to write a specific, unique string into the Single Line field.

This makes it easier to create conditional logic and accurately detect which button was clicked.







© 2024 by SchoolOfFiche. All rights reserved.

Follow Me

  • Twitter
  • LinkedIn
bottom of page