1. Konstantin Goldobin
  2. PowerBuilder
  3. Thursday, 24 March 2022 14:30 PM UTC

Hello,

I was wondering if anyone knows how to make PDF files generated by the datawindow SaveAs() method smaller. The following are the settings I'm using:

idw_to_save.Object.DataWindow.Export.PDF.NativePDF.UsePrintSpec = 'Yes'
idw_to_save.Object.DataWindow.Export.PDF.Method = NativePDF!
idw_to_save.Object.DataWindow.Export.PDF.NativePDF.PDFStandard = '2' //PDF/A-1b
idw_to_save.Object.DataWindow.Export.PDF.NativePDF.ImageFormat = '1' // JPG
li_rc = idw_to_save.saveAs( as_path, PDF!, true)

Best regards,
Konstantin

Olan Knight Accepted Answer Pending Moderation
  1. Saturday, 26 March 2022 01:14 AM UTC
  2. PowerBuilder
  3. # 1

What you want is for the final size opf the PDF to be as compact as possible.

Once you have created your PDFs, run them through a compression program.
This one is free:  https://smallpdf.com/compress-pdf
As is this one:  https://www.adobe.com/acrobat/online/compress-pdf.html

There are plenty of tools out there to purchase that do this. Put "pdf compression tool download" in your search engine and GO!


Later -

Olan

Comment
There are no comments made yet.
Konstantin Goldobin Accepted Answer Pending Moderation
  1. Friday, 25 March 2022 14:21 PM UTC
  2. PowerBuilder
  3. # 2

Sorry, I don't see anything about fonts in the Export options... 

Where can I find fonts.embed, etc?

Comment
  1. John Fauss
  2. Friday, 25 March 2022 15:48 PM UTC
Refer to the picture that accompanied Mike's earlier reply. Access those properties by editing the application object and clicking the Additional Properties button, then navigate to the PDF Export tab.
  1. Helpful
  1. Konstantin Goldobin
  2. Saturday, 26 March 2022 14:31 PM UTC
There's nothing more than what's displayed in Mike's reply, and I have both tick boxes off. What did Chris mean by "fonts() embed, etc"? I'm afraid I'm still not getting it...
  1. Helpful
  1. John Fauss
  2. Saturday, 26 March 2022 23:38 PM UTC
I'm pretty sure the application object property shown in Mike's screen shot is what Chris was referring to.
  1. Helpful
There are no comments made yet.
Konstantin Goldobin Accepted Answer Pending Moderation
  1. Friday, 25 March 2022 08:33 AM UTC
  2. PowerBuilder
  3. # 3

Hello Chris,

Thank you! Do you know which settings make the smallest size?

K

Comment
  1. Roland Smith
  2. Friday, 25 March 2022 14:09 PM UTC
The only properties in the help file that aren't mentioned above are:

Export.PDF.NativePDF.CustomOrientation

Export.PDF.NativePDF.CustomSize

Export.PDF.NativePDF.MasterPassword

Export.PDF.NativePDF.Restrictions

Export.PDF.NativePDF.UserPassword
  1. Helpful
  1. Chris Pollach @Appeon
  2. Friday, 25 March 2022 14:13 PM UTC
Please check the DW Syntax tool for all the "Export" options in the PDF category. However, the PDF standard & Image format are two key ones. Others like the fonts used, fonts() embed, etc are key too for the final PDF size. HTH
  1. Helpful
  1. Roland Smith
  2. Friday, 25 March 2022 14:42 PM UTC
DW Syntax Tool options match the help topic. There aren't any font related properties.

Maybe you are thinking of one of the secret pb.ini settings.
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Thursday, 24 March 2022 17:40 PM UTC
  2. PowerBuilder
  3. # 4

Hi Konstantin;

   That is a noted side effect of the NativePDF feature at the moment and we already have a few Support Tickets on Native vs GhostScript PDF sizes. So there already is a request over to Engineering to have a look at this larger PDF size issue on NativePDF feature. Note that the final PDF size is also directly tied to the PDF options that you set before using the SaveAs() command.

  I know that Engineering is looking at NativePDF enhancements for PB2022 but as of yet, I do not have a detailed list of changes.

Regards ... Chris

Comment
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Thursday, 24 March 2022 15:51 PM UTC
  2. PowerBuilder
  3. # 5

fonts take up space.  i believe 'custom' means all fonts

 

Comment
  1. Chris Pollach @Appeon
  2. Friday, 25 March 2022 14:32 PM UTC
Correct!
  1. Helpful
  1. Konstantin Goldobin
  2. Monday, 28 March 2022 10:28 AM UTC
I have these not checked.
  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.