What is the best PDF Printer Driver Windows to use with Five

What is the best PDF Printer Driver Windows to use with Five

Postby byron.hopp » Wed Jan 25, 2023 7:46 pm

I currently using PDF995 but you have to mess with the pdf995.ini file, it doesn't seem to work that great. Has somebody found something more stable, works every time. I would like not to have to rewrite all of my reports in this application this is why I don't use the PDF that is available in FiveWin.

Thanks,
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 382
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: What is the best PDF Printer Driver Windows to use with Five

Postby nageswaragunupudi » Wed Jan 25, 2023 8:30 pm

There is no need to rewrite any reports in the FiveWin program and we also do not need any external software to generate pdfs.

It is just as simple as clicking the "PDF button" on the Preview screen.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10625
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: What is the best PDF Printer Driver Windows to use with Five

Postby byron.hopp » Wed Jan 25, 2023 10:33 pm

Thank you very much, you got my interest, but I do not want the preview screen to come up during this process. They need to print to the pdf file and the program immediately emails the file to the intended user. So I need to be able to identify the File Name, and Path, and product the pdf file, then make it an attachment to an email. Is this possible to do this?

Thanks,
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 382
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: What is the best PDF Printer Driver Windows to use with Five

Postby karinha » Wed Jan 25, 2023 10:53 pm

Try this, Or use: SUMATRAPDF.exe.

Code: Select all  Expand view

FUNCTION PRINT_ME()

   REDEFINE BUTTONBMP oPrevAdobe ID 301 OF oDlgBtn RESOURCE "160" TEXTRIGHT  ;
      ACTION( IMPRIMIR_RECO_JARDIM_NEW( DeOndePartiu := "DIRETONAIMP", oDlgBtn ) )

   oPrevAdobe:cToolTip := OemToAnsi( "Imprimir Direto na Impressora PadrÆo" )

   REDEFINE BUTTONBMP oPrevFive ID 302 OF oDlgBtn RESOURCE "160" TEXTRIGHT   ;
        ACTION( IMPRIMIR_RECO_JARDIM_NEW( DeOndePartiu := "COMPREVIEWFIVE", oDlgBtn ) )

   oPrevFive:cToolTip := "Imprimir Visualizando com Preview"

   REDEFINE BUTTONBMP oPrevGravar ID 303 OF oDlgBtn RESOURCE "160" TEXTRIGHT ;
      ACTION( IMPRIMIR_RECO_JARDIM_NEW( DeOndePartiu := "COMPREVIEWPDF", oDlgBtn ) )

   oPrevGravar:cToolTip := OemToAnsi( "Visualiza(Preview) e Grava o PDF do Or‡amento" )

   oOrdemEntrega:cToolTip = OemToAnsi( "Gerar a Ordem de Entrega" )

   REDEFINE BUTTONBMP oSaida ID 304 OF oDlgBtn RESOURCE "154" TEXTRIGHT      ;
      ACTION( oDlgBtn:End() ) CANCEL

RETURN NIL

FUNCTION IMPRIMIR_RECO_JARDIM_NEW( ... )


   IF DeOndePartiu = "DIRETONAIMP"     // DIRETO NA IMPRESSORA

      PRINT oPrn NAME "RECOMP_JARDIM"  // DIRETO NA IMP.

   ELSEIF DeOndePartiu = "COMPREVIEWFIVE"  // COM PREVIEW DO FIVEWIN

      PRINT oPrn NAME "RECOMP_JARDIM" PREVIEW MODAL

   ELSEIF DeOndePartiu = "COMPREVIEWPDF"  // GERAR O ARQUIVO PDF.

      PRINT oPrn PREVIEW

   ENDIF

   DEFINE FONT oFontRua  NAME "Courier New" SIZE 0, - 10                OF oPrn
   DEFINE FONT oFontMin  NAME "Courier New" SIZE 0, - 10 BOLD           OF oPrn
   DEFINE FONT oFont     NAME "Courier New" SIZE 0, - 12                OF oPrn
   DEFINE FONT oFontBold NAME "Courier New" SIZE 0, - 12 BOLD           OF oPrn
   DEFINE FONT oFontSubl NAME "Courier New" SIZE 0, - 12 BOLD UnderLine OF oPrn
   DEFINE FONT oFontSub2 NAME "Courier New" SIZE 0, - 12 BOLD UnderLine OF oPrn

   DEFINE PEN oPen1 WIDTH 4 COLOR CLR_BROWN OF oPrn
   DEFINE PEN oPen2 WIDTH 2 COLOR CLR_BROWN OF oPrn
   DEFINE PEN oPen3 WIDTH 5 COLOR CLR_BLACK OF oPrn

   oPrn:SetPage( 9 ) ; oPrn:SetPortrait()

   ... TEXT... etc

   ENDPRINT

   IF DeOndePartiu = "COMPREVIEWPDF"

      FWSavePreviewToPDF( oPrn, "NAMETOPDF.PDF", .F. )

      // Para visualizar o PDF. HTMLPDF.PRG
      HTMLVIEW( "C:\ORCAMPDF\RECOMPJARDIM.PDF" )

   ENDIF

