Visual C#.NET: Create, Manipulate PDF Document
How to create, manipulate PDF documents using C#.NET
Yiigo.Imaging for .NET PDF Creating Plugin has those following functionalities:
- Create a PDF document according to your needs
- Control page size and the page margin size of each section when you create
- Create table of contents
- Create lines, rectangle, ellipse, bezier and more on PDF documents
- Save PDF to file, IStream and Stream
Create PDF Documents with C#.NET Sample Code Requirements
Before creating PDF documents in Visual C#.NET, make sure that you have installed. Start to Create PDF Documents
- Open and run your Microsoft Visual Studio;
- Choose "Windows Application" in the "Templates" List and name it "YiigoImagingPdfCreateCsharp";
- Right-click on the "References" folder, and select "Add Reference..." from the context menu in the "Solution Explorer" window;
- In the "Add Reference" dialog box, select the ".NET" tab and browse to Yiigo.Imaging.Net.dll library and Yiigo.Imaging.Net.Pdf.Generate.dll;
- Add it to your Visual C# applications;
- Call Yiigo .NET Image Namespace & Copy those following codes:
using System.IO; using System.Drawing.Printing; using Yiigo.Imaging; using Yiigo.Imaging.Processing; using Yiigo.Imaging.PdfGenerate;
// Create a basic PDF PDFGeneratorDocument pdf = new PDFGeneratorDocument(); PDFGeneratorPage page = DefaultPages.Letter; pdf.Pages.Add(page); string font = new Font ("Arial", 10f, FontStyle. Regular); TextLine line = new TextLine(font, 12, "Yiigo", new PdfPoint(72, 400)); page.DrawingLine.Add(line);
// Add some graphics on PDF PDFGeneratorGraphics graphics = DefaultPages.Letter; graphics.DrawRectangle = (System.Drawing.Color.Red, 5, new Rectangle(20, 20, 250, 200); graphics.EllipseRectangle = (System.Drawing.Color.Red, 5, piont1(10.0F, 30.0F), Point2(50.0F, 30.0F)); graphics.BezierRectangle = (System.Drawing.Color.Red, 5, piont1(10.0F, 30.0F), Point2(50.0F, 340.0F)) piont3(15.0F, 55.0F), Point4(50.0F, 30.0F)));
// Save & print PDF pdf.SaveToFile(String FilePath); pdf.SaveToStream(Stream Stream); pdf.print(); | 
Products Overview Tech Specs Features Other Plugins Image Viewer CoreBarcode PluginPDF Read & WriteTesseract OCR PluginForm Processing PluginJBIG2 CodecJPEG2000 CodecISIS ScannerTwain ScannerDICOM ReaderCAD Scanner
|