This code sample shows how to add a note to a PDF document.
Document document = new Document();
Section section = document.Sections.Add();
XhtmlParagraph xhtmlParagraph = new XhtmlParagraph();
ConversionSettings conversionSettings = new ConversionSettings();
conversionSettings.FontPath = @"..\fonts";
xhtmlParagraph.Settings = conversionSettings;
xhtmlParagraph.Text = "<b><font color=\"brown\">Hello world!</font></b><br/>With this you can:<ul><li>Include xHTML compliant layout</li><li>Allow formatting content by (web)designers<br/>... and include it in your document</li></ul>";
section.Paragraphs.Add(xhtmlParagraph);
using (var file = new FileStream(@"..\..\result.pdf", FileMode.Create, FileAccess.Write))
{
document.Write(file);
}
We have sent an email with a download link. Alternatively, you may want to use the NuGet package manager to install our library.
Use the NugetID and start right away, or download the package and install it handmatically