Click or drag to resize

ConvertFromXpsAsync Method (PDFDoc, IFilter)

Converts the specified XPS file to PDF and append converted pages to the specified PDF document. The EMF will be fitted to the page.

Namespace:  pdftron.PDF
Assembly:  pdftron (in pdftron.dll) Version: 255.255.255.255
Syntax
public static IAsyncAction FromXpsAsync(
	PDFDoc doc,
	IFilter filter
)

Parameters

doc
Type: pdftron.PDFPDFDoc
The PDFDoc to append to.
filter
Type: pdftron.FiltersIFilter
The source filter of the XPS document to convert.

Return Value

Type: IAsyncAction
An object used for managing the asynchronous operation.
Remarks
Use this method to convert a file pointed by any Windows Runtime stream handles (i.e. IInputStream, IStorageFile, etc.). Wrap the Windows Runtime stream with PDFNet's filter classes, then pass it to this method.
Examples
IStorageFile file = ...
using (var fileFilter = new IStorageFileFilter(file)) {
    var doc = new PDFDoc();
    await Convert.FromXpsAsync(doc, fileFilter);
}
See Also