How to use external data to fill in an existing PDF form in JavaScript?

Community Beginner ,
Apr 19, 2018

Copy link to clipboard

Copied

Hi all,

I've got a question which is : I have data from a database, now I need to use the data to fill in a PDF form?

To be more specific, for example, there are "name", "phone number" and "address" fields in my database, I want to catch these data to fill in an existing PDF form. The PDF form also has these three fields. I have no idea about how to implement in JavaScript. Really need some help.

Thank you so much for any suggestion.

Cheers,

Max

Adobe Community Professional
Correct answer by Karl Heinz Kremer | Adobe Community Professional

As was already suggested, you can export your data to a (tab separated) text file and then import that data into a form. If you can add some "glue" functionality to your database server, you might be able to do this with direct access from within a PDF form:

Connect to Database from PDF Form - This Time Without SOAP - KHKonsulting LLC

Getting a Serial Number Into a Form Using SOAP - KHKonsulting LLC

And, if you want to fill out more than one form at a time, take a look here:

Batch-Import Excel Data into PDF Forms - KHKonsulting LLC

Batch-Import List Data into PDF Form - KHKonsulting LLC 

TOPICS
Acrobat SDK and JavaScript, Macintosh, Windows

Views

2.3K

Likes

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

How to use external data to fill in an existing PDF form in JavaScript?

Community Beginner ,
Apr 19, 2018

Copy link to clipboard

Copied

Hi all,

I've got a question which is : I have data from a database, now I need to use the data to fill in a PDF form?

To be more specific, for example, there are "name", "phone number" and "address" fields in my database, I want to catch these data to fill in an existing PDF form. The PDF form also has these three fields. I have no idea about how to implement in JavaScript. Really need some help.

Thank you so much for any suggestion.

Cheers,

Max

Adobe Community Professional
Correct answer by Karl Heinz Kremer | Adobe Community Professional

As was already suggested, you can export your data to a (tab separated) text file and then import that data into a form. If you can add some "glue" functionality to your database server, you might be able to do this with direct access from within a PDF form:

Connect to Database from PDF Form - This Time Without SOAP - KHKonsulting LLC

Getting a Serial Number Into a Form Using SOAP - KHKonsulting LLC

And, if you want to fill out more than one form at a time, take a look here:

Batch-Import Excel Data into PDF Forms - KHKonsulting LLC

Batch-Import List Data into PDF Form - KHKonsulting LLC 

TOPICS
Acrobat SDK and JavaScript, Macintosh, Windows

Views

2.3K

Likes

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
Apr 19, 2018 0
Most Valuable Participant ,
Apr 20, 2018

Copy link to clipboard

Copied

You can't connect directly to a DB from an Acrobat PDF (any longer).

You would need to export the data into a plain-text file and then it would be possible.

Likes

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
Reply
Loading...
Apr 20, 2018 2
Adobe Community Professional ,
Apr 20, 2018

Copy link to clipboard

Copied

As was already suggested, you can export your data to a (tab separated) text file and then import that data into a form. If you can add some "glue" functionality to your database server, you might be able to do this with direct access from within a PDF form:

Connect to Database from PDF Form - This Time Without SOAP - KHKonsulting LLC

Getting a Serial Number Into a Form Using SOAP - KHKonsulting LLC

And, if you want to fill out more than one form at a time, take a look here:

Batch-Import Excel Data into PDF Forms - KHKonsulting LLC

Batch-Import List Data into PDF Form - KHKonsulting LLC 

Likes

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
Reply
Loading...
Apr 20, 2018 2
Community Beginner ,
Apr 25, 2018

Copy link to clipboard

Copied

Hi Karl,

Thank you for your reply. I am still having a question that seeks some suggestions.

In the link of "Batch-Import list data into pdf form", I can understand that in the code part, it is to create a temporary document to store the data from txt file. But I can not find how to import that existed pdf "sign-in sheet" and how to generate that pdf form to be ready to download. I mean, how to get this generated pdf "sign-in sheet", I am a little bit confused because I am still a beginner for javascript currently.

Really appreciate for your help.

Changjian

Likes

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
Reply
Loading...
Apr 25, 2018 0
Adobe Community Professional ,
Apr 26, 2018

Copy link to clipboard

Copied

I see that you've posted a separate question and already received a lot of information, so I will not comment on this any further.

Likes

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
Reply
Loading...
Apr 26, 2018 0