NetTalk Central

Author Topic: Print a report to PDF and do not delete  (Read 3051 times)

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Print a report to PDF and do not delete
« on: March 14, 2011, 10:04:41 PM »
I want to print a 1 or 2 page report to PDF and then email copies to various addresses after which I will delete (or save) the pdf file.
I would appreciate any help as to how to trap and save this file before Nettalk deletes it.
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11245
    • View Profile
Re: Print a report to PDF and do not delete
« Reply #1 on: March 14, 2011, 10:17:27 PM »
In the report procedure search for the line;

loc:pdfname = '.\$$$' & format(random(1,99999),@n05) &'.pdf'

(search for $$$, the rest of the line may be slightly different).

This sets the name of the PDF being saved. The leading $$$ is the magic that makes it auto-delete.
So if you embed just below the line to some name without $$$ then you'll have control over the file.

cheers
Bruce

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Re: Print a report to PDF and do not delete
« Reply #2 on: March 14, 2011, 10:47:31 PM »
Thanks Bruce
I knew about the $$$ (mentioned in your book) but I didn't know what was the best place to fiddle with the filename.
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186