Thread View: comp.lang.visual.basic
1 messages
1 total messages
Started by hboothe_no_spam
Wed, 09 Jun 2004 03:19
A twist on PDF forms filling from VB
Author: hboothe_no_spam
Date: Wed, 09 Jun 2004 03:19
Date: Wed, 09 Jun 2004 03:19
30 lines
2278 bytes
2278 bytes
Hello, all, I've read through both of the groups I'm posting to, and
all over the groups, regarding filling PDF forms with data from VB. I
have Acrobat 5 (and the SDK), and am using VB 6. I can successfully
place data in a field with code like the following (leaving out
declarations for brevity):
Set AdPre = CreateObject("AcroExch.AVDoc")
AdPre.Open "c:\test.pdf", "Foo"
Set formApp = CreateObject("AFormAut.App")
Set acroForm = formApp.Fields
acroForm.Item("AA1A").Value = "FOO"
Which basically opens up the form, grabs ref to the fields
collection/object and then sets one of their values to "FOO". Yea!
Not. The darned thing opens up in Acrobat (or viewer on a system with
only viewer). :-/ What I really want is this whole process to be
quiet and in the background. That is, the end user is using my
program to enter and store data and I want my program to fill the
fields and cause the printer to emit the printed report; I don't want
the end user to see a splash on the screen as Reader comes to life and
prints the document; more precisely, I don't want Acrobat/Reader to
ever launch with a UI. That is, is there anyway to make this happen
without actually opening the document in Acrobat/Reader? To me, to
have the document open, if only for a moment, in Acrobat/Reader, when
the user has no need to view it in that program but only to have the
printed report in hand, is junky.
TIA
--HC
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads