OK, here's working script.btnSaveAs::clickif (xfa.host.messageBox("Did you secure the document prior to saving it?", "WARNING",2,2) == 4) app.execMenuItem("SaveAs");
So, in your version, you rely on the ready::layout event. That should work well since you're using the built-in validate function.In my version the condition is just checking that there is something in a text field called tfSomething. I didn't know if you had set validation rules in you form. You'd ...
Would you be okay with multiple pages in a single form?Page1 = first formPage2 = Second formetc.Set each page to start on a new Page in the pagination tab, and it will look like individual forms. Then some simple coding logic to create some print buttons that only print certain forms.
Since each row has different information, I'll presume they are also named differently. Something like taxCollectorCustomerSatisfaction.tfMid and telephoneSurvey.tfMid for the first two rows. Whatever you called them, just make sure you're using the row name and cell name in your script.var t=0if (t...
Something like this, probably:if (xfa.host.messageBox("WARNING","Did you secure the document prior to saving it?",3,2) == 3) app.execMenuItem("SaveAs");
I like this. A reason to use the calculate event on a button!I'll let you work out how you would want to check the required fields (since I don't know how you set them up), but here's an example where we check for a field being empty. Multiple if statements could be used for the other required field...
I'm sure you could modify this for your purposes, but here's my solution with a checkbox instead of a button.So, if that box is checked when the form is saved, the text field will not generate a random number when the form is opened again.