I need to stop people from printing the form. The whole purpose of having the electronic form is to save paper. People are printing multiple copies and we don't want them to do it. I may need the capability of printing at some point, so I tried a script I found in the forum...but it's not working. Basically, I have a field that I want a specific value typed in, like a password. If that is correct, they should be able to print the form. Here is the code I used:
form1.Page1.Password::prePrint - (JavaScript, client)
if (this.rawValue != "xxx333")
{
app.alert("You cannot print this form. See Greg or Denise for questions.");
xfa.event.cancelAction = true;
}
else
{
xfa.host.print();
}
In this case, it will pop up the box telling them they can't print if they don't type xxx333 into the text field. However, it still pops up the print box after that, so they can still print. I was hoping the cancelAction script would take care of that, but it doesn't seem to do that. Is there a way to get this to work?
Thanks in advance,
Rose.