Hello,
first sorry for my english, i'm french...
I made a form pdf fill. He ends by a button "register". in the pdf 3 fields are compulsory: email, function, activite.
When the person stopped filling the form, she clicks the button to register and, if the 3 fields are filled, we have directly a popup to register.
If one or several fields are not filled, we have a popup: by ex: required email.
Click OK and the pop up closes.
What I do not manage to find, it is how to connect the 2 actions.
because, once popups required mail is closed, the popup to register opening before the required mail is filled.
I wish that we can register the pdf ONLY when the required areas are filled.
I put on my button: action, mouse down, launch a script:
if (getField("email").value == ""){ app.alert("email requis !");
} else { eformpdf_submitForm();
} if (getField("fonction").value == ""){ app.alert("intitulé de fonction requis !");
} else { eformpdf_submitForm();
} if (getField("secteur").value == ""){ app.alert("secteur activité requis !");
} else { eformpdf_submitForm();
}
Then = > 2nd line, execute a command) of menu: file to register under.
I think that it can be possible to replay the 2nd line only if the required areas are filled but i don't know how...
Thank you in advance to everyone who can help me.
Laurence
var submit = true;
if (getField("email").value == ""){
app.alert("email requis !");
submit = false;
}
if (getField("fonction").value == ""){
app.alert("intitulé de fonction requis !");
submit = false;
}
if (getField("secteur").value == ""){
app.alert("secteur activité requis !");
submit = false;
}
if (submit) eformpdf_submitForm();
- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com