Skip to main content

HtmlConversionOptions

Version: 3.0

cete.dynamicpdf.conversion.htmlconversionoptions

HtmlConversionOptions​

Defines properties and methods that are needed for a Html Conversion

public class HtmlConversionOptions : ConversionOptions
Public Class HtmlConversionOptions
Inherits ConversionOptions

Inheritance: Object → ConversionOptions → HtmlConversionOptions

Licensing Info​

This class is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

Example shows how to use HtmlConversionOptions.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(True)

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(true);

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

Constructors​

HtmlConversionOptions([Optional] Boolean)​

Initializes a new instance of the HtmlConversionOptions class.

public HtmlConversionOptions([bool appendToPdf = False])
Public Sub New (Optional appendToPdf As Boolean = False)

Parameters​

Specify if append option to be enabled

Licensing Info​

This constructor is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

Example shows how to use HtmlConversionOptions with appendToPdf as parameter.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(True)

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(true);

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

HtmlConversionOptions(Double, Double, Double)​

Initializes a new instance of the HtmlConversionOptions class.

public HtmlConversionOptions(double width, double height, double margins)
Public Sub New (width As Double, height As Double, margins As Double)

Parameters​

Width of the page in points

Height of hte page in points

Margins of the page in points

Licensing Info​

This constructor is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

Example shows how to use HtmlConversionOptions with width, height and margin as parameter.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(500,1000,10)

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(500,1000,10);

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

HtmlConversionOptions(Double, Double, Double, Double)​

Initializes a new instance of the HtmlConversionOptions class.

public HtmlConversionOptions(double width, double height, double leftAndRightMargins, double topAndBottomMargins)
Public Sub New (width As Double, height As Double, leftAndRightMargins As Double, topAndBottomMargins As Double)

Parameters​

Width of the page in points

Height of the page in points

The left and right margins of the page in points.

The top and bottom margins of the page in points.

Licensing Info​

This constructor is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use HtmlConversionOptions with Width, Height,LeftAndRightMargin and TopAndBottomMargin.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(500,1000,10,10)

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(500,1000,10,10);

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

HtmlConversionOptions(Double, Double, Double, Double, [Optional] Boolean)​

Initializes a new instance of the HtmlConversionOptions class.

public HtmlConversionOptions(double width, double height, double leftAndRightMargins, double topAndBottomMargins, [bool appendToPdf = False])
Public Sub New (width As Double, height As Double, leftAndRightMargins As Double, topAndBottomMargins As Double, Optional appendToPdf As Boolean = False)

Parameters​

Width of the page in points

Height of the page in points

The left and right margins of the page in points.

The top and bottom margins of the page in points.

Specify if append option to be enabled

Licensing Info​

This constructor is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use HtmlConversionOptions with Width, Height,LeftAndRightMargin, TopAndBottomMargin and appendToPdf as parameter.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(500,1000,10,10,False)

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(500,1000,10,10,false);

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

HtmlConversionOptions(PageSize, PageOrientation, Double)​

Initializes a new instance of the HtmlConversionOptions class.

public HtmlConversionOptions(PageSize size, PageOrientation orientation, double margins)
Public Sub New (size As PageSize, orientation As PageOrientation, margins As Double)

Parameters​

Size of the page

Orientation of the page

Margins of the page in points

Licensing Info​

This constructor is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use HtmlConversionOptions with pageSize, Page orientation and margin as parameter.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(PageSize.A4, PageOrientation.Portrait,10)

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(PageSize.A4, PageOrientaion.Portrait, 10);

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

HtmlConversionOptions(PageSize, PageOrientation, Double, Double, [Optional] Boolean)​

Initializes a new instance of the HtmlConversionOptions class.

public HtmlConversionOptions(PageSize size, PageOrientation orientation, double leftAndRightMargins, double topAndBottomMargins, [bool appendToPdf = False])
Public Sub New (size As PageSize, orientation As PageOrientation, leftAndRightMargins As Double, topAndBottomMargins As Double, Optional appendToPdf As Boolean = False)

Parameters​

Size of the page

Orientation of the page in points

The left and right margins of the page in points.

The top and bottom margins of the page in points.

Specify if append option to be enabled

Licensing Info​

This constructor is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use HtmlConversionOptions with Width, Height,LeftAndRightMargin, TopAndBottomMargin and appendToPdf as parameter.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(PageSize.A4,PageOrientation.Portrait,10,10,false)

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(PageSize.A4, PageOrientation.Portrait,10,10,false);

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

Properties​

AppendToPdf​

Gets or sets the boolean value to specify if append to pdf conversionOptions to be enabled. (Inherited from ConversionOptions)

public bool AppendToPdf { get; set; }
Public Property AppendToPdf As Boolean

