This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class CompressionExtensions | |
{ | |
//The binaries of ghostscript should be included in the application directory to make this work, in this case gswin32c. (Only for windows) | |
public static void CompressPDF(string inputFile, string outPutFile, CompressionOption compressionOption = CompressionOption.Printer) | |
{ | |
Process proc = new Process(); | |
ProcessStartInfo psi = new ProcessStartInfo | |
{ | |
CreateNoWindow = true, | |
ErrorDialog = false, |