Jump to content

restrict form from submission

Recommended Posts

Hello ,

I am using a javascript that should restrict me from submitting form based on condition.

I have field Start date and field End Date.

Then I am using a virtual calculated field to find number of days from the above two fields. Now if my value is greater than 5 it should restrict me to submit the form



  document.addEventListener('BeforeFormSubmit', function(event) {

     let checkValue = document.getElementById("cbParamVirtual3").value;
     if (checkValue > 5) {
     alert("You are not authorized to create this account.");


Ca anybody please help

Link to comment
Share on other sites

  • 1 month later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...