Property Value​

Boolean

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the append to pdf property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

'Assign value to AppendToPdf property.
conversionOptions.AppendToPdf = true

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to AppendToPdf property.
conversionOptions.AppendToPdf = true;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Author​

Gets or sets the author meta data for the converted PDF. (Inherited from ConversionOptions)

public string Author { get; set; }
Public Property Author As String

Property Value​

String

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the author property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

' Assign value to Author property.
conversionOptions.Author = "ceTe Software Pvt. Ltd."

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to Author property.
conversionOptions.Author = "ceTe Software Pvt. Ltd.";

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

BottomMargin​

Gets or sets the bottom margin of the page. (Inherited from ConversionOptions)

public double BottomMargin { get; set; }
Public Property BottomMargin As Double

Property Value​

Double

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the bottom margin property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(True)

'Assign value to bottom margin property
conversionOptions.BottomMargin = 10

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(true);

//Assign value to bottom margin property.
conversionOptions.BottomMargin = 10;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

CancelToken​

Gets or sets a CancellationToken for conversion task. (Inherited from ConversionOptions)

public CancellationToken CancelToken { get; set; }
Public Property CancelToken As CancellationToken

Property Value​

CancellationToken

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

Following code will cancel the conversion if it does not finish within a second.

ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 20);
CancellationTokenSource tokenSource = new CancellationTokenSource();
conversionOptions.CancelToken = tokenSource.Token;
System.Threading.Tasks.Task.Run(() => { Thread.Sleep(1000); tokenSource.Cancel(); });
byte[] pdf = await Converter.ConvertAsync(new Uri("http://www.dynamicpdf.com"), conversionOptions);

Remarks​

This property will be used to create the task for conversion, so that the task may be cancelled if needed.

Creator​

Gets or sets the creator meta data for the converted PDF. (Inherited from ConversionOptions)

public string Creator { get; set; }
Public Property Creator As String

Property Value​

String

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the creater meta data property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

' Assign value to producer property.
conversionOptions.Creator = "ceTe software"

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to producer property.
conversionOptions.Creator = "ceTe software";

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

DefaultConversionTimeout​

Gets or sets a default timeout value (in Milliseconds) for completion of the entire conversion. The task will be cancelled when the timeout occurs before CancelToken .

public static int DefaultConversionTimeout { get; set; }
Public Shared Property DefaultConversionTimeout As Int32

Property Value​

Int32

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Height​

Gets or sets the height of the page in points. (Inherited from ConversionOptions)

public double Height { get; set; }
Public Property Height As Double

Property Value​

Double

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the height property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(True)

'Assign value to height property
conversionOptions.Height = 600

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(true);

//Assign value to height property.
conversionOptions.Height = 600;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Keywords​

Gets or sets the keywords meta data for the converted PDF. (Inherited from ConversionOptions)

public string Keywords { get; set; }
Public Property Keywords As String

Property Value​

String

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the keyword meta data property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

' Assign value to keyword property.
conversionOptions.Keywords = "Converter"

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to Keyword property.
conversionOptions.Keywords = "Converter";

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

LeftMargin​

Gets or sets the left margin of the page in points. (Inherited from ConversionOptions)

public double LeftMargin { get; set; }
Public Property LeftMargin As Double

Property Value​

Double

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the left margin property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(True)

'Assign value to left margin property
conversionOptions.LeftMargin = 10

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(true);

//Assign value to left margin property.
conversionOptions.LeftMargin = 10;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

PaperKind​

Gets or sets paper kind for the pages properties. (Inherited from ConversionOptions)

public PaperKind PaperKind { get; set; }
Public Property PaperKind As PaperKind

Property Value​

PaperKind

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the Page kind property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(True)

conversionOptions.PaperKind = PaperKind.A4

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(true);

conversionOptions.PaperKind = PaperKind.A4;
// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Producer​

Gets or sets the producer meta data for the converted PDF. (Inherited from ConversionOptions)

public string Producer { get; set; }
Public Property Producer As String

Property Value​

String

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the producer meta data property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

' Assign value to producer property.
conversionOptions.Producer = "ceTe software"

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to producer property.
conversionOptions.Producer = "ceTe software";

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

RightMargin​

Gets or sets the right margin of the page in points. (Inherited from ConversionOptions)

public double RightMargin { get; set; }
Public Property RightMargin As Double

Property Value​

Double

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the right margin property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(True)

'Assign value to right margin property
conversionOptions.RightMargin = 10

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(true);

//Assign value to right margin property.
conversionOptions.RightMargin = 10;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Subject​

Gets or sets the subject meta data for the converted PDF. (Inherited from ConversionOptions)

public string Subject { get; set; }
Public Property Subject As String

Property Value​

String

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the subject property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

