Referencing pdf Form Fields from Access (1 Viewer)

gsrajan

Registered User.
Local time
Today, 12:43
Joined
Apr 22, 2014
Messages
227
I found the names of the form fields in a pdf form. Is it possible to populate this form with the data from access? Thank you for your help.
 

theDBguy

I’m here to help
Staff member
Local time
Today, 09:43
Joined
Oct 29, 2018
Messages
21,478
The link to ultra access is broken? Not sure. Can you please give me the direct link in utltra access? Thank you.
The download links are on the left side of that page. Did you just want to see the discussion? If so, try this link:

 

gsrajan

Registered User.
Local time
Today, 12:43
Joined
Apr 22, 2014
Messages
227
I used .. pdfformfieldsdemo v.1.0 works very well but not recognizing all fields. Missing three fields out of 30 fields. I hear about mail merge plug ins. Are they good?. Somewhere I read evermap. Please guide me. I have a form having 150 fields with text boxes and check marks. I will be generating around 100 forms in a week from around 100 users. Form is predefined. I have adobe acrobat dc installed. With DC I am able to change the properties of the forms like required etc. using prepare form option, but not sure how I can populate this form from data from access table. This is how it works: I get the data from users in excel. I clean it up and upload into the access table. I need to populate this data in the predefined form for printing or emailing. Thanks for your help
 

theDBguy

I’m here to help
Staff member
Local time
Today, 09:43
Joined
Oct 29, 2018
Messages
21,478
I used .. pdfformfieldsdemo v.1.0 works very well but not recognizing all fields. Missing three fields out of 30 fields. I hear about mail merge plug ins. Are they good?. Somewhere I read evermap. Please guide me. I have a form having 150 fields with text boxes and check marks. I will be generating around 100 forms in a week from around 100 users. Form is predefined. I have adobe acrobat dc installed. With DC I am able to change the properties of the forms like required etc. using prepare form option, but not sure how I can populate this form from data from access table. This is how it works: I get the data from users in excel. I clean it up and upload into the access table. I need to populate this data in the predefined form for printing or emailing. Thanks for your help
Hi. Just curious, are the missing fields checkboxes on the pdf?
 

gsrajan

Registered User.
Local time
Today, 12:43
Joined
Apr 22, 2014
Messages
227
Please let me know what is wrong in this code. It creates the form document. But it is empty. No error message. Thank you.,

Const strPDF As String = "W-2.pdf"
Const strXFDF As String = "W-2.xfdf"

Dim strPath As String
Dim intFile As Integer

strPath = CurrentProject.Path
intFile = FreeFile

Open strPath & "\" & strXFDF For Output As #intFile

Print #intFile, "<?xml version=""1.0"" encoding=""UTF-8""?>"
Print #intFile, "<xfdf xmlns=""http://ns.adobe.com/xfdf/"" xml:space=""preserve"">"
Print #intFile, "<f href=""" & strPDF & """/>"
Print #intFile, "<fields>"

Print #intFile, "<field name="" Last Name"">"
Print #intFile, "<value>" & Me.lastName & "</value>"
Print #intFile, "</field>"

Print #intFile, "</fields>"
Print #intFile, "</xfdf>"
 

theDBguy

I’m here to help
Staff member
Local time
Today, 09:43
Joined
Oct 29, 2018
Messages
21,478
Please let me know what is wrong in this code. It creates the form document. But it is empty. No error message. Thank you.,

Const strPDF As String = "W-2.pdf"
Const strXFDF As String = "W-2.xfdf"

Dim strPath As String
Dim intFile As Integer

strPath = CurrentProject.Path
intFile = FreeFile

Open strPath & "\" & strXFDF For Output As #intFile

Print #intFile, "<?xml version=""1.0"" encoding=""UTF-8""?>"
Print #intFile, "<xfdf xmlns=""http://ns.adobe.com/xfdf/"" xml:space=""preserve"">"
Print #intFile, "<f href=""" & strPDF & """/>"
Print #intFile, "<fields>"

Print #intFile, "<field name="" Last Name"">"
Print #intFile, "<value>" & Me.lastName & "</value>"
Print #intFile, "</field>"

Print #intFile, "</fields>"
Print #intFile, "</xfdf>"
A question first: Does the demo file work for you (out of the box)?
 

theDBguy

I’m here to help
Staff member
Local time
Today, 09:43
Joined
Oct 29, 2018
Messages
21,478
Yes, it did.
Ok, thanks. That means either the changes you made is missing something or the data is suspect. You said it created the file xfdf, what does it look like if you open it using Notepad?
 

gsrajan

Registered User.
Local time
Today, 12:43
Joined
Apr 22, 2014
Messages
227
When I open, it opens in Adobe DC - the w2 form itself. But no data (Last Name). Thanks. The last name field is blank.
 

theDBguy

I’m here to help
Staff member
Local time
Today, 09:43
Joined
Oct 29, 2018
Messages
21,478
When I open, it opens in Adobe DC - the w2 form itself. But no data (Last Name). Thanks. The last name field is blank.
You need to use Notepad to see what the code produced.
 

gsrajan

Registered User.
Local time
Today, 12:43
Joined
Apr 22, 2014
Messages
227
<?xml version="1.0" encoding="UTF-8"?>
<xfdf xmlns="http://ns.adobe.com/xfdf/" xml:space="preserve">
<f href="W-2.pdf"/>
<fields>
<field name=" Last Name">
<value>RAJAN</value>
</field>
</fields>
</xfdf>
 

theDBguy

I’m here to help
Staff member
Local time
Today, 09:43
Joined
Oct 29, 2018
Messages
21,478
<?xml version="1.0" encoding="UTF-8"?>
<xfdf xmlns="http://ns.adobe.com/xfdf/" xml:space="preserve">
<f href="W-2.pdf"/>
<fields>
<field name=" Last Name">
<value>RAJAN</value>
</field>
</fields>
</xfdf>
Okay, thanks. The first thing I noticed is the PDF field name has a space in it. I don't mean between Last and Name. There's a space before the word Last. Try to take it out and see what happens.
 

gsrajan

Registered User.
Local time
Today, 12:43
Joined
Apr 22, 2014
Messages
227
No difference it made. I got the same blank form. Thank you
 

theDBguy

I’m here to help
Staff member
Local time
Today, 09:43
Joined
Oct 29, 2018
Messages
21,478
No difference it made. I got the same blank form. Thank you
Can you post a sample version of your db with test data, so I can take a look? I mean, if the demo works for you, then you should be able to apply it to your own db, right?
 

Users who are viewing this thread

Top Bottom