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

Importing JavaScript variable data

New Here ,
Jul 31, 2020 Jul 31, 2020

Copy link to clipboard

Copied

Currently I have quite a bit of data in my JavaScript and would like to tidy this up a bit and maintain it through maybe a spreadsheet. If there anyway to import this data into my PDF's without keeping it in the JavaScript? The data does change depending on variables within the PDF so I'm not sure how that would work with this. For example if x is written in this box, the value in another box would be Blue, if y is written the value should be Red.

 

Any suggestions?

TOPICS
PDF forms

Views

284

Translate

Translate

Report

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
Community Expert ,
Jul 31, 2020 Jul 31, 2020

Copy link to clipboard

Copied

LATEST

It's possible to use an external data source and then read it using a script, parse it and use the values from it later on.

The file has to be in a known location and must be a plain-text file, though, for the script to be able to read it.

You can use the util.readFileIntoStream method for reading the file, for example.

Votes

Translate

Translate

Report

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