' Assign value to subject property.
conversionOptions.Subject = "Word document conversion to pdf."

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to Subject property.
conversionOptions.Subject = "Word document conversion to pdf.";

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Tagging​

Gets or sets the boolean value to specify if document structure tags for accesibility need to be enabled/disabled. (Inherited from ConversionOptions)

public bool Tagging { get; set; }
Public Property Tagging As Boolean

Property Value​

Boolean

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the Tagging property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

'Assign value to Tagging property.
conversionOptions.Tagging = false

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to Tagging property.
conversionOptions.Tagging = false;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Remarks​

Some doccuments like Word and Excel contains structural information which is added to PDFs by default as Tags. This property can be used to disable that behaviour in order to reduce PDF size in some cases.

Title​

Gets or sets the title meta data for the converted PDF. (Inherited from ConversionOptions)

public string Title { get; set; }
Public Property Title As String

Property Value​

String

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the title property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10)

' Assign value to Title property.
conversionOptions.Title = "MyDocument"

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(PageSize.A4, PageOrientation.Portrait, 10);

//Assign value to title property.
conversionOptions.Title = "MyDocument";

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

TopMargin​

Gets or sets the top margin of the page in points. (Inherited from ConversionOptions)

public double TopMargin { get; set; }
Public Property TopMargin As Double

Property Value​

Double

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the top margin property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(True)

'Assign value to top margin property
conversionOptions.TopMargin = 10

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(true);

//Assign value to top margin property.
conversionOptions.TopMargin = 10;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Width​

Gets or sets the width of the page in points. (Inherited from ConversionOptions)

public double Width { get; set; }
Public Property Width As Double

Property Value​

Double

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

This example shows how to use the width property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create an instance of ConversionOptions
Dim conversionOptions As ConversionOptions = New ConversionOptions(True)

'Assign value to width property
conversionOptions.Width = 600

' Call convert method to do conversion.
Converter.Convert("C:\MyDocument.doc", "C:\MyOutput.pdf", conversionOptions)

End Sub

End Module
using System;
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create an instance of ConversionOptions class.
ConversionOptions conversionOptions = new ConversionOptions(true);

//Assign value to width property.
conversionOptions.Width = 600;

// Call convert method to do conversion.
Converter.Convert(@"C:\MyDocument.doc", @"C:\MyOutput.pdf", conversionOptions);
}
}

Zoom​

Determines the magnification level for the HTML.

public float Zoom { get; set; }
Public Property Zoom As Single

Property Value​

Single

Licensing Info​

This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

Examples​

Example shows how to use Zoom Property.

Imports ceTe.DynamicPDF.Conversion

Module Module1

Sub Main()

' create new instance of HtmlConversionOptions.
Dim conversionOptions As HtmlConversionOptions = New HtmlConversionOptions(True)
conversionOptions.Zoom=1

' Create new instance of Converter by providing suitable parameters.
Dim htmlConversion As HtmlConverter = New HtmlConverter("C:\MyDocument.html",conversionOptions)

' Call Convert method to start conversion
htmlConversion.Convert("C:\MyOutput.pdf")

End Sub

End Module
using ceTe.DynamicPDF.Conversion;

class MyClass
{
static void Main()
{
// create new instance of HtmlConversionOptions.
HtmlConversionOptions conversionOptions = new HtmlConversionOptions(true);
conversionOption.Zoom=1;

// Create new instance of Converter by providing suitable parameters.
HtmlConverter htmlConversion = new HtmlConverter(@"C:\MyDocument.html", conversionOptions);

//Call Convert method to start conversion
htmlConversion.Convert(@"C:\MyOutput.pdf");
}
}

Remarks​

Value 1 represents original size or 100% zoom.

Methods​

Equals(Object)​

Determines whether the specified Object is equal to the current Object . (Inherited from Object)

public bool Equals(Object obj)
Function Equals(obj As Object) As Boolean

Parameters​

The Object to compare with the current Object .

Returns​

true if the specified Object is equal to the current Object ; otherwise, false.

Licensing Info​

This method is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

GetHashCode()​

Serves as a hash function for a particular type. (Inherited from Object)

public int GetHashCode()
Function GetHashCode() As Integer

Returns​

A hash code for the current Object .

Licensing Info​

This method is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

GetType()​

Gets the Type of the current instance. (Inherited from Object)

public Type GetType()
Function GetType() As Type

Returns​

The Type instance that represents the exact runtime type of the current instance.

Licensing Info​

This method is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

ToString()​

Returns a String that represents the current Object . (Inherited from Object)

public string ToString()
Function ToString() As String

Returns​

A String that represents the current Object .

Licensing Info​

This method is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:

See Also​

ceTe.DynamicPDF.Conversion