Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Export Specific Fields

New Here ,
Sep 20, 2016 Sep 20, 2016

I'm using the Merge Data Files Into Spreadsheet tool to create a CSV File, and it works great for what I need, but I was wondering if there was a way to choose with fields to export. I need all the information for the PDF but not all of it is necessary for a condensed file I also need to create.

TOPICS
Acrobat SDK and JavaScript , Windows
417
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Sep 20, 2016 Sep 20, 2016

It is, but there's not a built-in feature for this, so you'd have to use a custom JavaScript. I'd recommend tab-delimited over CSV as they are significantly easier to generate correctly. Here's a simple script that writes tab-delimited data to the JavaScript console (Ctrl+J), which you can then copy & paste into a file.

// List of fields to export

var aF = ["text1", "text2", "checkbox4", "dropdown6"];

// Loop through array of fields and add field values to array

var aValues = [];

for (var i = 0; i <

...
Translate
LEGEND ,
Sep 20, 2016 Sep 20, 2016
LATEST

It is, but there's not a built-in feature for this, so you'd have to use a custom JavaScript. I'd recommend tab-delimited over CSV as they are significantly easier to generate correctly. Here's a simple script that writes tab-delimited data to the JavaScript console (Ctrl+J), which you can then copy & paste into a file.

// List of fields to export

var aF = ["text1", "text2", "checkbox4", "dropdown6"];

// Loop through array of fields and add field values to array

var aValues = [];

for (var i = 0; i < aF.length; i += 1) {

    aValues.push(getField(aF).valueAsString);

}

// Write tab-delimited data to console

console.println(aValues.join("\t"));

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines