I've got a PDF Converter Version 2.05 Professional.
I am printing a report from Visual Foxpro 9.0 to using the printer. It prints but the resulting PDF is more 33M. It have about 46 pages, among them 44 are TIFs and 2 of them are JPGs.
I've tried many settings.
Below is the latest code that I am testing with:
Code: Select all
#define FileNameOption_NoPrompte 0x00000001 && do not prompt for file name
#define FileNameOption_UseFileName 0x00000002 && use file name set by SetDefaultFileName else use document name
#define FileNameOption_JPegLevelLow 0x00020000 && Low JPeg compression
m.loPdf = CREATEOBJECT("cdintf.cdintf")
m.loPdf.DriverInit("PDF Converter")
m.loPdf.FileNameOptionsEx = FileNameOption_NoPrompte ;
+ FileNameOption_UseFileName ;
+ FileNameOption_JPegLevelLow
SET PRINTER TO NAME ("PDF Converter")
REPORT FORM rptimagereport.frx NOEJECT NOCONSOLE TO PRINTER
m.loPDF.DriverEnd()
Well, I've tried to use Automatic Compression as the following block of code shows:
Code:
Code: Select all
m.loPdf.FileNameOptionsEx = FileNameOption_NoPrompte ;
+ FileNameOption_UseFileName ;
+ FileNameOption_AutoCompression
[error]
8002000a: Out of present range.
[/error]
Then, I converted all the TIFF images to JPEG format then used JPEGLow compression the size got reduced only by 1M from it's original 33M.
Code: Select all
m.loPdf.FileNameOptionsEx = FileNameOption_NoPrompte ;
+ FileNameOption_UseFileName ;
+ FileNameOption_JPegLevelLow
[code]
Why is this happening?
When I have mixed image types such as TIFF and JPEG, what is best compression to use? Will Automatic Compression compress both of the types?