These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Maintaining protection on submitted dynamic form

Runolfr
Registered: Oct 1 2008
Posts: 119

I have several forms that use the following code to protect fields, so the recipient can't modify what comes through:

for (var nPageCount = 0; nPageCount < xfa.host.numPages; nPageCount++)
{
var oFields = xfa.layout.pageContent(nPageCount, "field");
var nNodesLength = oFields.length;
// Set the field property.
for (var nNodeCount = 0; nNodeCount < nNodesLength; nNodeCount++)
{
oFields.item(nNodeCount).access = "protected";
}
}

I just changed one of these from a Static PDF form to a Dynamic XML form, and the sent file is no longer protected. Is there something else I need to do, or is it not possible that way?

scienceskillz
Registered: May 2 2010
Posts: 8
Hi,

I have the same problem. Did you ever figure this out?
klwalsh611
Registered: Sep 10 2009
Posts: 28
Runolfr - where do you insert this code?
scienceskillz
Registered: May 2 2010
Posts: 8
I have my code under the save button click event. I then envoke the menu item saveAs which opens up a dialog asking user to save. My problem is that when another user on another computer opens the saved form up to field reverts back to a default setting and is no longer protected or readOnly.
klwalsh611
Registered: Sep 10 2009
Posts: 28
i'll try inserting it into my send button. thanks!