HtmlToPdf Class |
Namespace: MailBee.Pdf
The HtmlToPdf type exposes the following members.
Name | Description | |
---|---|---|
HtmlToPdf | Creates an instance of HtmlToPdf class. | |
HtmlToPdf(String) |
Creates and unlocks an instance of HtmlToPdf class.
| |
HtmlToPdf(Boolean, Encoding, String, String) | Creates an instance of HtmlToPdf class for use with international charsets. |
Name | Description | |
---|---|---|
Convert(Stream, Stream) |
Writes an HTML or plain-text string into a stream in PDF format.
| |
Convert(Stream, String) |
Writes an HTML or plain-text string into the file in PDF format.
| |
Convert(String, Stream) |
Writes an HTML or plain-text string into a stream in PDF format.
| |
Convert(String, String) |
Writes an HTML or plain-text string into the file in PDF format.
| |
Convert(Uri, Stream) |
Converts HTML, plain text or XML document denoted by the specified URI into the stream in PDF format.
| |
Convert(Uri, String) |
Converts HTML, plain text or XML document denoted by the specified URI into the file in PDF format.
| |
ConvertFile(String, Stream) |
Writes the file with HTML or plain-text string into a stream in PDF format.
| |
ConvertFile(String, String) |
Writes the file with HTML or plain-text string into the file in PDF format.
| |
Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetHashCode | Serves as the default hash function. (Inherited from Object.) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Name | Description | |
---|---|---|
DefaultFont |
Gets or sets default font for creating .pdf document with specified name or filename,
encoding and size as iTextSharp.text.Font object.
| |
DefaultFontSize |
Gets or sets font size for the internal default font.
| |
LicenseKey | Obsolete.
Assigns the license key.
| |
OnConvertXmlNodeToPdf |
Gets or sets the application-supplied method for fine-tuning of source to PDF conversion.
| |
OnProcessImagePath |
Gets or sets the application-supplied method for changing path or URI or URL to the image.
| |
PageRectangle |
Gets or sets page size of .pdf document as iTextSharp.text.Rectangle object.
| |
SourceType |
Gets or sets the format of the input data for the conversion.
| |
TrialDaysLeft |
Gets the number of days left to the date of the trial license key expiration.
| |
UseBlackAndWhiteStyle |
Enables conversion of colored HTML document to black and white PDF document.
|
This class is capable of converting table-based HTML/XHTML documents (like invoices and reports) or plain-text into PDF format. For HTML, only the most common CSS styles are supported. The component, however, provides OnConvertXmlNodeToPdf delegate which allows you to fine-tune the conversion process by adjusting colors, alignment, fonts, or with direct emitting PDF content.
Prior to creating instances of this class, the correct license key must be set. See MailBee.Global.LicenseKey property for details.
Note |
---|
This class uses iTextSharp and HtmlAgilityPack open source libraries to make HTML be XHTML compliant and build actual PDF content. If you're using HtmlToPdf class, you'll also need to copy the corresponding .DLLs with your application. By default, iTextSharp and HtmlAgilityPack .DLLs reside at the same location where MailBee.NET.dll itself. |
Note |
---|
This class is not supported in .NET Core and UWP apps. |