RETURN NIL
 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7808
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: What is the best PDF Printer Driver Windows to use with Five

Postby TimStone » Wed Jan 25, 2023 11:07 pm

Byron,

I use FWH to send emails with PDF's all the time, as do my clients.

As a general "good operating principle", I would always suggest previewing anything before it is sent out, and especially any form of invoice, or statement. It's just being proactive to avoid issues later.

The process for me is quite simple. The client's email address is in their record. So, I preview the document, and hit the Email button. A dialog pops up with the To field populated, and the subject ( but I can edit it ). I then add text and hit the send button. It's very smooth and works perfectly.

You can probably create a subclass to the Printer program that allows you to bypass the Preview viewer as a print option, and just produce and grab the PDF and auto attach it to an email. You can also do things like have selectable scripts for your email ( templates ).

If you are using FWH to produce the documents, then this is all relatively easy to accomplish.

**. As for PDF's: If you create them in FWH, you can name, and save, them anywhere.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: What is the best PDF Printer Driver Windows to use with Five

Postby Jimmy » Wed Jan 25, 2023 11:21 pm

hi,
karinha wrote:Try this, Or use: SUMATRAPDF.exe.

can SumatraPDF "create" a PDF :?:
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1725
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: What is the best PDF Printer Driver Windows to use with Five

Postby byron.hopp » Thu Jan 26, 2023 4:21 am

Thank you, and good advice to preview, however this client runs a high volume shipping service and they do not like any additional clicks. If there is a way to be able to save this report as a pdf (naming it, and deciding where it lands on the drive) would greatly help. I have been using CDO, and PDF995 and this has not worked well. I have already written an OLE function to outlook to send the emails, all I need now is to produce the pdf using the Printer class. Any guidance would be greatly appreciated. Is there a way to send to preview and execute the save to pdf without viewing the preview screen?

Thanks,

Byron ...
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 382
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: What is the best PDF Printer Driver Windows to use with Five

Postby karinha » Thu Jan 26, 2023 3:53 pm

Code: Select all  Expand view

   FWSavePreviewToPDF( oPrn, "NAMETOPDF.PDF", .F. )

   HTMLVIEW( "C:\YOURPDF\RECOMPJARDIM.PDF" ) ; // .OR . SUMATRAPDF.exe

 


https://forums.fivetechsupport.com/viewtopic.php?f=6&t=38472

Regardas, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7808
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: What is the best PDF Printer Driver Windows to use with Five

Postby byron.hopp » Thu Jan 26, 2023 3:58 pm

Very cool, I am going to try this. If I was building a printout when would call this function. Just after the 'End Print', and if so how do you keep it from immediately printing to the printer selected.
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 382
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: What is the best PDF Printer Driver Windows to use with Five

Postby nageswaragunupudi » Sat Jan 28, 2023 12:35 pm

byron.hopp wrote:Thank you very much, you got my interest, but I do not want the preview screen to come up during this process. They need to print to the pdf file and the program immediately emails the file to the intended user. So I need to be able to identify the File Name, and Path, and product the pdf file, then make it an attachment to an email. Is this possible to do this?

Thanks,


This is also extremely simple

Use your PRINT command like this:
Code: Select all  Expand view
PRINT oPrn FILE "yourname.pdf"
  <your print code>
ENDPRINT
 

By the time ENDPRINT command finishes the job, "yourname.pdf" is created silently and is ready on the disk for you to send by email or do whatever.
Please do not get distracted by any other advices.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10625
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: What is the best PDF Printer Driver Windows to use with Five

Postby Rick Lipkin » Sat Jan 28, 2023 3:03 pm

You Can use FWharu .... Rao can give you help .. generate your .pdf within your code and save it out to the operating system and then attach it via whatever e-mail transport of your choice.

Rick Lipkin
User avatar
Rick Lipkin
 
Posts: 2665
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Re: What is the best PDF Printer Driver Windows to use with Five

Postby TimStone » Mon Jan 30, 2023 11:41 pm

Byron,

Based on Mr. Rao's instruction, I would think you can assign the file name to a variable which can be used for the "yourfile.pdf" in his comment.

Since you know the file name, and have it stored, the next instruction could be to use the email system you have ( hopefully ) built into the program to automatically attach that pdf to an email and send it.

Thus you eliminate any extra keystrokes.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2944
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 65 guests