Thanks Maruan

So there is no way for Pdfbox to update a open pdf form?

The process would look like :

1.User opens form and starts to fill out in reader
2. Just gets to ID field and puts in ID number and a form button submits ID
via html to listener application which gets name Address etc back from
database
3. This information is then used to update the still open form.

Step 3 seems to be the step from your previous answer that is not possible,
unless there is a way with pdfbox?

Cheers

Al
On 31/03/2016 8:41 am, "Maruan Sahyoun" <[email protected]> wrote:

> Hi,
>
> > Am 30.03.2016 um 20:25 schrieb Tilman Hausherr <[email protected]>:
> >
> > Am 30.03.2016 um 20:21 schrieb Al Grant:
> >> Yes
> >
> > Don't know / never observed this. The only thing I can think of is
> related to "submit", I think this was discussed in an earlier answer.
> >
> > Tilman
> >
> >> On 31/03/2016 6:35 am, "Tilman Hausherr" <[email protected]> wrote:
> >>
> >>> Am 30.03.2016 um 19:27 schrieb Al Grant:
> >>>
> >>>> I assume the value of the fields in a form cannot be updated while the
> >>>> form
> >>>> is open?
> >>>>
>
>
> I'm not sure why you'd like to do that - maybe you can explain that in a
> little more detail.
>
> Options you have are instead of opening a PDF opening a FDF, XFDF or XDP
> (XML Data Package, not to be confused with a LiveCycle Designer Form File
> which is also called XDP!) containing the data and the form (or a link to
> it). Adobe Reader will open the form and update the fields with the values
> supplied in the data files.
>
> For 'real time' updates there is also an option but for that the Adobe
> Reader must be run in a hosting environment such as a web browser. The you
> can use a JavaScript Bridge between the hosting environment and the Adobe
> Reader. E.g. your web browser could be connected to a web socket doing live
> update between the browser and the socket with the browser in turn
> forwarding the data to the PDF. The same way a user entry in the PDF could
> be reflected back.
>
> All of that is not really related to PDFBox, which - as outlined before -
> would populate the form with the data before it's opened by Adobe Reader.
>
> One thing to keep in mind is that the JavaScript Bridge is available in
> Adobe Reader and Adobe Acrobat only which will limit your PDF viewer
> options which may or may not be important for your application.
>
> BR
> Maruan
>
>
> >>> You mean, while the form is displayed in Adobe Reader?
> >>>
> >>> Tilman
> >>>
> >>>
> >>>> On Wed, Mar 30, 2016 at 8:44 PM, Al Grant <[email protected]> wrote:
> >>>>
> >>>> Yeah. That's pretty much what I plan to do.
> >>>>> Just checking my method.
> >>>>>
> >>>>> Thanks.
> >>>>> On 30/03/2016 8:43 pm, "Tilman Hausherr" <[email protected]>
> wrote:
> >>>>>
> >>>>> Am 30.03.2016 um 09:21 schrieb Al Grant:
> >>>>>> Hi Tilman
> >>>>>>> My bad. The form already exists.
> >>>>>>>
> >>>>>>> Is more about filling it out progmatically from the database.
> >>>>>>>
> >>>>>>> I can use any version of Pdfbox.
> >>>>>>>
> >>>>>>> Then get the field, and use setValue(). See e.g. the FillFormField
> >>>>>> example in the source code download, or the SetField example.
> >>>>>>
> >>>>>>
> >>>>>>              // Retrieve an individual field and set it's value.
> >>>>>>              PDTextField field = (PDTextField) acroForm.getField(
> >>>>>> "sampleField" );
> >>>>>>              field.setValue("Text Entry");
> >>>>>>
> >>>>>>              // If a field is nested within the form tree a fully
> >>>>>> qualified name
> >>>>>>              // might be provided to access the field.
> >>>>>>              field = (PDTextField) acroForm.getField(
> >>>>>> "fieldsContainer.nestedSampleField" );
> >>>>>>              field.setValue("Text Entry");
> >>>>>>
> >>>>>>
> >>>>>> Tilman
> >>>>>>
> >>>>>>
> >>>>>> Regards
> >>>>>>> Al
> >>>>>>> On 30/03/2016 8:12 pm, "Tilman Hausherr" <[email protected]>
> >>>>>>> wrote:
> >>>>>>>
> >>>>>>> Am 30.03.2016 um 08:57 schrieb Al Grant:
> >>>>>>>
> >>>>>>>> Hi All,
> >>>>>>>>
> >>>>>>>>> I am looking for a way to get a PDF Form to be partly populated
> from
> >>>>>>>>> a
> >>>>>>>>> database.
> >>>>>>>>>
> >>>>>>>>> Is your question how to create a form dynamically, or how to
> fill an
> >>>>>>>>>
> >>>>>>>> existing form? What PDFBox version are you using?
> >>>>>>>>
> >>>>>>>> Tilman
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> The database is propriety and I will scrape the data, then use
> PDFBox
> >>>>>>>> to
> >>>>>>>>
> >>>>>>>>> generate a copy of the form with some of the fields filled out
> with
> >>>>>>>>> the
> >>>>>>>>> relevant information that was previously scraped.
> >>>>>>>>>
> >>>>>>>>> Does anyone see any issues with this?
> >>>>>>>>>
> >>>>>>>>> The environment is XP, and it only has to work across a company
> LAN.
> >>>>>>>>>
> >>>>>>>>> Regards,
> >>>>>>>>>
> >>>>>>>>> Al
> >>>>>>>>>
> >>>>>>>>>
> >>>>>>>>>
> ---------------------------------------------------------------------
> >>>>>>>>>
> >>>>>>>> To unsubscribe, e-mail: [email protected]
> >>>>>>>> For additional commands, e-mail: [email protected]
> >>>>>>>>
> >>>>>>>>
> >>>>>>>>
> >>>>>>>>
> ---------------------------------------------------------------------
> >>>>>> To unsubscribe, e-mail: [email protected]
> >>>>>> For additional commands, e-mail: [email protected]
> >>>>>>
> >>>>>>
> >>>>>>
> >>> ---------------------------------------------------------------------
> >>> To unsubscribe, e-mail: [email protected]
> >>> For additional commands, e-mail: [email protected]
> >>>
> >>>
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [email protected]
> > For additional commands, e-mail: [email protected]
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to