cete.dynamicpdf.conversion.conversioncompletedeventargs
ConversionCompletedEventArgs
- Namespace: ceTe.DynamicPDF.Conversion
- Assemblies: DynamicPDF.Converter.dll
Provided data for ConversionCompleted event.
public class ConversionCompletedEventArgs
Public Class ConversionCompletedEventArgs
Inheritance: Object → ConversionCompletedEventArgs
Licensing Info
This class is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:
- An active DynamicPDF https://www.dynamicpdf.com/ultimate-subscription Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Converter selected.
- A DynamicPDF Converter for .NET v3.X Developer license.
Properties
FailException
Gets the exception that occurred during the conversion operation.
public Exception FailException { get; }
Public ReadOnly Property FailException As Exception
Property Value
Licensing Info
This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:
- An active DynamicPDF https://www.dynamicpdf.com/ultimate-subscription Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Converter selected.
- A DynamicPDF Converter for .NET v3.X Developer license.
Examples
Example shows how to use FailException property.
Imports ceTe.DynamicPDF.Conversion
Module Module1
Sub Main()
' Create new instance of Converter by providing suitable parameters.
Dim rtfConversion As RtfConverter = New RtfConverter("C:\MyDocument.rtf")
' Events to know if conversion completed successfully or not
AddHandler rtfConversion.Completed, AddressOf converter_Converted
' Call Convert method to start conversion
rtfConversion.Convert("C:\MyOutput.pdf")
End Sub
Sub converter_Converted(ByVal sender As Object, ByVal e As ConversionCompletedEventArgs)
If (e.FailException IsNot Nothing) Then
Console.WriteLine("Conversion failed with:" + e.FailException.Message +" Exception")
End If
End Sub
End Module
using ceTe.DynamicPDF.Conversion;
class MyClass
{
static void Main()
{
// Create new instance of Converter by providing suitable parameters.
RtfConverter rtfConverter = new RtfConverter(@"C:\MyDocument.rtf");
//Events to know if conversion completed successfully or not
rtfConverter.Completed += new ConversionCompleted(completed);
//Call Convert method to start conversion
rtfConverter.Convert(@"C:\MyOutput.pdf");
}
public static void completed(object sender, ConversionCompletedEventArgs e)
{
if (e.FailException != null)
{
Console.WriteLine("Conversion failed with:" + e.FailException.Message + " Exception");
}
}
}
PdfData
Property to get PDF byte array. It will contain data only when ConvertAsync(void) was called. Null for other things.
public Byte[] PdfData { get; }
Public Property PdfData As Byte[]
Property Value
Licensing Info
This property is a DynamicPDF Converter feature. One of the following is required for non-evaluation usage:
- An active DynamicPDF https://www.dynamicpdf.com/ultimate-subscription Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Converter selected.
- A DynamicPDF Converter for .NET v3.X Developer license.
Examples
Example shows how to get Pdfdata when Convert(void) is used.
Imports ceTe.DynamicPDF.Conversion
Module Module1
Sub Main()
' Create new instance of Converter by providing suitable parameters.
Dim rtfConverter As RtfConverter = New RtfConverter("C:\MyDocument.rtf")
' Events to know if conversion completed successfully or not
AddHandler rtfConverter.Completed, AddressOf completed
' Call Convert method to start conversion
rtfConverter.Convert("C:\MyOutput.pdf")
End Sub
Sub completed(ByVal sender As Object, ByVal e As ConversionCompletedEventArgs)
If (e.PdfData IsNot Nothing) Then
Console.WriteLine("Conversion completed successfully")
End If
End Sub
End Module
using ceTe.DynamicPDF.Conversion;
class MyClass
{
static void Main()
{
// Create new instance of Converter by providing suitable parameters.
RtfConverter rtfConverter = new RtfConverter(@"C:\MyDocument.rtf");
//Events to know if conversion completed successfully or not
rtfConverter.Completed += new ConversionCompleted(completed);
//Call Convert method to start conversion
rtfConverter.Convert(@"C:\MyOutput.pdf");
}
public static void completed(object sender, ConversionCompletedEventArgs e)
{
if (e.PdfData != null)
{
Console.WriteLine("Conversion completed successfully");
}
}
}
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
- obj: Object
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:
- An active DynamicPDF https://www.dynamicpdf.com/ultimate-subscription Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Converter selected.
- A DynamicPDF Converter for .NET v3.X Developer license.
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:
- An active DynamicPDF https://www.dynamicpdf.com/ultimate-subscription Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Converter selected.
- A DynamicPDF Converter for .NET v3.X Developer license.
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:
- An active DynamicPDF https://www.dynamicpdf.com/ultimate-subscription Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Converter selected.
- A DynamicPDF Converter for .NET v3.X Developer license.
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:
- An active DynamicPDF https://www.dynamicpdf.com/ultimate-subscription Subscription
- An active DynamicPDF Professional or Professional Plus Subscription with DynamicPDF Converter selected.
- A DynamicPDF Converter for .NET v3.X Developer license.