How to test PDF Compressor SDK from C# source code?


I am looking at getting a developer SDK license for the PDF Compressor, I am unable to work out how test this in my Application. i use C#, are you able to help me out or point me in the right direction.

Thanks for your message, you can download and purchase PDF Compressor SDK  from following web page,

this package is contain C#, VB and VB.NET examples, you can launch a CMD window by administrator privilege, and run following command line to register PDFCompressCom.exe COM into your system,

PDFCompressCom.exe /regserver

then you can compile and run C# project to test PDF Compression function.

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using VeryPDF;
using System.IO;

namespace WindowsFormsApplication1
    public partial class Form1 : Form
        public Form1()

        private void button1_Click(object sender, EventArgs e)
            string appPath = Path.GetDirectoryName(Application.ExecutablePath);
            string strPDFFile = appPath + "\\sample\\test-color-image.pdf";
            string strOutFile = appPath + "\\sample\\test-color-image_out.pdf";
            string strLicenseKey = "-$ XXXX-XXXX-XXXX-XXXX";

            string strCmd = "-ci jpx -cidown -cidownres 150 -gi jpx -gidown -gidownres 150 -mi jbig2 -midown -midownres 150 " + strLicenseKey + " \"" + strPDFFile + "\" \"" + strOutFile + "\"";

            System.Type VeryPDFType = System.Type.GetTypeFromProgID("VeryPDF.PDFCompressCom");
            VeryPDF.PDFCompressCom VeryPDFCom = (VeryPDF.PDFCompressCom)System.Activator.CreateInstance(VeryPDFType);
            string strReturn = VeryPDFCom.PDFCompressor(strCmd);


See Also:

VN:F [1.9.20_1166]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.20_1166]
Rating: 0 (from 0 votes)

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *

Verify Code   If you cannot see the CheckCode image,please refresh the page again!