Skip to main content
Participant
February 23, 2022
Question

Form fields aren't visible

  • February 23, 2022
  • 5 replies
  • 1752 views

I'm working with a fillable form that I created in Acrobat on a PC. Some fields are text, some are drop-down lists. All the data was entered on an ipad in Adobe Reader and the each file was copied back to the PC for further editing. Now that I have the forms open in Acrobat again, data in some fields isn't visible. I've probably tried half a dozen solutions to this problem, but nothing has worked.

This topic has been closed for replies.

5 replies

JR Boulay
Community Expert
Community Expert
February 24, 2022

"when a form is filled in using Mac Preview, then the data isn't visible until you click on the field. The workaround for this is:"

Use this script in the JavaScript Console or in an Action, it works fine:

 

/*
Folder-level JavaScript file: Preview_fix.js
Purpose: Correct field appearances corrupted by the Preview application on the Mac
Author: George Johnson, acroscript@gmail.com, inspired by a similar script by Joel Geraci
Version: 1.0.0
Date last edited: 2010/12/18
Compatible with Acrobat/Reader 6-10
*/

// Create namespace to prevent potential name conflicts
var COM_ACROSCRIPT = {};

// This function does the work
COM_ACROSCRIPT.correctFieldAppearances = function (doc) {

var i, j,
f_name, f, fp, nWidgets, fw, cc,
c1 = color.blue, c2 = color.yellow; // These can be any color, as long as they are different

// Suspend redrawing field appearances until the end of this script
doc.delay = true;

// Loop through all of the fields in the document
for (i = 0; i < doc.numFields; i += 1) {

// Get the name of the current field
f_name = doc.getNthFieldName(i);

// Get a reference to the current field
f = doc.getField(f_name);

switch (f.type) {

case "button" : break; // No need to process buttons
case "signature" : break; // Digital signatures will not be present if saved with Preview

default : // text, checkbox, radiobutton, combobox, listbox

// Get the page numbers on which the current field's widgets reside
// typeof = number (for single widget) or object (array, more than one widget with the same name)
fp = doc.getField(f_name).page;

// Determine the number of widgets for the current field
nWidgets = (typeof fp === "number") ? 1 : fp.length;

// Loop through the current field's widgets
for (j = 0; j < nWidgets; j += 1) {

// Get a reference to the current widget
fw = doc.getField(f_name + "." + j);

// Save the current widget's border color
cc = fw.strokeColor;

// Set the current widget's stroke color to a temporary color,
// either c1 or c2. Choose c2 if the current color equals c1
fw.strokeColor = color.equal(cc, c1) ? c2 : c1;

// Set the widget stroke color back to the original border color
fw.strokeColor = cc;
}

break;
}
}

// Allow Acrobat/Reader to redraw the field appearances
doc.delay = false;

app.alert("All fields have been processed.", 3, 0);
} // That's all, folks!

COM_ACROSCRIPT.correctFieldAppearances(this);

Acrobate du PDF, InDesigner et Photoshopographe
JR Boulay
Community Expert
Community Expert
February 24, 2022

"Sadly we can't control which program a client uses when they fill a form in"

Of course you can, see this tuto (copy-paste this URL in Google Translate if you can't read French):

https://www.abracadabrapdf.net/ressources-et-tutos/js-et-formulaires-ressources/forcer-utilisation-pdf-avec-acrobat-reader/

 

Acrobate du PDF, InDesigner et Photoshopographe
Inspiring
February 23, 2022

Might be related but I've found that when a form is filled in using Mac Preview, then the data isn't visible until you click on the field. The workaround for this is to give a background colour to each field (I use white) making sure that the Transparent checkbox is ticked. It's a bit of a pain having to do this on a multiple page form but you can do all fields on one page in one go. Hope that may help. AMP

try67
Community Expert
Community Expert
February 23, 2022

The workaround is to export the form data to an FDF file and then import it back into the file.

The solution is not to use Apple Preview, which is known to be very buggy and to corrupt PDF form fields, just by opening the file.

Inspiring
February 23, 2022

Sadly we can't control which program a client uses when they fill a form in ☹

try67
Community Expert
Community Expert
February 23, 2022

How (and where) were the fields filled in?

jgrcdAuthor
Participant
February 23, 2022

The form is a datasheet for field work, and the data was entered using Adobe Acrobat Reader on an ipad.

Bernd Alheit
Community Expert
Community Expert
February 23, 2022

Can you see the data when you click in the fields?

jgrcdAuthor
Participant
February 23, 2022

No, but I know data was entered there. For the fields with drop-down lists, the lists no longer drop down when I click on them, but I can use the arrows to scroll through them. If I do that my selection disappears as soon as I leave the field, but if I type in the selection it stays visible.