IronPdfDocumentation
Release4.0.0
http://IronPdf.com
February02,2016
.Pdf printing in thumbnail size - Compress reduce PDF size in C#.net, ASP.NET, MVC, Ajax, WinForms, WPF
C# Code & .NET API to Compress & Decompress PDF Document
change paper size in pdf; pdf reduce file size
.Pdf printing in thumbnail size - VB.NET PDF File Compress Library: Compress reduce PDF size in vb.net, ASP.NET, MVC, Ajax, WinForms, WPF
VB.NET PDF Document Compression and Decompression Control SDK
pdf compressor; change font size pdf fillable form
Create Thumbnail Winforms | Online Tutorials
For information about saving & printing images in Create Thumbnail; Generate Barcodes on Your Documents; Read Processing; RasterEdge OCR Engine; PDF Reading; Encode
pdf file compression; adjust pdf size preview
VB.NET Image: Visual Basic .NET Guide to Draw Text on Image in .
can adjust the text font, font size, font type System.IO Imports System.Drawing.Printing Imports RasterEdge & profession imaging controls, PDF document, image
reader shrink pdf; change font size in pdf fillable form
Contents
1 HelloWorld
3
1.1
Contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
3
i
XImage.Raster for .NET, Comprehensive .NET RasterImage SDK
resolution printing; More about Image Saving & Printing Create thumbnail directly in image. provide powerful & profession imaging controls, PDF document, image
pdf compression settings; batch reduce pdf file size
VB.NET Image: How to Create Visual Basic .NET Windows Image Viewer
image, rotating and flipping an image, printing & saving including png, jpeg, gif, tiff, bmp, PDF, and Word You can accurately define the size and location of
pdf page size limit; change font size fillable pdf
ii
VB.NET Image: How to Draw Annotation on Doc Images with Image SDK
and bmp) or documents (like multi-page TIFF, Microsoft Office Word and PDF file You can freely control the annotation shapes, the outline size (width and height
pdf page size dimensions; can a pdf be compressed
VB.NET Image: VB.NET Code to Create Watermark on Images in .NET
font type "Times New Roman", size "16", and style System.IO Imports System.Drawing. Printing Imports RasterEdge & profession imaging controls, PDF document, tiff
change paper size pdf; advanced pdf compressor
IronPdfDocumentation,Release4.0.0
IronPDFisacommercialGradePDFGenerationlibraryforthe.Netplatform,writteninC#.
Readmoreathttp://ironpdf.com
Thekeyconceptistoavoidtime-consumingPDFgenerationAPIsbyrenderingPDFsfromHTML,CSS,Images
andJavaScript.
IronPDF’scorefeaturesare:
• GeneratingPDFdocumentsfromHTMLasastring
• GeneratingPDFdocumentsfromUrls
• RenderingASPXwebformsasPDFdocumentson-the-fly
Thebaserequirementsare.Netframework4.0onthewindowsplatform.
ItworksequallywellinFormsApplications,ServerApplicationsandServices,WebApplications,SecureIn-
tranets,ConsoleApps,WPFAppsandMVCpatternedwebsites.
Contents
1
C# Image: How to Draw Text on Images within Rasteredge .NET Image
such as adjusting text font size, color, style and System.IO; using System.Drawing. Printing; using RasterEdge & profession imaging controls, PDF document, tiff
pdf change font size; compress pdf
VB.NET Image: How to Create New Images Using VB.NET Codes in .NET
the complete VB.NET sample codes for printing a high settings like image color and size according to powerful & profession imaging controls, PDF document, tiff
pdf change page size; best way to compress pdf files
IronPdfDocumentation,Release4.0.0
2
Contents
VB.NET Image: Web Image and Document Viewer Creation & Design
document pages with zero footprint and thumbnail preview support Basic project is capable of printing current image toolkit to print bitonal images, PDF, and so
pdf page size; 300 dpi pdf file size
VB.NET Image: Compress & Decompress Document Image; RasterEdge .
System.IO Imports System.Drawing.Printing Imports RasterEdge decompressing: reduce Word document size according to Scanned PDF encoding and decoding: compress a
best pdf compression; pdf file size
CHAPTER
1
HelloWorld
NuGetInstaller
PM> Install-Package e IronPdf
1LineHelloWorld
new IronPdf.HtmlToPdf().RenderHtmlAsPdf(@“<p>hello world</p>“).SaveAs(“test.pdf”);
1.1 Contents
1.1.1 WhatisIronPdf?
IronPDFisacommercialGradePDFGenerationlibraryforthe.Netplatform,writteninC#.
Thekeyconceptistoavoidtime-consumingPDFgenerationAPIsbyrenderingPDFsfromHTML,CSS,Images
andJavaScript.
IronPDF’scorefeaturesare:
• GeneratingPDFdocumentsfromHTMLasastring
• GeneratingPDFdocumentsfromUrls
• RenderingASPXwebformsasPDFdocumentson-the-fly
Thebaserequirementsare.Netframework4.0onthewindowsplatform.
ItworksequallywellinFormsApplications,ServerApplicationsandServices,WebApplications,SecureIn-
tranets,ConsoleApps,WPFAppsandMVCpatternedwebsites.
Readmoreathttp://ironpdf.com
HelloWorld
NuGetInstaller
PM> Install-Package e IronPdf
1LineHelloWorld
new IronPdf.HtmlToPdf().RenderHtmlAsPdf(@“<p>hello world</p>“).SaveAs(“test.pdf”);
3
IronPdfDocumentation,Release4.0.0
Features
IronPDFdoesn’ttrytorenderHTML.Itactuallyprintupaninstanceofarealstandardcompliantwebbrowser
behindthescenes(withoutanyadditionalsoftwareneedingtobeinstalled).
TheHTMLgetsrenderedwithcompleteaccuracy-andinavectorformatsuitableforthehigheststandardsof
commercialprinting.
• NomoreconvolutedPDFAPIs.
• JustmakeitlookrightinHTML-andthenuseIronPDFoutputyourPDFasafile,streamorbytearray.
• FullIntelliSensedocumentationwhichevenincludesembeddedcodeexamples.
• NoExternalDependancies.Just1Dll.
• Deployalmostanywhereonawindowsenvironmentwithoutspecialpermissions. NoEXEfiles, , Msior
NativeDllstoinstall.NoCOMobjectsorInterophell.
• Nospecialsecuritypermissionsrequired.
• CSS3,HTML5andJavascriptcompliance.
• Real,standardscompliantHTMLrenderingandpixelperfectPDFconversionwithvectorandfontsupport.
• JavascriptandAJAXcontentcanalsoberenderedintoyourPDFs.
• HighPerformance-PDFfromHTMLrenderingtakesabout125ms.RemoteHTTPrequestswillobviously
takelonger. Firstusagetakeextraoverheadasthebrowservirtualinstanceisinitiated. Thereafteritis
availablealmostinstantlythroughoutyourapplicationprocess.
• Lowmemoryfootprintaboutunder10MBmemory.OursmartGarbageCollectionThisallowsforinstance
likeperformancefromstaticmethods.DynamicallymakessmartchoicestominimizeimpactonCPUand
FreeRam.
• PDFrenderingcanbeachievedinparallelusingthreadsorParallel.ForEach.Thismakesbatchconversions
evenfaster.
• HTMLformsfieldscanautomagicallybecomeeditableareasinyourPDFs
• WorkingcodeExamplesonGitHub
• CustomizableWebClientfunctionallyallowsPrintingofHTMLDocumentsevenbehindloginsoronsecure
intranets.
• Wecanttogetbettereveryday. . Ifthisdocumentationorsoftwarelacksinanyway,pleasepostaGitHub
issueandwewillrespond.
1.1.2 QuickStart
GetIronPdfInstalled
UsingNugetPackagemanagerinVisualStudio
PM> Install-Package e IronPdf
OrDownloadIronPdfasDLL
• Gethttp://localhost/iron/packages/IronPdf.zip
• AddIronPdf.dlltoyourprojectasareferenceortotheGAC.
• Lazyoption-justcopythedllintoyour/Binfolderin.netwebapplications.
4
Chapter1. HelloWorld
IronPdfDocumentation,Release4.0.0
BasicUsage
HTMLStringtoPdf
using IronPdf;
HtmlToPdf HtmlToPdf f = = new IronPdf.HtmlToPdf();
HtmlToPdf.RenderHtmlAsPdf("<p>html</p>"").SaveAs(@"Path\File.Pdf");
UrltoPdf
using IronPdf;
HtmlToPdf HtmlToPdf f = = new IronPdf.HtmlToPdf();
HtmlToPdf.RenderUrlAsPdf(@“http://myurl.com").SaveAs(@"Path\File.Pdf");
Advancedusage-youcanalsopassaSystem.Net.WebClienttoRenderUrlAsPdf.
//...
HtmlToPdf.RenderUrlAsPdf("http://ironpdf.com", myWebClient ).SaveAs("File.Pdf");
Thisallowsyoutosetlogincredentials,proxysettings,specialheaders,cookies-tologintoprotected/secure
webpages.
PdfSettings
using IronPdf;
HtmlToPdf HtmlToPdf f = new IronPdf.HtmlToPdf();
HtmlToPdf.PrintOptions.Dpi = 300;
HtmlToPdf.PrintOptions.PDFPaperSize = = System.Drawing.PaperKind.A4;
HtmlToPdf.PrintOptions.EnableJavaScript = true;
HtmlToPdf.PrintOptions.AllowScreenCss = false;
HtmlToPdf.PrintOptions.SetHeaderText = "{page} of f {total-pages}";
HtmlToPdf.PrintOptions.GrayScale = true;
YoucanalsocreateareusableinstanceofIronPDF.PdfPrintOptionsanduseitintheIronPdf.HtmlToPdfconstruc-
tor.
AspxToPdf
ChangesanyASPXwebpagetoautomaticallyrenderasaPdfdocumentinsteadofhtml.
using IronPdf;
private void Form1_Load(object sender, EventArgs s e)
{
//..
AspxToPdf.RenderThisPageAsPDF();
}
AspxToPdfwithAdvancedSettings
IronPdf.AspxToPdf.RenderThisPageAsPDF(AspxToPdf.FileBehaviour.Attachment, "MyPdfDownload.pdf"new PdfPrintOptions(){ Dpi = 300});
1.1. Contents
5
IronPdfDocumentation,Release4.0.0
PdfOutputs
HtmlToPdf.RenderUrlAsPdfandHtmlToPdf.RenderHtmlAsPdfreturnaninstanceoftheIronPdf.PdfResource
class.
Intheaboveexamples,wedirectlysaveeachPDFasafile.
ItisalsopossibletogetthePdfdocumentasaSystem.IO.MemoryStreamorabytearray(byte[])theStreamand
BinaryDatapropertiesofPdfResourcerespectively.
using IronPdf;
HtmlToPdf HtmlToPdf f = new IronPdf.HtmlToPdf();
//..
System.IO.MemoryStream stream = = HtmlToPdf.RenderHtmlAsPdf("<p>html</p>).Stream;
//or
byte[] data = HtmlToPdf.RenderHtmlAsPdf("<p>html</p>"").BinaryData;
1.1.3 InstallingIronPdf
ForMicrosoftVisualStudioUsers-theeasiestwaytoinstallIronPdfisusingtheNuGetPackageManager.
PM> Install-Package e IronPdf
UsingNuGet
• RightclickonyourprojectinVisualStudio‘SolutionExplorer’
• Select“ManageNugetPackages...”
• IntheSearchBoxType“IronPDF”
• SelectThe“IronPdf”packagetoyourlowerleft.
• Clickthe“Install”buttonyourright.
Formoreinfoyoucanalsofindusat:https://www.nuget.org/packages/IronPdf/
ManualInstallation
• DownloadIronPdfasDLLfromhttp://ironpdf.com/packages/IronPdf.zip
• ExtracttheDLLtoalogicallocationinsideyourproject(orGACforadvancedusers)
• InVisualStudio‘SolutionExplorer’”:
– RightclickonyourprojectandchooseAdd>Reference....
– Select‘Browse...’andthenfindIronPDF.dllanddoubleclickonit.
1.1.4 ObjectReference
IronPdf.HtmlToPdf
HtmlToPdfisyourgo-toclassforcreatingPDFsin.Net
ItcanworkfromHTMlstringorfetchURL(withalloftheirsupportingassets).
AcustomSystem.Net.WebCientcanoptionallybeassigntomanagerequeststorenderwebpageswithspecial
securityprovisions.
6
Chapter1. HelloWorld
Documents you may be interested
Documents you may be interested