Load PDF and Print Details
- cdmmaui
- Posts: 653
- Joined: Fri Oct 28, 2005 9:53 am
- Location: The Woodlands - Dallas - Scottsdale - London
- Contact:
Load PDF and Print Details
Hello,
Is it possible to load a PDF document (see link below) and print data from FWH application in defined fields? If so, where can I see an example?
http://www.cbsa-asfc.gc.ca/publications ... es/ci1.pdf
Thank you,
Is it possible to load a PDF document (see link below) and print data from FWH application in defined fields? If so, where can I see an example?
http://www.cbsa-asfc.gc.ca/publications ... es/ci1.pdf
Thank you,
- Manuel Valdenebro
- Posts: 706
- Joined: Thu Oct 06, 2005 9:57 pm
- Location: Málaga-España
Re: Load PDF and Print Details
Un saludo
Manuel
Manuel
- cdmmaui
- Posts: 653
- Joined: Fri Oct 28, 2005 9:53 am
- Location: The Woodlands - Dallas - Scottsdale - London
- Contact:
Re: Load PDF and Print Details
Hello,
Thank you for the link. However, where can I find a good example? The links on the post no longer work.
Sincerely,
Thank you for the link. However, where can I find a good example? The links on the post no longer work.
Sincerely,
Re: Load PDF and Print Details
My code for example.
Code: Select all
*-----------------------------------*
Function OpenPdf(cTempFile,cReport)
LOCAL oWnd, oPdf, arq
Default cReport := cTempFile
arq := ""
if PDFActivex(@arq)
DEFINE WINDOW oWnd TITLE cReport
oPdf = TActiveX():New( oWnd, arq ) // "AcroPDF.PDF" )
// oPdf:LoadFile := cTempFile
oPdf:Do( "LoadFile", cTempFile )
oWnd:oClient = oPdf
ACTIVATE WINDOW oWnd MAXIMIZED ;
ON INIT SETWINDOWPOS( oWnd:hWnd, -1, 0, 0, 0, 0, 3 ) ;
VALID (oPdf:End(), .T. )
else
MsgAlert('Acrobat Reader is not install !')
end
RETURN NIL
Regards,
Dutch
FWH 19.01 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio
FWPPC 10.02 / Harbour for PPC (FTDN)
ADS V.9 / MySql / MariaDB
R&R 12 Infinity / Crystal Report XI R2
(Thailand)
Dutch
FWH 19.01 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio
FWPPC 10.02 / Harbour for PPC (FTDN)
ADS V.9 / MySql / MariaDB
R&R 12 Infinity / Crystal Report XI R2
(Thailand)
- cdmmaui
- Posts: 653
- Joined: Fri Oct 28, 2005 9:53 am
- Location: The Woodlands - Dallas - Scottsdale - London
- Contact:
Re: Load PDF and Print Details
Hi Dutch,
Thank you. However I am looking to automatically transfer data from my FWH application to the PDF document. I do not want the user to have to re-enter data. I am looking to do a PDF Meld type transfer.
Thank you. However I am looking to automatically transfer data from my FWH application to the PDF document. I do not want the user to have to re-enter data. I am looking to do a PDF Meld type transfer.
- James Bott
- Posts: 4654
- Joined: Fri Nov 18, 2005 4:52 pm
- Location: San Diego, California, USA
- Contact:
Re: Load PDF and Print Details
Darrell,
You might try what I have done in the past with TXT files.
Generate the PDF using whatever tool you have and include in it keywords for the fields you want to insert--something like [*field1*] (including the brackets and asterisks). This will be your form. Then load the entire file into a memory variable using memoread() or the binary functions if needed. Then do a search and replace for each of the fields using left() and right(). Then write the file out to a temp name and print it.
James
You might try what I have done in the past with TXT files.
Generate the PDF using whatever tool you have and include in it keywords for the fields you want to insert--something like [*field1*] (including the brackets and asterisks). This will be your form. Then load the entire file into a memory variable using memoread() or the binary functions if needed. Then do a search and replace for each of the fields using left() and right(). Then write the file out to a temp name and print it.
James
- cdmmaui
- Posts: 653
- Joined: Fri Oct 28, 2005 9:53 am
- Location: The Woodlands - Dallas - Scottsdale - London
- Contact:
Re: Load PDF and Print Details
Hi James,
Thank you. Actually, I was able to use a third party application called Pdf Meld to transfer data from my FWH application to the PDF. It seems to be working well.
Thank you. Actually, I was able to use a third party application called Pdf Meld to transfer data from my FWH application to the PDF. It seems to be working well.
- Manuel Aranda
- Posts: 561
- Joined: Wed Oct 19, 2005 8:20 pm
- Location: España
Re: Load PDF and Print Details
Un saludo,
Manuel
xH 1.2.3, FWH 14.09, BC++ 5.8.2, xVerce CW 1.0, PellesC
Manuel
xH 1.2.3, FWH 14.09, BC++ 5.8.2, xVerce CW 1.0, PellesC
- cdmmaui
- Posts: 653
- Joined: Fri Oct 28, 2005 9:53 am
- Location: The Woodlands - Dallas - Scottsdale - London
- Contact:
Re: Load PDF and Print Details
Gracias Manuel
Re: Load PDF and Print Details
Aqui tienes un codigo publicado en el foro que lo hace mediante ole ( Adobe acrobat , ojo creo que no vale Reader )
http://forums.fivetechsupport.com/viewt ... 13#p154413
http://forums.fivetechsupport.com/viewt ... 13#p154413