I have a form which has several checkboxes. A couple of them requires a date field to be entered in a box next to it. If the user checks the box which has a date field box next to it, I want the form to do the following:
2. Stop the user from sending the form via email, printing the form and saving the form if the date is not entered in the box.
If you use this PDF in Adobe Reader you will need to have Reader Extensions applied either by using Acrobat Pro or AEM Forms server software - otherwise it will not allow to submit the entered data.
The logic I showed you will only change the state of the field from non-mandatory to mandatory and back and must be in the change event of the check-box - I realized that I did not mention that.
The Send as Email functionality of Reader will also heed the mandatory state of the fields (if they are mandatory) - there should not be a difference to using the Email Submit button.If your logic fails to make a mandatory field mandatory then it is no surprise that it will send the E-Mail right away.