How do I set Jpeg Compression programmatically?

This is a read only forum. It contains the most frequently asked questions about Amyuni products and licensing.
Post Reply
Dany
Amyuni Team
Posts: 113
Joined: Wed Sep 11 2002
Location: Montreal.
Contact:

How do I set Jpeg Compression programmatically?

Post by Dany »

There are two ways to set the compression option and level, depending on your application and your needs. If you call:

pdf.DriverInit( PrinterName )
pdf.JPegCompression = True

pdf.JPegLevel = 7
pdf.SetDefaultConfig

This method will set the Jpeg compression default values for all applications. If you are aware of the DEVMODE structures, you are modifying the default DEVMODE values for the printer. If you open the Printer properties, you will see the settings in the Compression properties page.

If you use:
pdf.DriverInit( PrinterName )
pdf.FileNameOptionsEx( NoPrompt + UseFileName + JPegLevelHigh )
' Do some printing
pdf.FileNameOptionsEx( 0 )

This case will set the Jpeg compression only for a specific print job and then removing it, if you open the printer properties. You will not see the settings in the Compression properties page.
Post Reply