FileConversionHelper Class

Namespace:
Weavy.Core.Helpers
Assembly:
Weavy.Core.dll

Helper methods for working with file conversion.

public static class FileConversionHelper
Inheritance:
System.Object → FileConversionHelper

Methods

CanConvertToDocx(string) Returns whether the specified file can be converted to the docx format.
CanConvertToHtml(string) Returns whether the specified file can be converted to html.
CanConvertToImage(string) Returns whether the specified file can be converted to an image format.
CanConvertToPdf(string) Returns whether the specified file can be converted to pdf.
CanConvertToText(string) Returns whether the specified file can be converted to a text file.
HtmlToImage(string, int, int, int, Color) Renders the specified HTML into a new image of the requested size. The HTML will be layout by the given size but will be clipped if it cannot fit.
ToDocx(FileInfo, FileInfo) Convert the specified file to docx.
ToHtml(FileInfo) Returns the content of the specified file converted to html.
ToImage(FileInfo, FileInfo) Converts the contents of the input file to a System.Drawing.Bitmap image and writes it to the output file. Valid output formats are .gif, .jpg and .png. If the file could not be converted to a System.Drawing.Bitmap image the output file will not be created.
ToPdf(FileInfo, FileInfo) Convert the specified file to pdf.
ToText(FileInfo, FileInfo) Converts the contents of the input file to text and writes it to the output file. If the file could not be converted to text the output file will not be created.