Jump to content

Search the Community

Showing results for tags 'js submission form fail'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Caspio Bridge
    • General Questions
    • Caspio JavaScript Solutions
    • Tables, Views and Relationships
    • Import/Export and DataHub
    • DataPages
    • Deployment
    • Security, Authentications, Roles, SAML
    • Styles and Localizations
    • Parameters
    • API and Integration
    • Calculations and aggregations
    • User JavaScript and CSS Discussions

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start




Website URL






Found 1 result

  1. I have two blocks of JavaScript placed in the bottom most HTML section of a Submission Form. These are required to reprocess rules on this page if a user makes any changes to either the Parent, WC_MFG, or Secondary,WC_MOD_OPT, fields of the Cascading Elements on this form. All is well and performs as needed and expected. The issue arises when a change event is firing during a failed form submission and I don't believe it should. During a successful form submission all works perfectly. The failed submission we have observed, is when a required field is forgotten and the Submit button is clicked. The secondary field, WC_MOD_OPT, on the cascading element seems to have a change event as the second section of my JavaScript executes and resets the fields when it should not, there have been no user updates to any of the data. I have debugged this using the console as noted in the script. I also have created a Calculated Value using Case When and it results in the same scenario. Current JavaScript located in the final HTML Block on the Form just before the Footer: <script> document.getElementsByName("InsertRecordWC_MFG")[0].addEventListener("change", function() { console.log("I changed the manufacturer!"); document.getElementsByName("InsertRecordDRBI_YN")[0].value = "No"; document.getElementsByName("InsertRecordFR_YN")[0].value = "No"; document.getElementsByName("InsertRecordPERMIT_SUBMIT")[0].value = ""; }); document.getElementsByName("InsertRecordWC_MOD_OPT")[0].addEventListener("change", function() { console.log("I changed the model!"); document.getElementsByName("InsertRecordDRBI_YN")[0].value = "No"; document.getElementsByName("InsertRecordFR_YN")[0].value = "No"; document.getElementsByName("InsertRecordPERMIT_SUBMIT")[0].value = ""; }); </script> I would like to know if there is an event I could capture while the form submission fails due to required fields? I could then attempt to catch this and handle this exception but have no idea what it might be or if it even exists.
  • Create New...