Page 1 of 1

form pdf

Posted: Sat Nov 05, 2016 9:54 am
by Jack
Hi,
How is it possible to read the content of a pdf form with fivewin .
Is there a dll or activex ?
Thanks for your help.

Re: form pdf

Posted: Sat Nov 05, 2016 2:56 pm
by dagiayunus
Adobe Acrobat Pro version is require to use the sample.

Code: Select all

function main()
    AcroApp:= CreateObject("AcroExch.App")
    theForm:= CreateObject("AcroExch.PDDoc")
    theForm:Open("c:\reports\test.pdf")
    jso:= theForm:GetJSObject
    text1 = jso:getField("fld1"):Value
    text2 = jso:getField("fld2"):Value
    ?text1
    ?text2
return nil

Re: form pdf

Posted: Mon Nov 07, 2016 7:25 am
by Jack
Thanks for this answer .

Do you have a help file giving more info about this communication .

Is it also possible to write info in a field with fivewin and save this info in the PDF ?

Thanks .

Re: form pdf

Posted: Mon Nov 07, 2016 10:49 am
by dagiayunus

Code: Select all

function main()
    AcroApp:= CreateObject("AcroExch.App")
    theForm:= CreateObject("AcroExch.PDDoc")
    theForm:Open("c:\report\test.pdf")
    jso:= theForm:GetJSObject

********** To Read Pdf form Field  ***********************
    text1 = jso:getField("fld1"):Value
    text2 = jso:getField("fld2"):Value

********** To save pdf form field ************************
    jso:getField("fld1"):Value="Value Changed"
    TheForm:save(,"c:\report\test.pdf")
    
return nil
 

Re: form pdf

Posted: Mon Nov 07, 2016 1:08 pm
by Jack
Thanks for this answer,

Do you have a help or pdf file with more info about this ?

Thanks

Re: form pdf

Posted: Mon Nov 07, 2016 1:49 pm
by dagiayunus

Re: form pdf

Posted: Tue Nov 08, 2016 2:50 am
by hua
Jack, you can search this forum for pdftk if you need to fill pdf forms