Creates a new instance of the SautinSoft.PdfVision class

Namespace:  SautinSoft
Assembly:  SautinSoft.PdfVision (in SautinSoft.PdfVision.dll) Version: 5.1.2.13

Syntax

      
 C#  Visual Basic 
public PdfVision()
Public Sub New

Remarks

This is constructor of the PDF Vision .Net. The component enably any .Net app to:


  • Convert HTML, ASPX to PDF
  • Convert HTML, ASPX to Image
  • Convert Images (JPEG, PNG, Multipage-TIFF, Bitmap, GIF etc) to PDF
  • Merge and split PDF documents

Examples

CopyHow to convert many TIFF files to PDF files in C#
using System;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;

namespace Sample
{
    class Test
    {
        static void Main(string[] args)
        {
            // Convert many TIFF files to PDF files in the same folder.
            SautinSoft.PdfVision v = new SautinSoft.PdfVision();

            DirectoryInfo tiffDir = new DirectoryInfo(@"..\..\..\..\..\Testing Files\");
            FileInfo[] tiffFiles = tiffDir.GetFiles(@"*.tif*");

            foreach (FileInfo tiffFile in tiffFiles)
            {
                string pdfFile = Path.ChangeExtension(tiffFile.FullName, ".pdf");
                v.ConvertImageFileToPDFFile(tiffFile.FullName, pdfFile);
            }
            // Open the folder with PDF.
            System.Diagnostics.Process.Start(tiffDir.FullName);
        }
    }
}
CopyHow to convert many TIFF files to PDF files in VB.Net
Imports System.IO

Namespace Sample
    Friend Class Test

        Shared Sub Main(ByVal args() As String)
            ' Convert many TIFF files to PDF files in the same folder.
            Dim v As New SautinSoft.PdfVision()

            Dim tiffDir As New DirectoryInfo("..\..\..\..\..\Testing Files\")
            Dim tiffFiles() As FileInfo = tiffDir.GetFiles("*.tif*")

            For Each tiffFile As FileInfo In tiffFiles
                Dim pdfFile As String = Path.ChangeExtension(tiffFile.FullName, ".pdf")
                v.ConvertImageFileToPDFFile(tiffFile.FullName, pdfFile)
            Next tiffFile
            ' Open the folder with PDF.
            System.Diagnostics.Process.Start(tiffDir.FullName)
        End Sub
    End Class
End Namespace

See Also