Compression PDF

Discussions about PDF management.
Post Reply
JanaGedap
Posts: 1
Joined: Tue Jun 25, 2013 5:22 pm

Compression PDF

Post by JanaGedap » Tue Jun 25, 2013 6:05 pm

Hello, good afternoon !

I'm trying to compress a PDF file, but I can not make it work... Can you help me? Here is the code:

Command1_Click()
Dim oPDF As New GdPicture_NET_9.GdPicturePDF
Dim PDFName As String
Dim PDFName2 As String

PDFName = "c:\saida\testefinal.pdf"
PDFName2 = "C:\Saida\testefinal_1.pdf"

pictureStatus = oPDF.LoadFromFile(PDFName, False)
oPDF.EnableCompression (True)
Call oPDF.SetCompressionForBitonalImage(PdfCompression_PdfCompressionJBIG2)
pictureStatus = oPDF.SaveToFile_2(PDFName2, True)

MsgBox "Fim"
End Sub

What am I doing wrong?
thank you

Gabriela
Posts: 436
Joined: Wed Nov 22, 2017 9:52 am

Re: Compression PDF

Post by Gabriela » Wed Jan 30, 2019 6:31 pm

Hello,

Here you are:
https://www.gdpicture.com/guides/gdpicture/web ... ssion.html
SetCompression... methods are used for images that you want to add into the PDF document, see the attached examples below:
https://www.gdpicture.com/guides/gdpicture/web ... Image.html
https://www.gdpicture.com/guides/gdpicture/web ... Image.html

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest