Syncfusion.Pdf.Base //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //Sets the barcode text. codaBarcode.Text = "0123"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As PdfCodabarBarcode = New PdfCodabarBarcode() 'Sets the barcode text. codaBarcode.Text = "0123" 'Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") Indicates the region of the barcode. Indicates the backColor of the barcode. Indicates the barcolor of the barcode. Indicates the textcolor of the barcode. Indicates the narrow bar width. Indicates the wide bar width. Indicates the location on where to draw the barcode in the PDF Document. Indicates the size of the the barcode to draw in the PDF Document. Indicates the data string which is to be encoded. Indicates the free area around the barcode label. Indicates the actual width of the barcode. Indicates the actual height of the barcode. Indicates the bar height of the barcode. Indicates the extended text; Indicates BarHeight enabled when sets BarHeight value ; Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //Sets the barcode text. codaBarcode.Text = "0123"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As PdfCodabarBarcode = New PdfCodabarBarcode() 'Sets the barcode text. codaBarcode.Text = "0123" 'Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") Initializes a new instance of the class. Set the barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode("0123"); //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As PdfCodabarBarcode = New PdfCodabarBarcode("0123") 'Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") Internal method which validates whether the given text is acceptable by the current barcode specification or not. The Text. True if Valid, Otherwise False Internal method which calculates the size of the barcode which is going to rendered. Initializes this instance. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode back color. code93.BackColor = new PdfColor(Color.Green); //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Sets the barcode back color. code93.BackColor = new PdfColor(Color.Green) 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode color. code93.BarColor = new PdfColor(Color.Green); //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Sets the barcode color. code93.BarColor = new PdfColor(Color.Green) 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode text color. code93.TextColor = new PdfColor(Color.Green); //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Sets the barcode text color. code93.TextColor = new PdfColor(Color.Green) 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode narrow width. code93.NarrowBarWidth =1f; //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Sets the barcode narrow width. code93.NarrowBarWidth = 1f 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode(); //Sets the barcode text. code93.Text ="CODE93"; //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode() 'Sets the barcode back color. code93.Text ="CODE93" 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode location. code93.Location = new PointF(50, 50); //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code93 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Sets the barcode location. code93.Location = new PointF(50, 50) 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.All = 0f; //Sets the barcode quiet zone. code93QuietZone = quietZones; //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.All = 0f 'Sets the barcode quiet zone. code93QuietZone = quietZones 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode height. code93.BarHeight = 50f; //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Sets the barcode height. code93.BarHeight = 50f 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode size SizeF size=code93.Size; //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Get the barcode size. SizeF size=code93.Size 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Sets the barcode bounds. RectangleF bounds=code93.Bounds; //Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("PdfBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Get the barcode bounds. RectangleF bounds=code93.Bounds 'Draws a barcode on the new Page. code93.Draw(page, new PointF(25, 500)) 'Save document to disk. document.Save("PdfBarcode.pdf") Gets or sets the barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); /// /Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //barcode text. string barcodeText = "0123x"; string validExpression = @"^[\d\-\$\:\/\.\+]+$"; Regex regex = new Regex(validExpression, RegexOptions.Compiled); if (!regex.IsMatch(barcodeText)) { //Create new barcode exception instance. PdfBarcodeException barcodeException = new PdfBarcodeException("Barcode Text contains characters that are not accepted by this barcode specification."); throw barcodeException; } else { //Sets the barcode text. codaBarcode.Text = "0123x"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("output.pdf"); } //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As New PdfCodabarBarcode() 'barcode text. Dim barcodeText As String = "0123x" Dim validExpression As String = "^[\d\-\$\:\/\.\+]+$" Dim regex As New Regex(validExpression, RegexOptions.Compiled) If Not regex.IsMatch(barcodeText) Then 'Create new barcode exception instance. Dim barcodeException As New PdfBarcodeException("Barcode Text contains characters that are not accepted by this barcode specification.") Throw barcodeException Else 'Sets the barcode text. codaBarcode.Text = "0123x" 'Draws a barcode on the new Page. codaBarcode.Draw(page, New PointF(25, 500)) 'Save document to disk. document.Save("output.pdf") End If 'Close the document. document.Close(True) Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); /// /Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //barcode text. string barcodeText = "0123x"; string validExpression = @"^[\d\-\$\:\/\.\+]+$"; Regex regex = new Regex(validExpression, RegexOptions.Compiled); if (!regex.IsMatch(barcodeText)) { //Create new barcode exception instance. PdfBarcodeException barcodeException = new PdfBarcodeException(); throw barcodeException; } else { //Sets the barcode text. codaBarcode.Text = "0123x"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("output.pdf"); } //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As New PdfCodabarBarcode() 'barcode text. Dim barcodeText As String = "0123x" Dim validExpression As String = "^[\d\-\$\:\/\.\+]+$" Dim regex As New Regex(validExpression, RegexOptions.Compiled) If Not regex.IsMatch(barcodeText) Then 'Create new barcode exception instance. Dim barcodeException As New PdfBarcodeException() Throw barcodeException Else 'Sets the barcode text. codaBarcode.Text = "0123x" 'Draws a barcode on the new Page. codaBarcode.Draw(page, New PointF(25, 500)) 'Save document to disk. document.Save("output.pdf") End If 'Close the document. document.Close(True) Initializes a new instance of the class. User defined error message. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); /// /Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //barcode text. string barcodeText = "0123x"; string validExpression = @"^[\d\-\$\:\/\.\+]+$"; Regex regex = new Regex(validExpression, RegexOptions.Compiled); if (!regex.IsMatch(barcodeText)) { //Create new barcode exception instance. PdfBarcodeException barcodeException = new PdfBarcodeException("Barcode Text contains characters that are not accepted by this barcode specification."); throw barcodeException; } else { //Sets the barcode text. codaBarcode.Text = "0123x"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("output.pdf"); } //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As New PdfCodabarBarcode() 'barcode text. Dim barcodeText As String = "0123x" Dim validExpression As String = "^[\d\-\$\:\/\.\+]+$" Dim regex As New Regex(validExpression, RegexOptions.Compiled) If Not regex.IsMatch(barcodeText) Then 'Create new barcode exception instance. Dim barcodeException As New PdfBarcodeException("Barcode Text contains characters that are not accepted by this barcode specification.") Throw barcodeException Else 'Sets the barcode text. codaBarcode.Text = "0123x" 'Draws a barcode on the new Page. codaBarcode.Draw(page, New PointF(25, 500)) 'Save document to disk. document.Save("output.pdf") End If 'Close the document. document.Close(True) Initializes a new instance of the class. User defined error message. The inner exception. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); /// /Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //barcode text. string barcodeText = "0123x"; string validExpression = @"^[\d\-\$\:\/\.\+]+$"; Regex regex = new Regex(validExpression, RegexOptions.Compiled); if (!regex.IsMatch(barcodeText)) { //Create new barcode exception instance. PdfBarcodeException barcodeException = new PdfBarcodeException("Barcode Text contains characters that are not accepted by this barcode specification.", new InvalidDataException("Invalid input text")); throw barcodeException; } else { //Sets the barcode text. codaBarcode.Text = "0123x"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("output.pdf"); } //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As New PdfCodabarBarcode() 'barcode text. Dim barcodeText As String = "0123x" Dim validExpression As String = "^[\d\-\$\:\/\.\+]+$" Dim regex As New Regex(validExpression, RegexOptions.Compiled) If Not regex.IsMatch(barcodeText) Then 'Create new barcode exception instance. Dim barcodeException As New PdfBarcodeException("Barcode Text contains characters that are not accepted by this barcode specification.", New InvalidDataException("Invalid input text")) Throw barcodeException Else 'Sets the barcode text. codaBarcode.Text = "0123x" 'Draws a barcode on the new Page. codaBarcode.Draw(page, New PointF(25, 500)) 'Save document to disk. document.Save("output.pdf") End If 'Close the document. document.Close(True) Initializes a new instance of the class. The object that holds the serialized object data. The contextual information about the source or destination. Represets the Utility class for storing barcode symbols. Indicates the symbol. Indicates the check character. Indicates the Data. Initializes a new instance of the class. Initializes a new instance of the class. The symbol. The check digit. The bars. Gets or sets the Symbol. Gets or sets the check digit. Gets or sets the bar information. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.All = 0f; //Set the barcode quiet zone. code93.QuietZone = quietZones; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("code93.pdf"); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.All = 0f; 'Set the barcode quiet zone. code93.QuietZone = quietZones 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("code93.pdf") Internal variable to store margin. Internal variable to store right margin. Internal variable to store top margin. Internal variable to store left margin. Internal variable to store bottom margin. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.Right = 0f; //Set the barcode quiet zone. code93.QuietZone = quietZones; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("code93.pdf"); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.Right = 0f; 'Set the barcode quiet zone. code93.QuietZone = quietZones 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("code93.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.Top = 0f; //Set the barcode quiet zone. code93.QuietZone = quietZones; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("code93.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.Top = 0f; 'Set the barcode quiet zone. code93.QuietZone = quietZones 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("code93.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.Left = 0f; //Set the barcode quiet zone. code93.QuietZone = quietZones; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("code93.pdf"); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.Left = 0f; 'Set the barcode quiet zone. code93.QuietZone = quietZones 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("code93.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.Bottom = 0f; //Set the barcode quiet zone. code93.QuietZone = quietZones; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("code93.pdf"); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.Bottom = 0f; 'Set the barcode quiet zone. code93.QuietZone = quietZones 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("code93.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.All = 0f; //Set the barcode quiet zone. code93.QuietZone = quietZones; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("code93.pdf"); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.All = 0f; 'Set the barcode quiet zone. code93.QuietZone = quietZones 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("code93.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones(); quietZones.All = 0f; //Set the barcode quiet zone. code93.QuietZone = quietZones; bool isAll=code93.QuietZone.IsAll; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("code93.pdf"); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Creates a new PdfBarcodeQuietZones. PdfBarcodeQuietZones quietZones = new PdfBarcodeQuietZones() quietZones.All = 0f code39.QuietZone=quietZones Dim isAll As bool = code39.QuietZone.IsAll 'Set the barcode quiet zone. code93.QuietZone = quietZones 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("code93.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Holds data of barcode. Indicates the backColor of the barcode. Stores the location of the barcode Holds the quietzone. Holds the dimension of the barcode. Holds the Size of the barcode. Indicates the fore color of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "www.syncfusion.com"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "www.syncfusion.com" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Returns the data as byte array. Draw the barcode to PDF. The PdfPageBase to be drawn the barcode. The location of the barcode to be drawn in the page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Draws a barcode on the new Page. datamatrix.Draw(page, new PointF(100,100)); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Draws a barcode on the new Page. datamatrix.Draw(page, New PointF(100,100)) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Draw the barcode to PDF page. The PDF page to be drawn the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Export the barcode as image. The exported image of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Get the barcode as image. Image img = datamatrix.ToImage(); //Draw image to PDF page. page.Graphics.DrawImage(new PdfBitmap(img), PointF.Empty); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Get the barcode as image. Dim img As Image = datamatrix.ToImage() 'Draw image to PDF page. page.Graphics.DrawImage(New PdfBitmap(img), PointF.Empty) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or set the size of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or sets Quietzone for the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or set the location of the barcode to be rendered in the page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set fore color. datamatrix.ForeColor = new PdfColor(Color.Red); //Set back color. datamatrix.BackColor = new PdfColor(Color.Yellow); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set fore color. datamatrix.ForeColor = New PdfColor(Color.Red) 'Set back color. datamatrix.BackColor = New PdfColor(Color.Yellow) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //Set the font to codabarcode. codaBarcode.Font = font; //Set the barcode text. codaBarcode.Text = "0123"; //Draw a barcode in the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("CodaBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCodabarBarcode. Dim codaBarcode As PdfCodabarBarcode = New PdfCodabarBarcode() 'Set the font.. codaBarcode.Font = font 'Set the barcode text. codaBarcode.Text = "0123" 'Draw a barcode in the new Page. codaBarcode.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("CodaBarcode.pdf") This symbology allows the encoding of strings of up to 16 digits, 10 numeric digits (0 through 9) and 6 special non alpha characters ("+", "-", "$", "/", ":", "."). Class Class Class Class Class Class Class Class Class //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //Sets the barcode text. codaBarcode.Text = "0123"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As New PdfCodabarBarcode() 'Sets the barcode text. codaBarcode.Text = "0123" 'Draws a barcode on the new Page. codaBarcode.Draw(page, New PointF(25, 500)) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Default bar width value. Initializes a defalut DPI Space count for barcode Indicates whether the Checkdigit is already added to the barcode text or not. Used with the barcodes which involves multiple checksum calculations. To check whether Barcode is Continuous Barcode or discrete Automatically adds the check digit to the barcode when true. Indicates barcode pattern. Indicates the barcode text display location. Indicates the font used to draw the text. Indicates the start symbol. Indicates the stop symbol. Indicates the validation expression which is used to validate the input text. Indicates the validation expression. Indicates whether to show check digit or not. Indicates whether to enable / disable the check digits. Indicates the intercharcter gap between bars. Indicates the gap between barcode and the text. Indicates the text alignment. Indicates whether to encode start and stop symbols or not. returns true when the Font property is set. Initializes the new instance of //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //Sets the barcode text. codaBarcode.Text = "0123"; //Draws a barcode on the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCodabarBarcode. Dim codaBarcode As New PdfCodabarBarcode() 'Sets the barcode text. codaBarcode.Text = "0123" 'Draws a barcode on the new Page. codaBarcode.Draw(page, New PointF(25, 500)) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Draws the barcode on the at the specified location. The PDF page. The barcode location. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the font to code11. code11.Font = font; //Set the barcode text. code11.Text = "012345678"; //Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the font to code11. code11.Font = font 'Set the barcode text. code11.Text = "012345678" 'Draw a barcode in the new Page. code11.Draw(page, New PointF(25, 500)) 'Save the document to disk. document.Save("Code11.pdf") Draw one dimensional barcode based on location and size value. The PDF page. The barcode location. The size of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the font to code11. code11.Font = font; //Set the barcode text. code11.Text = "012345678"; //Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500), new SizeF(200,200)); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the font to code11. code11.Font = font 'Set the barcode text. code11.Text = "012345678" 'Draw a barcode in the new Page. code11.Draw(page, New PointF(25, 500), New SizeF(200, 200)) 'Save the document to disk. document.Save("Code11.pdf") Draw one dimensional barcode based on rectangle input values. The PDF page. The bounds of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the font to code11. code11.Font = font; //Set the barcode text. code11.Text = "012345678"; //Draw a barcode in the new Page. code11.Draw(page, new RectangleF(new PointF(25, 500), new SizeF(200,200))); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the font to code11. code11.Font = font 'Set the barcode text. code11.Text = "012345678" 'Draw a barcode in the new Page. code11.Draw(page, New RectangleF(New PointF(25, 500), New SizeF(200, 200))) 'Save the document to disk. document.Save("Code11.pdf") Draw one dimensional barcode based on float input values. The PDF page. The x coordinate of the upper-left corner of the bounding rectangle. The y coordinate of the upper-top corner of the bounding rectangle. The width of the bouding rectangle. The height of the bounding rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the font to code11. code11.Font = font; //Set the barcode text. code11.Text = "012345678"; //Draw a barcode in the new Page. code11.Draw(page, 25, 500, 200, 200); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the font to code11. code11.Font = font 'Set the barcode text. code11.Text = "012345678" 'Draw a barcode in the new Page. code11.Draw(page, 25, 500,200, 200) 'Save the document to disk. document.Save("Code11.pdf") Draws the barcode on the at the specified location. The PDF page. /// //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the font to code11. code11.Font = font; //Set the barcode text. code11.Text = "012345678"; code11.Location = new PointF(100,100); //Draw a barcode in the new Page. code11.Draw(page); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the font to code11. code11.Font = font 'Set the barcode text. code11.Text = "012345678" code11.Location = New PointF(100,100); 'Draw a barcode in the new Page. code11.Draw(page) 'Save the document to disk. document.Save("Code11.pdf") Exports the barcode as image. The barcode image. //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the barcode text. code11.Text = "012345678"; //Get the image for Code32 Barcode. Image image= code32.ToImage(); //Save the image into Disk image.Save("Code32.png", ImageFormat.Png); 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the barcode text. code11.Text = "012345678" 'Get the image for Code32 Barcode. Image image= code32.ToImage() 'Save the image into Disk image.Save("Code32.png", ImageFormat.Png) Export the barcode as image. The size of the barcode. //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the barcode text. code11.Text = "012345678"; //Get the image for Code32 Barcode. Image image= code32.ToImage(new SizeF(200,200)); //Save the image into Disk image.Save("Code32.png", ImageFormat.Png); 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the barcode text. code11.Text = "012345678" 'Get the image for Code32 Barcode. Image image= code32.ToImage(New SizeF(200,200)) 'Save the image into Disk image.Save("Code32.png", ImageFormat.Png) Internal method used to validate the given barcode text. The Text. True if valid, Otherwise False. Returns the size of the barcode. The Size. Returns the Width of the barcode. To get the Extended Text Calculates the check digit based on the barcode specification. Char array containing Check digits Returns the Character width. The width. Returns the Actual text to encode. The Actual Text. Returns the encoded list bytes from text. Internal method used to paint bars on the page. The Page. The Rectangle. Returns the right margin. Returns the height of the barcode. The Height. Internal method used to paint bars on the image. The graphics to draw. The Rectangle. Returns the right margin. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Set the barcode font. code93.Font = font; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code93 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Set the barcode font. code93.Font = font 'Draw a barcode in the new Page. code93.Draw(page, New PointF(25, 500)) 'Save the document to disk. document.Save("code93.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Set the barcode text display location. code93.TextDisplayLocation = TextLocation.Bottom; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code93 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Set the barcode text display location. code93.TextDisplayLocation = TextLocation.Bottom 'Draw a barcode in the new Page. code93.Draw(page, New PointF(25, 500)) 'Save the document to disk. document.Save("code93.pdf") The Default value is false. The Default value is True. Default value is Center. true if [encode start stop symbols]; otherwise, false. Gets or sets the barcode symbols. Gets or sets the barcode symbols. Gets or sets the start symbol for the current barcode specification. Gets or sets the stop symbol for the current barcode specification. Gets or sets the validation expression to validate the given text. Gets or sets the IntercharacterGap. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode(); //Set the font to codabarcode. codaBarcode.Font = font; //Set the barcode text. codaBarcode.Text = "0123"; //Draw a barcode in the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("CodaBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCodabarBarcode. Dim codaBarcode As PdfCodabarBarcode = New PdfCodabarBarcode() 'Set the font.. codaBarcode.Font = font 'Set the barcode text. codaBarcode.Text = "0123" 'Draw a barcode in the new Page. codaBarcode.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("CodaBarcode.pdf") Initializes a new instance of the class. The Barcode Text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCodabarBarcode. PdfCodabarBarcode codaBarcode = new PdfCodabarBarcode("0123"); //Set the font to codabarcode. codaBarcode.Font = font; //Draw a barcode in the new Page. codaBarcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("CodaBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCodabarBarcode. Dim codaBarcode As PdfCodabarBarcode = New PdfCodabarBarcode("0123") 'Set the font.. codaBarcode.Font = font 'Draw a barcode in the new Page. codaBarcode.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("CodaBarcode.pdf") //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create pdfFont and pdfFont style. PdfFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the pdffont to code11 barcode. code11.Font = pdfFont; //Set the barcode text. code11.Text = "012345678"; //Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create pdfFont and pdfFont style. Dim pdfFont As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the pdffont to code11 barcode. code11.Font = pdfFont; 'Set the barcode text. code11.Text = "012345678" 'Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code11.pdf") Only the following symbols are allowed in a Code 11 barcode: 0 1 2 3 4 5 6 7 8 9 - Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create pdfFont and pdfFont style. PdfFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode(); //Set the pdffont to code11 barcode. code11.Font = pdfFont; //Set the barcode text. code11.Text = "012345678"; //Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create pdfFont and pdfFont style. Dim pdfFont As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode() 'Set the pdffont to code11 barcode. code11.Font = pdfFont; 'Set the barcode text. code11.Text = "012345678" 'Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code11.pdf") Initializes a new instance of the class. The Barcode Text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create pdfFont and pdfFont style. PdfFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode11Barcode. PdfCode11Barcode code11 = new PdfCode11Barcode("012345678"); //Set the pdffont to code11 barcode. code11.Font = pdfFont; //Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code11.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create pdfFont and pdfFont style. Dim pdfFont As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode11Barcode. Dim code11 As PdfCode11Barcode = New PdfCode11Barcode("012345678") 'Set the pdffont to code11 barcode. code11.Font = pdfFont 'Draw a barcode in the new Page. code11.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code11.pdf") Calculates the check digit for this barcode specification. The Check digits. Initializes the internal barcode symbol table Gets the symbol. The check value. Symbol //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128ABarcode. PdfCode128ABarcode code128A = new PdfCode128ABarcode(); //Set the font to code128A. code128A.Font = font; //Set the barcode text. code128A.Text = "CODE128A"; //Draw a barcode in the new Page. code128A.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128A.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128ABarcode. Dim code32 As PdfCode128ABarcode = New PdfCode128ABarcode() 'Set the font to code128A. code128A.Font = font 'Set the barcode text. code128A.Text = "Code128A" 'Draw a barcode in the new Page. code128A.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128A.pdf") Only the following symbols are allowed in a Code 128 A barcode: NUL (\x00) SOH (\x01) STX (\x02) ETX (\x03) EOT (\x04) ENQ (\x05) ACK (\x06) BEL (\x07) BS (\x08) HT (\x09) LF (\x0A) VT (\x0B) FF (\x0C) CR (\x0D) SO (\x0E) SI (\x0F) DLE (\x10) DC1 (\x11) DC2 (\x12) DC3 (\x13) DC4 (\x14) NAK (\x15) SYN (\x16) ETB (\x17) CAN (\x18) EM (\x19) SUB (\x1A) ESC (\x1B) FS (\x1C) GS (\x1D) RS (\x1E) US (\x1F) SPACE ! # $ % ' * + , - . 0 1 2 3 4 5 6 7 8 9 : ; ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \ ]^ _ FNC1 (\xF0) FNC2 (\xF1) FNC3 (\xF2) FNC4 Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128ABarcode. PdfCode128ABarcode code128A = new PdfCode128ABarcode(); //Set the font to code128A. code128A.Font = font; //Set the barcode text. code128A.Text = "CODE128A"; //Draw a barcode in the new Page. code128A.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128A.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128ABarcode. Dim code32 As PdfCode128ABarcode = New PdfCode128ABarcode() 'Set the font to code128A. code128A.Font = font 'Set the barcode text. code128A.Text = "Code128A" 'Draw a barcode in the new Page. code128A.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128A.pdf") Initializes a new instance of the class. The Barcode Text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128ABarcode. PdfCode128ABarcode code128A = new PdfCode128ABarcode("Code128A"); //Set the font to code128A. code128A.Font = font; //Draw a barcode in the new Page. code128A.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128A.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128ABarcode. Dim code32 As PdfCode128ABarcode = New PdfCode128ABarcode("Code128A") 'Set the font to code128A. code128A.Font = font 'Draw a barcode in the new Page. code128A.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128A.pdf") Calculates the check digit for this barcode specification. The Check digits. Internal method used to validate the given barcode text. The Text. True if valid, Otherwise False. Initializes the internal barcode symbol table Gets the symbol. The check value. symbol //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode(); //Set the font to code128C. code128C.Font = font; //Set the barcode text. code128C.Text = "Code128C"; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode() 'Set the font to code128C. code128C.Font = font 'Set the barcode text. code128C.Text = "Code128C" 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Only the following symbols are allowed in a Code 128C barcode: 0 1 2 3 4 5 6 7 8 9 FNC1 (\xF0). Code 128 C encodes only numeric symbols at double density, each pair of digits is encoded using a single symbol. Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode(); //Set the font to code128C. code128C.Font = font; //Set the barcode text. code128C.Text = "Code128C"; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode() 'Set the font to code128C. code128C.Font = font 'Set the barcode text. code128C.Text = "Code128C" 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode("Code128C"); //Set the font to code128C. code128C.Font = font; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode("Code128C") 'Set the font to code128C. code128C.Font = font 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Calculates the check digit for this barcode specification. The Check digits. Returns the Actual text to encode. The Actual Text. Gets the data to encode. The original data. Encoded string. Initializes the internal barcode symbol table Internal method used for reading a symbol from barcode symbol table. Returns the encoded list bytes from text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128BBarcode. PdfCode128BBarcode code128B = new PdfCode128BBarcode(); //Set the font to code128B. code128B.Font = font; //Set the barcode text. code128B.Text = "CODE128B"; //Draw a barcode in the new Page. code128B.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128B.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128BBarcode. Dim code32 As PdfCode128BBarcode = New PdfCode128BBarcode() 'Set the font to code128B. code128B.Font = font; 'Set the barcode text. code128B.Text = "Code128B" 'Draw a barcode in the new Page. code128B.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128B.pdf") Only the following symbols are allowed in a Code 128 B barcode:SPACE ! " # $ % ' ( ) * + , - . / 0 12 3 4 5 6 7 8 9 : ; ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \ ]^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~ DEL (\x7F) FNC1 (\xF0) FNC2 (\xF1) FNC3 (\xF2) FNC4 (\xF3) SHIFT (\xF4). Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128BBarcode. PdfCode128BBarcode code128B = new PdfCode128BBarcode(); //Set the font to code128B. code128B.Font = font; //Set the barcode text. code128B.Text = "CODE128B"; //Draw a barcode in the new Page. code128B.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128B.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128BBarcode. Dim code32 As PdfCode128BBarcode = New PdfCode128BBarcode() 'Set the font to code128B. code128B.Font = font; 'Set the barcode text. code128B.Text = "Code128B" 'Draw a barcode in the new Page. code128B.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128B.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128BBarcode. PdfCode128BBarcode code128B = new PdfCode128BBarcode("Code128B"); //Set the font to code128B. code128B.Font = font; //Draw a barcode in the new Page. code128B.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128B.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128BBarcode. Dim code32 As PdfCode128BBarcode = New PdfCode128BBarcode("Code128B") 'Set the font to code128B. code128B.Font = font; 'Draw a barcode in the new Page. code128B.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128B.pdf") Calculates the check digit for this barcode specification. The Check digits. Initializes the internal barcode symbol table Gets the symbol. The check value. symbol //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode(); //Set the font to code128C. code128C.Font = font; //Set the barcode text. code128C.Text = "Code128C"; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode() 'Set the font to code128C. code128C.Font = font 'Set the barcode text. code128C.Text = "Code128C" 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Only the following symbols are allowed in a Code 128C barcode: 0 1 2 3 4 5 6 7 8 9 FNC1 (\xF0). Code 128 C encodes only numeric symbols at double density, each pair of digits is encoded using a single symbol. Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode(); //Set the font to code128C. code128C.Font = font; //Set the barcode text. code128C.Text = "Code128C"; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode() 'Set the font to code128C. code128C.Font = font 'Set the barcode text. code128C.Text = "Code128C" 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode("Code128C"); //Set the font to code128C. code128C.Font = font; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode("Code128C") 'Set the font to code128C. code128C.Font = font 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Calculates the check digit for this barcode specification. The Check digits. Internal method used to validate the given barcode text. The Text. True if valid, Otherwise False. Returns the Actual text to encode. The Actual Text. Returns the encoded list bytes from text. Gets the data to encode. The original data. Encoded string. Initializes the internal barcode symbol table Internal method used for reading a symbol from barcode symbol table. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode32Barcode. PdfCode32Barcode code32 = new PdfCode32Barcode(); //Set the font to code32. code32.Font = font; //Set the barcode text. code32.Text = "01234567"; //Draw a barcode in the new Page. code32.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code32.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode32Barcode. Dim code32 As PdfCode32Barcode = New PdfCode32Barcode() 'Set the font to code32. code32.Font = font 'Set the barcode text. code32.Text = "01234567" 'Draw a barcode in the new Page. code32.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code32.pdf") Only the following symbols are allowed in a Code 32 barcode: 1 2 3 4 5 6 7 8 9 0. The barcode length is 9 digits (8 user defined digits + 1 check digit). Code 32 barcodes are also known as Italian Pharmacode barcodes. Class Class Class Class Class Class Class Class Class //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode39Barcode. PdfCode39Barcode code39 = new PdfCode39Barcode(); //Set the font to code39. code32.Font = font; //Set the barcode text. code39.Text = "CODE39"; //Draw a barcode in the new Page. code39.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code39.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode39Barcode. Dim code39 As PdfCode39Barcode = New PdfCode39Barcode() 'Set the font to code39. code39.Font = font 'Set the barcode text. code39.Text = "CODE39" 'Draw a barcode in the new Page. code39.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code39.pdf") Only the following symbols are allowed in a Code 39 barcode:Only the following symbols are allowed in a Code 39 barcode: 1 2 3 4 5 6 7 8 9 0 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z - . $ / + % SPACE All alphabetic characters are uppercase. If lowercase characters are required, then a Code 39 Extended barcode must be used. Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode39Barcode. PdfCode39Barcode code39 = new PdfCode39Barcode(); //Set the font to code39. code32.Font = font; //Set the barcode text. code39.Text = "CODE39"; //Draw a barcode in the new Page. code39.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code39.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode39Barcode. Dim code39 As PdfCode39Barcode = New PdfCode39Barcode() 'Set the font to code39. code39.Font = font 'Set the barcode text. code39.Text = "CODE39" 'Draw a barcode in the new Page. code39.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code39.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode39Barcode. PdfCode39Barcode code39 = new PdfCode39Barcode("CODE39"); //Set the font to code39. code32.Font = font; //Draw a barcode in the new Page. code39.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code39.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode39Barcode. Dim code39 As PdfCode39Barcode = New PdfCode39Barcode("CODE39") 'Set the font to code39. code39.Font = font 'Draw a barcode in the new Page. code39.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code39.pdf") Initializes this instance. Internal method to calculate the check-digit Internal method which retrieves the specified symbol from the symbol table. Local variable to store the Checksum character value. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode32Barcode. PdfCode32Barcode code32 = new PdfCode32Barcode(); //Set the font to code32. code32.Font = font; //Set the barcode text. code32.Text = "01234567"; //Draw a barcode in the new Page. code32.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code32.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode32Barcode. Dim code32 As PdfCode32Barcode = New PdfCode32Barcode() 'Set the font to code32. code32.Font = font 'Set the barcode text. code32.Text = "01234567" 'Draw a barcode in the new Page. code32.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code32.pdf") Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode32Barcode. PdfCode32Barcode code32 = new PdfCode32Barcode("01234567"); //Set the font to code32. code32.Font = font; //Draw a barcode in the new Page. code32.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code32.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode32Barcode. Dim code32 As PdfCode32Barcode = New PdfCode32Barcode("01234567") 'Set the font to code32. code32.Font = font 'Draw a barcode in the new Page. code32.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code32.pdf") The Barcode Text. Calculates the check digit for this barcode specification. The Check digits. Gets the barcode symbols. Encoded data To get the Actual Encoded Text from from original Text.. The original data. original Data Returns the Actual text to encode. The Actual Text. Initializes the internal barcode symbol table //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode39ExtendedBarcode. PdfCode39ExtendedBarcode code39Ext = new PdfCode39ExtendedBarcode(); //Set the font to code39Ext. code39Ext.Font = font; //Set the barcode text. code39Ext.Text = "Code39Ext"; //Draw a barcode in the new Page. code39Ext.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code39Ext.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode39ExtendedBarcode. Dim code39Ext As PdfCode39ExtendedBarcode = New PdfCode39ExtendedBarcode() 'Set the font to code39Ext. code39Ext.Font = font 'Set the barcode text. code39Ext.Text = "Code39Ext" 'Draw a barcode in the new Page. code39Ext.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code39Ext.pdf") All 128 ASCII characters can be encoded in an extended Code 39 barcode Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode39ExtendedBarcode. PdfCode39ExtendedBarcode code39Ext = new PdfCode39ExtendedBarcode(); //Set the font to code39Ext. code39Ext.Font = font; //Set the barcode text. code39Ext.Text = "Code39Ext"; //Draw a barcode in the new Page. code39Ext.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code39Ext.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode39ExtendedBarcode. Dim code39Ext As PdfCode39ExtendedBarcode = New PdfCode39ExtendedBarcode() 'Set the font to code39Ext. code39Ext.Font = font 'Set the barcode text. code39Ext.Text = "Code39Ext" 'Draw a barcode in the new Page. code39Ext.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code39Ext.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode39ExtendedBarcode. PdfCode39ExtendedBarcode code39Ext = new PdfCode39ExtendedBarcode("Code39Ext"); //Set the font to code39Ext. code39Ext.Font = font; //Draw a barcode in the new Page. code39Ext.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code39Ext.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode39ExtendedBarcode. Dim code39Ext As PdfCode39ExtendedBarcode = New PdfCode39ExtendedBarcode("Code39Ext") 'Set the font to code39Ext. code39Ext.Font = font 'Draw a barcode in the new Page. code39Ext.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code39Ext.pdf") Internal method to calculate the check-digit check digit Initializes this instance. Internal method which retrieves the specified symbol from the symbol table. symbol Internal method to get the extended text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode(); //Set the font to code93. code93.Font = font; //Set the barcode text. code93.Text = "CODE93"; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode() 'Set the font to code93. code93.Font = font 'Set the barcode text. code93.Text = "CODE93" 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("code93.pdf") Only the following symbols are allowed in a Code 93 barcode: 1 2 3 4 5 6 7 8 9 0 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z - . $ / + % SPACE All alphabetic characters are uppercase. If lowercase characters are required, then a Code 93 Extended barcode must be used. Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode(); //Set the font to code93. code93.Font = font; //Set the barcode text. code93.Text = "CODE93"; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode() 'Set the font to code93. code93.Font = font 'Set the barcode text. code93.Text = "CODE93" 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("code93.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode("CODE93"); //Set the font to code93. code93.Font = font; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode("CODE93") 'Set the font to code93. code93.Font = font 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("code93.pdf") Initializes the internal barcode symbol table Calculates the check digit for this barcode specification. The Check digits. Internal method to calculate the check-digit symbols //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode93ExtendedBarcode. PdfCode93ExtendedBarcode code93 = new PdfCode93ExtendedBarcode(); //Set the font to code93Ext. code93Ext.Font = font; //Set the barcode text. code93Ext.Text = "CODE39Ext"; //Draw a barcode in the new Page. code93Ext.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93Ext.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode93ExtendedBarcode. Dim code93Ext As PdfCode93ExtendedBarcode = New PdfCode93ExtendedBarcode() 'Set the font to code93Ext. code93Ext.Font = font 'Set the barcode text. code93Ext.Text = "CODE39Ext" 'Draw a barcode in the new Page. code93Ext.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code93Ext.pdf") All 128 ASCII characters can be encoded in an extended Code 93 barcode. Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode93ExtendedBarcode. PdfCode93ExtendedBarcode code93 = new PdfCode93ExtendedBarcode(); //Set the font to code93Ext. code93Ext.Font = font; //Set the barcode text. code93Ext.Text = "CODE39Ext"; //Draw a barcode in the new Page. code93Ext.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93Ext.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode93ExtendedBarcode. Dim code93Ext As PdfCode93ExtendedBarcode = New PdfCode93ExtendedBarcode() 'Set the font to code93Ext. code93Ext.Font = font 'Set the barcode text. code93Ext.Text = "CODE39Ext" 'Draw a barcode in the new Page. code93Ext.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code93Ext.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode93ExtendedBarcode. PdfCode93ExtendedBarcode code93 = new PdfCode93ExtendedBarcode("Code93Ext"); //Set the font to code93Ext. code93Ext.Font = font; //Draw a barcode in the new Page. code93Ext.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code93Ext.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode93ExtendedBarcode. Dim code93Ext As PdfCode93ExtendedBarcode = New PdfCode93ExtendedBarcode("Code93Ext") 'Set the font to code93Ext. code93Ext.Font = font 'Draw a barcode in the new Page. code93Ext.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code93Ext.pdf") Calculates the check digit for this barcode specification. The Check digits. To get the Checksum value checksum symbols Initializes the internal barcode symbol table To get the Extended Text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCodeUpcBarcode. PdfCodeUpcBarcode upcbarcode = new PdfCodeUpcBarcode(); //Set the font to upc. upcbarcode.Font = font; //Set the barcode text. upcbarcode.Text = "UPC"; //Draw a barcode in the new Page. upcbarcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("UPC.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCodeUpcBarcode. Dim code32 As PdfCodeUpcBarcode = New PdfCodeUpcBarcode() 'Set the font to upc. upcbarcode.Font = font; 'Set the barcode text. upcbarcode.Text = "UPC" 'Draw a barcode in the new Page. upcbarcode.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("UPC.pdf") Only the following symbols are allowed in a UPC-A barcode: 0 1 2 3 4 5 6 7 8 9 B. Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCodeUPCBarcode. PdfCodeUpcBarcode upcbarcode = new PdfCodeUpcBarcode(); //Set the font to upc. upcbarcode.Font = font; //Set the barcode text. upcbarcode.Text = "UPC"; //Draw a barcode in the new Page. upcbarcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("UPC.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCodeUPCBarcode. Dim code32 As PdfCodeUpcBarcode = New PdfCodeUpcBarcode() 'Set the font to upc. upcbarcode.Font = font; 'Set the barcode text. upcbarcode.Text = "UPC" 'Draw a barcode in the new Page. upcbarcode.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("UPC.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCodeUPCBarcode. PdfCodeUpcBarcode upcbarcode = new PdfCodeUpcBarcode("UPC"); //Set the font to upc. upcbarcode.Font = font; //Draw a barcode in the new Page. upcbarcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("UPC.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCodeUPCBarcode. Dim code32 As PdfCodeUpcBarcode = New PdfCodeUpcBarcode("UPC") 'Set the font to upc. upcbarcode.Font = font; 'Draw a barcode in the new Page. upcbarcode.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("UPC.pdf") Calculates the check digit for this barcode specification. The Check digits. Initializes the internal barcode symbol table Represents the PDF datamatrix barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Initializes a defalut DPI Holds the encoding. Holds the data matrix size. Holds the final array. Array containing all possible datamatrix symbol attributes. Holds the suitable symbol attribute based on input text. Holds log array. Holds ALog array. Internal variable for Reed Solomon polynomial. Internal variable for block length. Initializes default quiteZone for data matrix Initialize a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Initialize a new instance of the class. Data to be converted as barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode("Test"); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode("Test") 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Initializes properties and calculation array for DataMatrix barcode. Create log and alog arrays. Creates factors for Reed Solomon polynomial based on the data. Number of correction codewords required. Create matrix. Input data matrix. Builds data matrix. Prepares data codeword by encoding and appending error correction codes. Data in bytes. Final codeword ready for generating matrix. Encodes the data using Base256 encoder. Data to be encoded. Encoded data. Compute codeword using 255 state algorithm. Codeword to compute. Index of the codeword. Encoded codeword. Encodes the data using Numeric encoder. Data to be encoded. Encoded data. Encodes the data using ASCII encoder. Data to be encoded. Encoded data. Compute error correction codewords. Data codewords. Correction codeword array. Data codeword is padded to match the chosen symbol attribute. Length of data codeword. Codeword without padding. Codeword with padding. Choose suitable encoding. Data codeword. Encoded codeword. Adds quietzone on all sides of the data matrix. Input data matrix. Returns QuiteZone value //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Get the barcode as image. Image img = datamatrix.ToImage(); //Draw image to PDF page. page.Graphics.DrawImage(new PdfBitmap(img), PointF.Empty); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Get the barcode as image. Dim img As Image = datamatrix.ToImage() 'Draw image to PDF page. page.Graphics.DrawImage(New PdfBitmap(img), PointF.Empty) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Get the barcode as image. Image img = datamatrix.ToImage(new SizeF(200,200)); //Draw image to PDF page. page.Graphics.DrawImage(new PdfBitmap(img), PointF.Empty); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Get the barcode as image. Dim img As Image = datamatrix.ToImage(New SizeF(200,200)) 'Draw image to PDF page. page.Graphics.DrawImage(New PdfBitmap(img), PointF.Empty) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Draw DataMatrix barcode on Pdf Document. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Draws a barcode on the new Page. datamatrix.Draw(page, new PointF(100,100), new SizeF(200,200)); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Draws a barcode on the new Page. datamatrix.Draw(page, New PointF(100,100), New SizeF(200,200)) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Draw DataMatrix Barcode in pdf document. The PDF page to be drawn the barcode. The rectangle bounds of the rendering area. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Draws a barcode on the new Page. datamatrix.Draw(page, new RectangleF(100, 100, 200, 200)); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Draws a barcode on the new Page. datamatrix.Draw(page, New RectangleF(100, 100, 200, 200)) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Draw DataMatrix barcode in pdf document. The PDF page to be draw the barcode. The x coordinate of the upper-left corner of the bounding rectangle. The Y coordinate of the upper-top corner bounding rectangle. The width of the barcode bounding rectangle. The height of the barcode bounding rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Draws a barcode on the new Page. datamatrix.Draw(page, 100, 100, 200, 200); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Draws a barcode on the new Page. datamatrix.Draw(page, 100, 100, 200, 200) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Draws datamatrix in the PdfPage. The PDF page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set back color. datamatrix.BackColor = new PdfColor(Color.Red); //Set the dimention of the barcode. datamatrix.XDimension = 5; //Draws a barcode on the new Page. datamatrix.Draw(page, new PointF(100,100)); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set back color. datamatrix.BackColor = New PdfColor(Color.Red) 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Draws a barcode on the new Page. datamatrix.Draw(page, New PointF(100,100)) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Set data matrix barcode encoding. datamatrix.Encoding = PdfDataMatrixEncoding.ASCII; //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Set data matrix barcode encoding. datamatrix.Encoding = PdfDataMatrixEncoding.ASCII 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set barcode size. datamatrix.Size = PdfDataMatrixSize.Size20x20; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set barcode size. datamatrix.Size = PdfDataMatrixSize.Size20x20 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Returns the actual number of rows (including quietzones). Returns the actual number of columns (including quietzones). Symbol attribute structure for the DataMatrix. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode(); //Set the font to code128C. code128C.Font = font; //Set the barcode text. code128C.Text = "Code128C"; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode() 'Set the font to code128C. code128C.Font = font 'Set the barcode text. code128C.Text = "Code128C" 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Only the following symbols are allowed in a Code 128C barcode: 0 1 2 3 4 5 6 7 8 9 FNC1 (\xF0). Code 128 C encodes only numeric symbols at double density, each pair of digits is encoded using a single symbol. Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode(); //Set the font to code128C. code128C.Font = font; //Set the barcode text. code128C.Text = "Code128C"; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode() 'Set the font to code128C. code128C.Font = font 'Set the barcode text. code128C.Text = "Code128C" 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfCode128CBarcode. PdfCode128CBarcode code128C = new PdfCode128CBarcode("Code128C"); //Set the font to code128C. code128C.Font = font; //Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Code128C.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfCode128CBarcode. Dim code128C As PdfCode128CBarcode = New PdfCode128CBarcode("Code128C") 'Set the font to code128C. code128C.Font = font 'Draw a barcode in the new Page. code128C.Draw(page, new PointF(25, 500)) 'Save the document to disk. document.Save("Code128C.pdf") Calculates the check digit for this barcode specification. The Check digits. Returns the Actual text to encode. The Actual Text. Gets the data to encode. The original data. Encoded string. Initializes the internal barcode symbol table Internal method used for reading a symbol from barcode symbol table. Returns the encoded list bytes from text. Represents the PDF QR barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Initializes a defalut DPI Holds the Version Information. Holds the Number of Modules. Holds the data of Function Pattern. Holds the Data in the Encoding Region. Check if mode is mixing mode. Set version for mixing mode. Data to be currently encoded in Mixing Mode Data remaining for encoding in mixing mode Total bits required in mixing mode. Count of mixing mode blocks. Stores data blocks of particular mode. Stores Mode of each data block. Holds the Input Mode. Holds the Error correction level. Holds the Data Bit value. Holds the Number of Blocks. Holds the Image. Check if User Mentioned Mode. Check if User Mentioned Version. Check if User Mentioned Error Correction Level. Check if ECI. Holds the ECI Assignment Number. Variable to hold the QR Barcode Values. it used to maintain the dimension of barcode width and height when QuiteZone.All with barcode Size. Initialize a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Creates a new PdfQRBarcode. PdfQRBarcode qrCode = new PdfQRBarcode(); //Set the barcode text. qrCode.Text = "012345678"; //Get the image for QR Barcode. Image image= qrCode.ToImage(); //Save the image into Disk image.Save("QRCode.png", ImageFormat.Png); 'Creates a new PdfQRBarcode. Dim qrCode As PdfQRBarcode = New PdfQRBarcode() 'Set the barcode text. qrCode.Text = "012345678" 'Get the image for Code32 Barcode. Dim image As Image = qrCode.ToImage() 'Save the image into Disk image.Save("QRCode.png", ImageFormat.Png) Draws the barcode on the at the specified location. The pdf page. The barcode location. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfQRBarcode. PdfQRBarcode qrCode = new PdfQRBarcode(); //Set the barcode text. qrCode.Text = "012345678"; //Draw a barcode in the new Page. qrCode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("QRBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfQRBarcode. Dim qrCode As PdfQRBarcode = New PdfQRBarcode() 'Set the barcode text. qrCode.Text = "012345678" 'Draw a barcode in the new Page. qrCode.Draw(page, New PointF(25, 500)) 'Save the document to disk. document.Save("QRBarcode.pdf") Draws the barcode on the at the specified location. The PDF page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfQRBarcode. PdfQRBarcode qrCode = new PdfQRBarcode(); //Set the barcode text. qrCode.Text = "012345678"; qrCode.Location = new PointF(100,100); //Draw a barcode in the new Page. qrCode.Draw(page); //Save the document to disk. document.Save("QRBarcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfQRBarcode. Dim qrCode As PdfQRBarcode = New PdfQRBarcode() 'Set the barcode text. qrCode.Text = "012345678" qrCode.Location = new PointF(100,100); 'Draw a barcode in the new Page. qrCode.Draw(page) 'Save the document to disk. document.Save("QRBarcode.pdf") Generates the values of the QR Barcode Adds quietzone to the QR Barcode. Draw the principal display panel in the given location The x co-ordinate. The y co-ordinate. Draw the Timing Pattern Draw the Alignment Pattern in the given location The x co-ordinate. The y co-ordinate. Encode the Input Data Allocates the Encoded Data and then Mask Encoded Data. Draw the Format Information Initializes the Version, Error correction level, Input Mode. Splits the Code words The Encoded value Blocks. Index of Block Number. Length of the Block. Creates the Blocks The Encoded value. Number of Blocks. Converts Integer value to Boolean The Integer value. Number of Bits. Converts string value to Boolean The String value. Number of Bits. Gets the Allignment pattern coordinates of the current version. Allocates Format and Version Information Returns QuiteZone value //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the QR barcode version. qrBarcode.Version = QRCodeVersion.Version05; //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the QR barcode version. qrBarcode.Version = QRCodeVersion.Version05 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the error correction level. qrBarcode.ErrorCorrectionLevel = PdfErrorCorrectionLevel.High; //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the error correction level. qrBarcode.ErrorCorrectionLevel = PdfErrorCorrectionLevel.High 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the input mode. qrBarcode.InputMode = InputMode.BinaryMode; //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the input mode. qrBarcode.InputMode = InputMode.BinaryMode 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or set the size of the barcode. Struct to hold the value of each dots in Barcode. Specifies if the Dot is black. Specifies if the Dot is already filled. Specifies if the Dot is PDP. Holds the Version Information. Holds the Error Correction Level. Holds the Number of Data code word. Holds the Number of Error correction code words. Holds the Number of Error correction Blocks. Holds the End value of the version. Holds the Data copacity of the version. Holds the Format Information. Holds the Version Information. Holds all the values of Error correcting code words. Holds all the end values. Holds all the Data capacity values. Holds all the Numeric Data capacity of the Error correction level Low. Holds all the Numeric Data capacity of the Error correction level Medium. Holds all the Numeric Data capacity of the Error correction level Quartile. Holds all the Numeric Data capacity of the Error correction level High. Holds all the Alphaumeric Data capacity of the Error correction level Low. Holds all the Alphaumeric Data capacity of the Error correction level Medium. Holds all the Alphaumeric Data capacity of the Error correction level Quartile. Holds all the Alphaumeric Data capacity of the Error correction level High. Holds all the Binary Data capacity of the Error correction level Low. Holds all the Binary Data capacity of the Error correction level Medium. Holds all the Binary Data capacity of the Error correction level Quartile. Holds all the Binary Data capacity of the Error correction level High. Holds all the Mixed Data capacity of the Error correction level Low. Holds all the Mixed Data capacity of the Error correction level Medium. Holds all the Mixed Data capacity of the Error correction level Quartile. Holds all the Mixed Data capacity of the Error correction level High. Initializes the Values. Gets the Alphanumeric values. Gets number of Data code words. Get number of Error correction code words. Gets number of Error correction Blocks. Gets the End of the version. Gets Data capacity. Gets Format Information. Gets Version Information. Gets equivalent Number of the Character. Gets Numeric Data capacity. Gets Alphanumeric data capacity. Get or Private set the Number of Data code words. Get or Private set the Number of Error correction code words. Get or Private set the Number of Error correction Blocks. Get or Private set the End value of the Current Version. Get or Private set the Data capacity. Get or Private set the Format Information. Get or Private set the Version Information. Holds the Length Holds the Error Correction Code Word Holds the DataBits Holds the Data Code word Holds G(x) Holds all the values of Alpha Holds the Decimal value Holds the values of QR Barcode Initializes Error correction code word Version. Error correction level. Gets the Error correction code word Error correction code word. Convert to Decimal Binary values. Convert decimal to Binary value Binary Representation. Decimal Representation. Polynomial division Polynomial coefficient. Find the element in the alpha Index of the element. Element. Alpha. Gets g(x) of the element g(x) Element. Alpha. Sets and Gets the Data code word Sets and Gets the DataBits Sets and Gets the Error Correction Code Words Represents the Pdf417 barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set the barcode text. pdf417Barcode.Text = "012345678"; pdf417Barcode.Location = new PointF(100,100); //Draw a barcode in the new Page. pdf417Barcode.Draw(page); //Save the document to disk. document.Save("417Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As Pdf417Barcode = New Pdf417Barcode() 'Set the barcode text. pdf417Barcode.Text = "012345678" pdf417Barcode.Location = new PointF(100,100); 'Draw a barcode in the new Page. pdf417Barcode.Draw(page) 'Save the document to disk. document.Save("417Barcode.pdf") Draws the barcode on the . The PDF page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set the barcode text. pdf417Barcode.Text = "012345678"; pdf417Barcode.Location = new PointF(100,100); //Draw a barcode in the new Page. pdf417Barcode.Draw(page); //Save the document to disk. document.Save("417Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As Pdf417Barcode = New Pdf417Barcode() 'Set the barcode text. pdf417Barcode.Text = "012345678" pdf417Barcode.Location = new PointF(100,100); 'Draw a barcode in the new Page. pdf417Barcode.Draw(page) 'Save the document to disk. document.Save("417Barcode.pdf") Draws the barcode on the at the specified location. The pdf page. The barcode location. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set the barcode text. pdf417Barcode.Text = "012345678"; //Draw a barcode in the new Page. pdf417Barcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("417Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As Pdf417Barcode = New Pdf417Barcode() 'Set the barcode text. pdf417Barcode.Text = "012345678" 'Draw a barcode in the new Page. pdf417Barcode.Draw(page, New PointF(25, 500)) 'Save the document to disk. document.Save("417Barcode.pdf") Draw Pdf417Barcode based on float input values. The PDF page. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-top corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set the barcode text. pdf417Barcode.Text = "012345678"; //Draw a barcode in the new Page. pdf417Barcode.Draw(page, 25, 100, 200, 200); //Save the document to disk. document.Save("417Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As Pdf417Barcode = New Pdf417Barcode() 'Set the barcode text. pdf417Barcode.Text = "012345678" 'Draw a barcode in the new Page. pdf417Barcode.Draw(page, 25, 100, 200, 200) 'Save the document to disk. document.Save("417Barcode.pdf") Draw Pdf417Barcode based on location and size values. The PDF page. The location of the barcode on the PDF page. The size of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set the barcode text. pdf417Barcode.Text = "012345678"; //Draw a barcode in the new Page. pdf417Barcode.Draw(page, new PointF(25, 500), new SizeF(200,200)); //Save the document to disk. document.Save("417Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As Pdf417Barcode = New Pdf417Barcode() 'Set the barcode text. pdf417Barcode.Text = "012345678" 'Draw a barcode in the new Page. pdf417Barcode.Draw(page, New PointF(25, 500), New SizeF(200, 200)) 'Save the document to disk. document.Save("417Barcode.pdf") Draw Pdf417Barcode based on rectangle input values. The PDF page. The bounds of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set the barcode text. pdf417Barcode.Text = "012345678"; //Draw a barcode in the new Page. pdf417Barcode.Draw(page, new RectangleF(25, 100, 200, 200)); //Save the document to disk. document.Save("417Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As Pdf417Barcode = New Pdf417Barcode() 'Set the barcode text. pdf417Barcode.Text = "012345678" 'Draw a barcode in the new Page. pdf417Barcode.Draw(page, New RectangleF(25, 100, 200, 200)) 'Save the document to disk. document.Save("417Barcode.pdf") Exports the barcode as image. The barcode image. //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set the barcode text. pdf417Barcode.Text = "012345678"; //Get the image for Pdf417Barcode. Image image= pdf417Barcode.ToImage(); //Save the image into Disk image.Save("Pdf417.png", ImageFormat.Png); 'Creates a new Pdf417Barcode. Dim pdf417Barcode As Pdf417Barcode = New Pdf417Barcode() 'Set the barcode text. pdf417Barcode.Text = "012345678" 'Get the image for Pdf417Barcode. Dim image As Image = pdf417Barcode.ToImage() 'Save the image into Disk image.Save("Pdf417.png", ImageFormat.Png) Gets or set the size of the barcode. Gets or sets the error correction level. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set text. pdf417Barcode.Text = "012345678"; //Set barcode size. pdf417Barcode.Size = new SizeF(200, 200); //Set the error correction level. pdf417Barcode.ErrorCorrectionLevel = Pdf417ErrorCorrectionLevel.Auto; //Set the dimention of the barcode. pdf417Barcode.XDimension = 3; //Set the barcode location. pdf417Barcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. pdf417Barcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As New Pdf417Barcode() 'Set text. pdf417Barcode.Text = "012345678" 'Set barcode size. pdf417Barcode.Size = New SizeF(200, 200) 'Set the error correction level. pdf417Barcode.ErrorCorrectionLevel = PdfErrorCorrectionLevel.High 'Set the dimention of the barcode. pdf417Barcode.XDimension = 5 'Set the barcode location. pdf417Barcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. pdf417Barcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Specifies the Pdf417Barcode error correction level. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new Pdf417Barcode. Pdf417Barcode pdf417Barcode = new Pdf417Barcode(); //Set text. pdf417Barcode.Text = "012345678"; //Set barcode size. pdf417Barcode.Size = new SizeF(200, 200); //Set the error correction level. pdf417Barcode.ErrorCorrectionLevel = Pdf417ErrorCorrectionLevel.Auto; //Set the dimention of the barcode. pdf417Barcode.XDimension = 3; //Set the barcode location. pdf417Barcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. pdf417Barcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new Pdf417Barcode. Dim pdf417Barcode As New Pdf417Barcode() 'Set text. pdf417Barcode.Text = "012345678" 'Set barcode size. pdf417Barcode.Size = New SizeF(200, 200) 'Set the error correction level. pdf417Barcode.ErrorCorrectionLevel = PdfErrorCorrectionLevel.High 'Set the dimention of the barcode. pdf417Barcode.XDimension = 5 'Set the barcode location. pdf417Barcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. pdf417Barcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) 2 code words 4 code words 8 code words 16 code words 32 code words 64 code words 128 code words 256 code words 512 code words Auto. Represents the PdfEan13 barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the barcode text. barcode.Text = "4006381333931"; barcode.Location = new PointF(100,100); //Draw a barcode in the new Page. barcode.Draw(page); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the barcode text. barcode.Text = "4006381333931" barcode.Location = new PointF(100,100); 'Draw a barcode in the new Page. barcode.Draw(page) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the font to Ean13. barcode.Font = font; //Set the barcode text. barcode.Text = "4006381333931"; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the font to Ean13. barcode.Font = font 'Set the barcode text. barcode.Text = "4006381333931" 'Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode("4006381333931"); //Set the font to Ean13. barcode.Font = font; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode("4006381333931") 'Set the font to Ean13. barcode.Font = font 'Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Draw PdfEan13Barcode based on float input values. The PDF page. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-top corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the barcode text. barcode.Text = "4006381333931"; //Draw a barcode in the new Page. barcode.Draw(page, 25, 100, 200, 200); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the barcode text. barcode.Text = "4006381333931" 'Draw a barcode in the new Page. barcode.Draw(page, 25, 100, 200, 200) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Draw PdfEan13Barcode based on location and size values. The PDF page. The location of the barcode on the PDF page. The size of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the barcode text. barcode.Text = "4006381333931"; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 500), new SizeF(200,200)); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the barcode text. barcode.Text = "4006381333931" 'Draw a barcode in the new Page. barcode.Draw(page, New PointF(25, 500), New SizeF(200, 200)) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Draw PdfEan13Barcode based on rectangle input values. The PDF page. The bounds of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the barcode text. barcode.Text = "4006381333931"; //Draw a barcode in the new Page. barcode.Draw(page, new RectangleF(25, 100, 200, 200)); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the barcode text. barcode.Text = "4006381333931" 'Draw a barcode in the new Page. barcode.Draw(page, New RectangleF(25, 100, 200, 200)) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Draws the barcode on the . The PDF page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the barcode text. barcode.Text = "4006381333931"; barcode.Location = new PointF(100,100); //Draw a barcode in the new Page. barcode.Draw(page); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the barcode text. barcode.Text = "4006381333931" barcode.Location = new PointF(100,100); 'Draw a barcode in the new Page. barcode.Draw(page) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Draws the barcode on the at the specified location. The pdf page. The barcode location. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the barcode text. barcode.Text = "4006381333931"; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 500)); //Save the document to disk. document.Save("Ean13Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the barcode text. barcode.Text = "4006381333931" 'Draw a barcode in the new Page. barcode.Draw(page, New PointF(25, 500)) 'Save the document to disk. document.Save("Ean13Barcode.pdf") Exports the barcode as image. The barcode image. //Creates a new PdfEan13Barcode. PdfEan13Barcode barcode = new PdfEan13Barcode(); //Set the barcode text. barcode.Text = "4006381333931"; //Get the image for PdfEan13Barcode. Image image= barcode.ToImage(); //Save the image into Disk image.Save("PdfEan13.png", ImageFormat.Png); 'Creates a new PdfEan13Barcode. Dim barcode As PdfEan13Barcode = New PdfEan13Barcode() 'Set the barcode text. barcode.Text = "4006381333931" 'Get the image for PdfEan13Barcode. Dim image As Image = barcode.ToImage() 'Save the image into Disk image.Save("PdfEan13.png", ImageFormat.Png) Represents the PdfEan8 barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the barcode text. barcode.Text = "1234567"; barcode.Location = new PointF(100,100); //Draw a barcode in the new Page. barcode.Draw(page); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the barcode text. barcode.Text = "1234567" barcode.Location = new PointF(100,100); 'Draw a barcode in the new Page. barcode.Draw(page) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the font to Ean8. barcode.Font = font; //Set the barcode text. barcode.Text = "1234567"; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the font to Ean8. barcode.Font = font 'Set the barcode text. barcode.Text = "1234567" 'Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Initializes a new instance of the class. The Barcode text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode("1234567"); //Set the font to Ean8. barcode.Font = font; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode("1234567") 'Set the font to Ean8. barcode.Font = font 'Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Draw PdfEan8Barcode based on float input values. The PDF page. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-top corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the barcode text. barcode.Text = "1234567"; //Draw a barcode in the new Page. barcode.Draw(page, 25, 100, 200, 200); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the barcode text. barcode.Text = "1234567" 'Draw a barcode in the new Page. barcode.Draw(page, 25, 100, 200, 200) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Draw PdfEan8Barcode based on location and size values. The PDF page. The location of the barcode on the PDF page. The size of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the barcode text. barcode.Text = "1234567"; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100), new SizeF(200,200)); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the barcode text. barcode.Text = "1234567" 'Draw a barcode in the new Page. barcode.Draw(page, New PointF(25, 200), New SizeF(200, 200)) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Draw PdfEan8Barcode based on rectangle input values. The PDF page. The bounds of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the barcode text. barcode.Text = "1234567"; //Draw a barcode in the new Page. barcode.Draw(page, new RectangleF(25, 100, 200, 200)); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the barcode text. barcode.Text = "1234567" 'Draw a barcode in the new Page. barcode.Draw(page, New RectangleF(25, 100, 200, 200)) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Draws the barcode on the . The PDF page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the barcode text. barcode.Text = "1234567"; barcode.Location = new PointF(100,100); //Draw a barcode in the new Page. barcode.Draw(page); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the barcode text. barcode.Text = "1234567" barcode.Location = new PointF(100,100); 'Draw a barcode in the new Page. barcode.Draw(page) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Draws the barcode on the at the specified location. The pdf page. The barcode location. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the barcode text. barcode.Text = "1234567"; //Draw a barcode in the new Page. barcode.Draw(page, new PointF(25, 100)); //Save the document to disk. document.Save("Ean8Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the barcode text. barcode.Text = "1234567" 'Draw a barcode in the new Page. barcode.Draw(page, New PointF(25, 100)) 'Save the document to disk. document.Save("Ean8Barcode.pdf") Exports the barcode as image. The barcode image. //Creates a new PdfEan8Barcode. PdfEan8Barcode barcode = new PdfEan8Barcode(); //Set the barcode text. barcode.Text = "1234567"; //Get the image for PdfEan8Barcode. Image image= barcode.ToImage(); //Save the image into Disk image.Save("PdfEan8.png", ImageFormat.Png); 'Creates a new PdfEan8Barcode. Dim barcode As PdfEan8Barcode = New PdfEan8Barcode() 'Set the barcode text. barcode.Text = "1234567" 'Get the image for PdfEan8Barcode. Dim image As Image = barcode.ToImage() 'Save the image into Disk image.Save("PdfEan8.png", ImageFormat.Png) Encode the raw data using the EAN-8 algorithm. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode(); //Set the barcode text location. code93.TextDisplayLocation = TextLocation.Bottom; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("Barcode.pdf"); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode() 'Set the barcode text location. code93.TextDisplayLocation = TextLocation.Bottom 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("Barcode.pdf") Displays, no text. Displays text, above the barcode. Displays text, at the bottom of the barcode. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PdfCode93Barcode. PdfCode93Barcode code93 = new PdfCode93Barcode(); //Set the barcode text alignment code93.TextAlignment = PdfBarcodeTextAlignment.Center; //Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)); //Save document to disk. document.Save("Barcode.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PdfCode93Barcode. Dim code39 As PdfCode93Barcode = New PdfCode93Barcode() 'Set the barcode text alignment code93.TextAlignment = PdfBarcodeTextAlignment.Center 'Draw a barcode in the new Page. code93.Draw(page, new PointF(25, 500)) 'Save the document. document.Save("Barcode.pdf") Displays the readable text on the left side of the barcode. Displays the readable text at the center of the barcode. Displays the readable text on the right side of the barcode. Specifies the data matrix barcode encoding. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Set data matrix barcode encoding. datamatrix.Encoding = PdfDataMatrixEncoding.ASCII; //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Set data matrix barcode encoding. datamatrix.Encoding = PdfDataMatrixEncoding.ASCII 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Encoding is choosen based on the data. Encoding is done by ASCII encoder. Encoding is done by Numeric encoder. Encoding is done by Base256 encode. Specifies the data matrix barcode size. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF datamatrix barcode. PdfDataMatrixBarcode datamatrix = new PdfDataMatrixBarcode(); //Sets the barcode text. datamatrix.Text = "Test"; //Set the dimention of the barcode. datamatrix.XDimension = 5; //Set barcode size. datamatrix.Size = PdfDataMatrixSize.Size20x20; //Set the barcode location. datamatrix.Location = new PointF(100, 100); //Draws a barcode on the new Page. datamatrix.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF datamatrix barcode. Dim datamatrix As New PdfDataMatrixBarcode() 'Sets the barcode text. datamatrix.Text = "Test" 'Set the dimention of the barcode. datamatrix.XDimension = 5 'Set barcode size. datamatrix.Size = PdfDataMatrixSize.Size20x20 'Set the barcode location. datamatrix.Location = New PointF(100, 100) 'Draws a barcode on the new Page. datamatrix.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Size is choosen based on the data. Square matrix with 10 rows and 10 columns. Square matrix with 12 rows and 12 columns. Square matrix with 14 rows and 14 columns. Square matrix with 16 rows and 16 columns. Square matrix with 18 rows and 18 columns. Square matrix with 20 rows and 20 columns. Square matrix with 22 rows and 22 columns. Square matrix with 24 rows and 24 columns. Square matrix with 26 rows and 26 columns. Square matrix with 32 rows and 32 columns. Square matrix with 36 rows and 36 columns. Square matrix with 40 rows and 40 columns. Square matrix with 44 rows and 44 columns. Square matrix with 48 rows and 48 columns. Square matrix with 52 rows and 52 columns. Square matrix with 64 rows and 64 columns. Square matrix with 72 rows and 72 columns. Square matrix with 80 rows and 80 columns. Square matrix with 88 rows and 88 columns. Square matrix with 96 rows and 96 columns. Square matrix with 104 rows and 104 columns. Square matrix with 120 rows and 120 columns. Square matrix with 132 rows and 132 columns. Square matrix with 144 rows and 144 columns. Rectangular matrix with 8 rows and 18 columns. Rectangular matrix with 8 rows and 32 columns. Rectangular matrix with 12 rows and 26 columns. Rectangular matrix with 12 rows and 36 columns. Rectangular matrix with 16 rows and 36 columns. Rectangular matrix with 16 rows and 48 columns. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the QR barcode version. qrBarcode.Version = QRCodeVersion.Version05; //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the QR barcode version. qrBarcode.Version = QRCodeVersion.Version05 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) Specifies the default version. Specifies version 1 (21x21 modules). Specifies version 2 (25x25 modules). Specifies version 3 (29x29 modules). Specifies version 4 (33x33 modules). Specifies version 5 (37x37 modules). Specifies version 6 (41x41 modules). Specifies version 7 (45x45 modules). Specifies version 8 (49x49 modules). Specifies version 9 (53x53 modules). Specifies version 10 (57x57 modules). Specifies version 11 (61x61 modules). Specifies version 12 (65x65 modules). Specifies version 13 (69x69 modules). Specifies version 14 (73x73 modules). Specifies version 15 (77x77 modules). Specifies version 16 (81x81 modules). Specifies version 17 (85x85 modules). Specifies version 18 (89x89 modules). Specifies version 19 (93x93 modules). Specifies version 20 (97x97 modules). Specifies version 21 (101x101 modules). Specifies version 22 (105x105 modules). Specifies version 23 (109x109 modules). Specifies version 24 (113x113 modules). Specifies version 25 (117x117 modules). Specifies version 26 (121x121 modules). Specifies version 27 (125x125 modules). Specifies version 28 (129x129 modules). Specifies version 29 (133x133 modules). Specifies version 30 (137x137 modules). Specifies version 31 (141x141 modules). Specifies version 32 (145x145 modules). Specifies version 33 (149x149 modules). Specifies version 34 (153x153 modules). Specifies version 35 (157x157 modules). Specifies version 36 (161x161 modules). Specifies version 37 (165x165 modules). Specifies version 38 (169x169 modules). Specifies version 39 (173x173 modules). Specifies version 40 (177x177 modules). //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the error correction level. qrBarcode.ErrorCorrectionLevel = PdfErrorCorrectionLevel.High; //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the error correction level. qrBarcode.ErrorCorrectionLevel = PdfErrorCorrectionLevel.High 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) The Recovery capacity is 7%(approx.) The Recovery capacity is 15%(approx.) The Recovery capacity is 25%(approx.) The Recovery capacity is 30%(approx.) //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a new PDF QR barcode. PdfQRBarcode qrBarcode = new PdfQRBarcode(); //Set text. qrBarcode.Text = "012345678"; //Set barcode size. qrBarcode.Size = new SizeF(200, 200); //Set the input mode. qrBarcode.InputMode = InputMode.BinaryMode; //Set the dimention of the barcode. qrBarcode.XDimension = 5; //Set the barcode location. qrBarcode.Location = new PointF(100, 100); //Draw the barcode to PDF page. qrBarcode.Draw(page); //Save document to disk. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creates a new PDF QR barcode. Dim qrBarcode As New PdfQRBarcode() 'Set text. qrBarcode.Text = "012345678" 'Set barcode size. qrBarcode.Size = New SizeF(200, 200) 'Set the input mode. qrBarcode.InputMode = InputMode.BinaryMode 'Set the dimention of the barcode. qrBarcode.XDimension = 5 'Set the barcode location. qrBarcode.Location = New PointF(100, 100) 'Draw the barcode to PDF page. qrBarcode.Draw(page) 'Save document to disk. document.Save("output.pdf") 'Close the document. document.Close(True) The Input only contains the Numeric Values(0,1,2,3,4,5,6,7,8,9). The Input may contain Numeric Values, Alphabets(Upper case only), SPACE, $, %, *, +, -, ., /, : The Input may contain all the ASCII values This mode is a combination of all modes Initilaize the cipher Process a block Reset the cipher. Algorithm name Size of the cipher Indicates whether this cipher can handle partial blocks. This class holds the name of the Syncfusion.Pdf.Base assembly and provides a helper routine that helps with resolving types when loading a serialization stream and when the framework probes for assemblies by reflection. The root namespace of this assembly. Used internally for locating resources within the assembly. The full name of this assembly without version information: "Syncfusion.Pdf.Base". A reference to the for the grid assembly. This delegate helps with resolving types and can be used as an event handler for a event. The source of the event. The event data with information about the type. A reference to the assembly where the type is located. Use this handler when reading back types from a serialization stream saved with an earlier version of this assembly. public static GridModel LoadSoap(Stream s) { try { AppDomain.CurrentDomain.AssemblyResolve += new ResolveEventHandler(GridAssembly.AssemblyResolver); SoapFormatter b = new SoapFormatter(); b.AssemblyFormat = FormatterAssemblyStyle.Simple; GridModel t = b.Deserialize(s) as GridModel; t.Modified = false; return t; } finally { AppDomain.CurrentDomain.AssemblyResolve -= new ResolveEventHandler(GridAssembly.AssemblyResolver); } } Configuration class for the PDF library. In the current version, there are no explicit settings. Adding this component from the toolbar allows you to configure your project for PDF support easily. Initializes a new instance of the class. Copyright notice for the library. Exception of this type is raised when annotation object is used incorrectly. The class represents general PDF document level exceptions. The inherited from the class The class represents general PDF exceptions. The inherited from the class PdfLoadedDocument document; try { //Load an existing document. document = new PdfLoadedDocument("input.pdf"); } catch (Syncfusion.Pdf.PdfException) { //Load an existing document. document = new PdfLoadedDocument("input.pdf", true); } document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument Try document = New PdfLoadedDocument("input.pdf") Catch exception As Syncfusion.Pdf.PdfException document = New PdfLoadedDocument("input.pdf", True) End Try 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Initializes object by default error message. PdfLoadedDocument document; try { //Load an existing document. document = new PdfLoadedDocument("input.pdf"); } catch (Syncfusion.Pdf.PdfException) { //Load an existing document. document = new PdfLoadedDocument("input.pdf", true); } document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument Try document = New PdfLoadedDocument("input.pdf") Catch exception As Syncfusion.Pdf.PdfException document = New PdfLoadedDocument("input.pdf", True) End Try 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Initializes object by specified error message. User defined error message. Initializes object by specified error message and inner exception object. User defined error message. The inner exception. Default exception message. Initializes object by default error message. Initializes object by default error message and inner exception object. The inner exception. Initializes object by specified error message. User defined error message. Initializes object by specified error message and inner exception object. User defined error message. The inner exception. Default exception message. Initializes object with default error message. Initializes object with default error message and inner exception object. The inner exception. Initializes object by specified error message. User defined error message. Initializes object with specified error message and inner exception object. User defined error message. The inner exception. Exception of this type is raised when the document contains object which are not supported by current document standard.Inherited from Default exception message. Initializes object with default error message. Initializes object with default error message and inner exception object. The inner exception. Initializes object by specified error message. User defined error message. Initializes object with specified error message and inner exception object. User defined error message. The inner exception. Indicates that the provided user or owner password is not valid. PdfLoadedDocument document; try { //Load an existing document. document = new PdfLoadedDocument("input.pdf"); } catch (Syncfusion.Pdf.PdfException) { //Load an existing document. document = new PdfLoadedDocument("input.pdf", true); } document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument Try document = New PdfLoadedDocument("input.pdf") Catch exception As Syncfusion.Pdf.PdfException document = New PdfLoadedDocument("input.pdf", True) End Try 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Initializes object for Pdf Invalid password Initializes object by specified Pdf Invalid password message User defined error message. Represents base class for all action types. Interface Defines the basic interace of the various Wrapper.. Gets the element. Next action to perform. Internal variable to store dictionary; Initializes a new instance of the class. Initializes an instance. Gets or sets the next action to be performed after the action represented by this instance. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = document.Pages.Add(); //Create a new sound action. PdfSoundAction soundAction = new PdfSoundAction(@"startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; soundAction.Mix = true; //Create a new PdfUriAction. PdfUriAction uriAction = new PdfUriAction("http://www.google.com"); //Set the next action to the soundAction. soundAction.Next = uriAction; //Set the action. document.Actions.AfterOpen = soundAction; //Save document to disk. document.Save("output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document. Dim page As PdfPage = document.Pages.Add() 'Create a new sound action. Dim soundAction As New PdfSoundAction("startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F soundAction.Mix = True 'Create a new PdfUriAction. Dim uriAction As New PdfUriAction("http://www.google.com") 'Set the next action to the soundAction. soundAction.[Next] = uriAction 'Set the action. document.Actions.AfterOpen = soundAction 'Save document to disk. document.Save("output.pdf") 'close the document. document.Close(True) Class Class Class Gets the dictionary. The dictionary. Gets the element. The Syncfusion.Pdf.Interactive namespace contains classes used to create interactive elements. Represents collection of actions. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField. PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Font = font; submitButton.Text = "Goto"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new page and adds it as the last page of the document. PdfPage pdfPages = document.Pages.Add(); //Create a new PdfGoToAction. PdfGoToAction gotoAction = new PdfGoToAction(pdfPages); //Add the gotoAction. submitButton.Actions.GotFocus = gotoAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("GoToAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField. Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Font = font submitButton.Text = "Goto" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new page and adds it as the last page of the document. Dim pdfPages As PdfPage = document.Pages.Add() 'Create a new PdfGoToAction. Dim gotoAction As New PdfGoToAction(pdfPages) 'Add the gotoAction. submitButton.Actions.GotFocus = gotoAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("GoToAction.pdf") 'close the document. document.Close(True) Class. The class used to handle the collection of PDF objects. //Create new document. PdfDocument document = new PdfDocument(); //Add new page. PdfPage page = document.Pages.Add(); //Add the first layer. PdfPageLayer layer = page.Layers.Add("Layer1"); //Get layer graphics. PdfGraphics graphics = layer.Graphics; graphics.TranslateTransform(100, 60); //Create new instance of PDF pen. PdfPen pen = new PdfPen(System.Drawing.Color.Red, 50); RectangleF bounds = new RectangleF(0, 0, 50, 50); //Draw arc. graphics.DrawArc(pen, bounds, 360, 360); //Add another layer on the page. PdfPageLayer layer2 = page.Layers.Add("Layer2"); graphics = layer2.Graphics; graphics.TranslateTransform(100, 180); //Draw ellipse. graphics.DrawEllipse(pen, bounds); //Get layer collection from page. PdfCollection collection = page.Layers; //Get the total count of layers. int count = collection.Count; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Add new page. Dim page As PdfPage = document.Pages.Add() 'Add the first layer. Dim layer As PdfPageLayer = page.Layers.Add("Layer1") 'Get layer graphics. Dim graphics As PdfGraphics = layer.Graphics graphics.TranslateTransform(100, 60) 'Create new instance of PDF pen. Dim pen As PdfPen = New PdfPen(System.Drawing.Color.Red, 50) Dim bounds As RectangleF = New RectangleF(0, 0, 50, 50) 'Draw arc. graphics.DrawArc(pen, bounds, 360, 360) 'Add another layer on the page. Dim layer2 As PdfPageLayer = page.Layers.Add("Layer2") graphics = layer2.Graphics graphics.TranslateTransform(100, 180) 'Draw ellipse. graphics.DrawEllipse(pen, bounds) 'Get layer collection from page. Dim collection As PdfCollection = page.Layers 'Get the total count of layers. Dim count As Integer = collection.Count 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class List of the collection. Initializes a new instance of the class. //Create new document. PdfDocument document = new PdfDocument(); //Add new page. PdfPage page = document.Pages.Add(); //Add the first layer. PdfPageLayer layer = page.Layers.Add("Layer1"); //Get layer graphics. PdfGraphics graphics = layer.Graphics; graphics.TranslateTransform(100, 60); //Create new instance of PDF pen. PdfPen pen = new PdfPen(System.Drawing.Color.Red, 50); RectangleF bounds = new RectangleF(0, 0, 50, 50); //Draw arc. graphics.DrawArc(pen, bounds, 360, 360); //Add another layer on the page. PdfPageLayer layer2 = page.Layers.Add("Layer2"); graphics = layer2.Graphics; graphics.TranslateTransform(100, 180); //Draw ellipse. graphics.DrawEllipse(pen, bounds); //Initialize new instance of PDF collection. PdfCollection collection = new PdfCollection(); //Get layer collection from the page. collection = page.Layers; //Get the total count of layers. int count = collection.Count; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Add new page. Dim page As PdfPage = document.Pages.Add() 'Add the first layer. Dim layer As PdfPageLayer = page.Layers.Add("Layer1") 'Get layer graphics. Dim graphics As PdfGraphics = layer.Graphics graphics.TranslateTransform(100, 60) 'Create new instance of PDF pen. Dim pen As PdfPen = New PdfPen(System.Drawing.Color.Red, 50) Dim bounds As RectangleF = New RectangleF(0, 0, 50, 50) 'Draw arc. graphics.DrawArc(pen, bounds, 360, 360) 'Add another layer on the page. Dim layer2 As PdfPageLayer = page.Layers.Add("Layer2") graphics = layer2.Graphics graphics.TranslateTransform(100, 180) 'Draw ellipse. graphics.DrawEllipse(pen, bounds) 'Initialize new instance of PDF collection. Dim collection As PdfCollection = New PdfCollection() 'Get layer collection from the page. collection = page.Layers 'Get the total count of layers. Dim count As Integer = collection.Count 'Get the total count of layers. Dim count As Integer = collection.Count 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Copies the elements of the ICollection to an Array, starting at a particular Array index. The one-dimensional Array that is the destination of the elements copied from ICollection. The Array must have zero-based indexing. The zero-based index in array at which copying begins. Returns an enumerator that iterates through a collection. Returns an enumerator that iterates through a collection. Clearing the Collection. Gets number of the elements in the collection. The total number of elements in the collection. //Create new document. PdfDocument document = new PdfDocument(); //Add new page. PdfPage page = document.Pages.Add(); //Add the first layer. PdfPageLayer layer = page.Layers.Add("Layer1"); //Get layer graphics. PdfGraphics graphics = layer.Graphics; graphics.TranslateTransform(100, 60); //Create new instance of PDF pen. PdfPen pen = new PdfPen(System.Drawing.Color.Red, 50); RectangleF bounds = new RectangleF(0, 0, 50, 50); //Draw arc. graphics.DrawArc(pen, bounds, 360, 360); //Add another layer on the page. PdfPageLayer layer2 = page.Layers.Add("Layer2"); graphics = layer2.Graphics; graphics.TranslateTransform(100, 180); //Draw ellipse. graphics.DrawEllipse(pen, bounds); //Get layer collection from page. PdfCollection collection = page.Layers; //Get the total count of layers. int count = collection.Count; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Add new page. Dim page As PdfPage = document.Pages.Add() 'Add the first layer. Dim layer As PdfPageLayer = page.Layers.Add("Layer1") 'Get layer graphics. Dim graphics As PdfGraphics = layer.Graphics graphics.TranslateTransform(100, 60) 'Create new instance of PDF pen. Dim pen As PdfPen = New PdfPen(System.Drawing.Color.Red, 50) Dim bounds As RectangleF = New RectangleF(0, 0, 50, 50) 'Draw arc. graphics.DrawArc(pen, bounds, 360, 360) 'Add another layer on the page. Dim layer2 As PdfPageLayer = page.Layers.Add("Layer2") graphics = layer2.Graphics graphics.TranslateTransform(100, 180) 'Draw ellipse. graphics.DrawEllipse(pen, bounds) 'Get layer collection from page. Dim collection As PdfCollection = page.Layers 'Get the total count of layers. Dim count As Integer = collection.Count 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets internal list of the collection. Array of actions. Adds the specified action to the collection The The index of the action in the collection Inserts the action at the specified position. The index in the collection where the action to be inserted The Gets the index of the action. The . Index of the action Determines whether the action is contained within collection. The . Value, indicating the presents of the action in collection. Clears the action collection. Removes the specified action from the collection The . Removes the action at the specified index from the collection The index. Initializes a new instance of the class. Adds the action. The action. Index of the inserted action. Inserts the action. The index. The action. Clear the collection. Removes the action. The action. Removes the action at the specified position. The index. Gets the at the specified index. the Represents the action on form fields. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField. PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); //Set the bounds submitButton.Bounds = new RectangleF(25, 160, 100, 20); //Set the submitButton Font. submitButton.Font = font; //Set the submit button text submitButton.Text = "Apply"; //Set the submit button back color submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfFormAction. PdfFormAction formAction = new PdfFormAction(); formAction.Include = true; //Set the submit button action. submitButton.Actions.GotFocus = formAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save and close the document document.Save("FormAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField. Dim submitButton As New PdfButtonField(page, "submitButton") 'Set the bounds submitButton.Bounds = New RectangleF(25, 160, 100, 20) 'Set the submitButton Font. submitButton.Font = font 'Set the submit button text submitButton.Text = "Apply" 'Set the submit button back color submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new PdfFormAction. Dim formAction As New PdfFormAction() formAction.Include = True 'Set the submit button action. submitButton.Actions.GotFocus = formAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save and close the document document.Save("FormAction.pdf") document.Close(True) Internal variable to store value indicating whether to include or exclude fields for resetting process. Internal variable to store fields affected by the action. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField. PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); //Set the bounds submitButton.Bounds = new RectangleF(25, 160, 100, 20); //Set the submitButton Font. submitButton.Font = font; //Set the submit button text submitButton.Text = "Apply"; //Set the submit button back color submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfFormAction. PdfFormAction formAction = new PdfFormAction(); formAction.Include = true; //Set the submit button action. submitButton.Actions.GotFocus = formAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save and close the document document.Save("FormAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField. Dim submitButton As New PdfButtonField(page, "submitButton") 'Set the bounds submitButton.Bounds = New RectangleF(25, 160, 100, 20) 'Set the submitButton Font. submitButton.Font = font 'Set the submit button text submitButton.Text = "Apply" 'Set the submit button back color submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new PdfFormAction. Dim formAction As New PdfFormAction() formAction.Include = True 'Set the submit button action. submitButton.Actions.GotFocus = formAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save and close the document document.Save("FormAction.pdf") document.Close(True) Gets or sets a value indicating whether fields contained in collection will be included for resetting or submitting. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField. PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); //Set the bounds submitButton.Bounds = new RectangleF(25, 160, 100, 20); //Set the submitButton Font. submitButton.Font = font; //Set the submit button text submitButton.Text = "Apply"; //Set the submit button back color submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfFormAction. PdfFormAction formAction = new PdfFormAction(); formAction.Include = true; //Set the submit button action. submitButton.Actions.GotFocus = formAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save and close the document document.Save("FormAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField. Dim submitButton As New PdfButtonField(page, "submitButton") 'Set the bounds submitButton.Bounds = New RectangleF(25, 160, 100, 20) 'Set the submitButton Font. submitButton.Font = font 'Set the submit button text submitButton.Text = "Apply" 'Set the submit button back color submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new PdfFormAction. Dim formAction As New PdfFormAction() formAction.Include = True 'Set the submit button action. submitButton.Actions.GotFocus = formAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save and close the document document.Save("FormAction.pdf") document.Close(True) If Include property is true, only the fields in this collection will be reset or submitted. If Include property is false, the fields in this collection are not reset or submitted and only the remaining form fields are reset or submitted. If the collection is null or empty, then all the form fields are reset and the Include property is ignored. true if include; otherwise, false. Gets the fields. The fields. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); //Create a new PdfButtonField. PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); //Set the submitButton Bounds. submitButton.Bounds = new RectangleF(25, 160, 100, 20); //Create a new PdfFormAction. PdfFormAction formAction = new PdfFormAction(); //Gets the FieldCollection from formAction PdfFieldCollection fields = formAction.Fields; //Set actions to submit button submitButton.Actions.GotFocus = formAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save document document.Save("FormAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField. Dim submitButton As New PdfButtonField(page, "submitButton") 'Set the submitButton Bounds. submitButton.Bounds = New RectangleF(25, 160, 100, 20) 'Create a new PdfFormAction. Dim formAction As New PdfFormAction() 'Gets the FieldCollection from formAction Dim fields As PdfFieldCollection = formAction.Fields 'Set actions to submit button submitButton.Actions.GotFocus = formAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save document document.Save("FormAction.pdf") document.Close(True) Represents an action which goes to a destination in the current document. This class is used to display the specified page in the current document. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Font = font; submitButton.Text = "Goto"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new page and adds it as the last page of the document PdfPage pdfPages = document.Pages.Add(); //Create a new PdfGoToAction PdfGoToAction gotoAction = new PdfGoToAction(pdfPages); //Add the gotoAction submitButton.Actions.GotFocus = gotoAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("GoToAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Font = font submitButton.Text = "Goto" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new page and adds it as the last page of the document Dim pdfPages As PdfPage = document.Pages.Add() 'Create a new PdfGoToAction Dim gotoAction As New PdfGoToAction(pdfPages) 'Add the gotoAction submitButton.Actions.GotFocus = gotoAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("GoToAction.pdf") document.Close(True) Class Class Class Internal variable to store action's destination. Initializes a new instance of the class with specified destination page. The destination to jump to. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Font = font; submitButton.Text = "Goto"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new page and adds it as the last page of the document PdfPage pdfPages = document.Pages.Add(); //Create a new PdfDestination PdfDestination destination = new PdfDestination(pdfPages); //Set the PdfDestinationMode destination.Mode = PdfDestinationMode.FitToPage; //Create a new PdfGoToAction PdfGoToAction gotoAction = new PdfGoToAction(destination); //Add the gotoAction submitButton.Actions.GotFocus = gotoAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("GoToAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Font = font submitButton.Text = "Goto" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new page and adds it as the last page of the document Dim pdfPages As PdfPage = document.Pages.Add() 'Create a new PdfDestination Dim destination As New PdfDestination(pdfPages) 'Set the PdfDestinationMode destination.Mode = PdfDestinationMode.FitToPage 'Create a new PdfGoToAction Dim gotoAction As New PdfGoToAction(destination) 'Add the gotoAction submitButton.Actions.GotFocus = gotoAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("GoToAction.pdf") document.Close(True) Class Class Class Initializes a new instance of the class with specified page. The page to navigate. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Font = font; submitButton.Text = "Goto"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new page and adds it as the last page of the document PdfPage pdfPages = document.Pages.Add(); //Create a new PdfGoToAction PdfGoToAction gotoAction = new PdfGoToAction(pdfPages); //Add the gotoAction submitButton.Actions.GotFocus = gotoAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("GoToAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Font = font submitButton.Text = "Goto" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new page and adds it as the last page of the document Dim pdfPages As PdfPage = document.Pages.Add() 'Create a new PdfGoToAction Dim gotoAction As New PdfGoToAction(pdfPages) 'Add the gotoAction submitButton.Actions.GotFocus = gotoAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("GoToAction.pdf") document.Close(True) Class Class Class Initializes instance. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Gets or sets the destination to be navigated. The to navigate. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Font = font; submitButton.Text = "Goto"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new page and adds it as the last page of the document PdfPage pdfPages = document.Pages.Add(); //Create a new PdfDestination PdfDestination destination = new PdfDestination(pdfPages); //Set the PdfDestinationMode destination.Mode = PdfDestinationMode.FitToPage; //Create a new PdfGoToAction PdfGoToAction gotoAction = new PdfGoToAction(pdfPages); //Set the destination gotoAction.Destination = destination; //Add the gotoAction submitButton.Actions.GotFocus = gotoAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("GoToAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Font = font submitButton.Text = "Goto" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new page and adds it as the last page of the document Dim pdfPages As PdfPage = document.Pages.Add() 'Create a new PdfDestination Dim destination As New PdfDestination(pdfPages) 'Set the PdfDestinationMode destination.Mode = PdfDestinationMode.FitToPage 'Create a new PdfGoToAction Dim gotoAction As New PdfGoToAction(pdfPages) 'Set the destination gotoAction.Destination = destination 'Add the gotoAction submitButton.Actions.GotFocus = gotoAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("GoToAction.pdf") document.Close(True) Class Class Class Class Represents an java script action in PDF document. This class is used to perform the java script action in PDF document. Please refer the UG docuemntation link for more details. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Add the JavaScript action document.Actions.AfterOpen = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Add the JavaScript action document.Actions.AfterOpen = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Internal variable to store java script code. Initializes a new instance of the class with java script code The java script code. A string value representing valid javascript code to be executed. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Add the JavaScript action document.Actions.AfterOpen = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Add the JavaScript action document.Actions.AfterOpen = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Initializes instance. Gets or sets the javascript code to be executed when this action is executed. A string value representing valid javascript code to be executed. /// //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Get the javascript code. string javascriptcode = javaScriptAction.JavaScript; //Add the JavaScript action document.Actions.AfterOpen = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Get the javascript code. Dim javascriptcode As String = javaScriptAction.JavaScript 'Add the JavaScript action document.Actions.AfterOpen = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Represents an action which launches an application or opens or prints a document. This class is used to allow the external file to execute. Please refer the UG docuemntation link for more details. //Create a new PDF document PdfDocument document = new PdfDocument(); //Create and add new launch Action to the document PdfLaunchAction action = new PdfLaunchAction("logo.png"); document.Actions.AfterOpen = action; //Save the document document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create and add new launch Action to the document Dim action As New PdfLaunchAction("logo.png") document.Actions.AfterOpen = action 'Save the document document.Save("LaunchAction.pdf") document.Close(True) Class Internal variable to store file specification. //Create a new PDF document PdfDocument document = new PdfDocument(); //Create and add new launch Action to the document PdfLaunchAction action = new PdfLaunchAction("logo.png"); document.Actions.AfterOpen = action; //Save the document document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create and add new launch Action to the document Dim action As New PdfLaunchAction("logo.png") document.Actions.AfterOpen = action 'Save the document document.Save("LaunchAction.pdf") document.Close(True) Class //Create a new PDF document PdfDocument document = new PdfDocument(); //Create and add new launch Action to the document PdfLaunchAction action = new PdfLaunchAction("../../Data/logo.png",PdfFilePathType.Absolute); document.Actions.AfterOpen = action; //Save the document document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create and add new launch Action to the document Dim action As New PdfLaunchAction("../../Data/logo.png",PdfFilePathType.Absolute) document.Actions.AfterOpen = action 'Save the document document.Save("LaunchAction.pdf") document.Close(True) Class Creates a Launch Action from loaded page Initializes instance. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. //Create a new PDF document PdfDocument document = new PdfDocument(); //Create and add new launch Action to the document PdfLaunchAction action = new PdfLaunchAction("logo.png"); //Get file name string fileName = action.FileName; document.Actions.AfterOpen = action; //Save the document document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create and add new launch Action to the document Dim action As New PdfLaunchAction("logo.png") 'Get file name Dim fileName As String = action.FileName document.Actions.AfterOpen = action 'Save the document document.Save("LaunchAction.pdf") document.Close(True) Class The class represents an named action which execute an action predefined by the viewer application. //Create a new document PdfDocument document = new PdfDocument(); document.Pages.Add(); document.Pages.Add(); //Create a named action PdfNamedAction namedAction = new PdfNamedAction(PdfActionDestination.LastPage); //Add the named action document.Actions.AfterOpen = namedAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() document.Pages.Add() document.Pages.Add() 'Create a named action Dim namedAction As New PdfNamedAction(PdfActionDestination.LastPage) 'Add the named action document.Actions.AfterOpen = namedAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Internal variable to store destination. Initializes a new instance of the class. The object representing destination of an action. //Create a new document PdfDocument document = new PdfDocument(); document.Pages.Add(); document.Pages.Add(); //Create a named action PdfNamedAction namedAction = new PdfNamedAction(PdfActionDestination.LastPage); //Set the destination namedAction.Destination = PdfActionDestination.NextPage; //Add the named action document.Actions.AfterOpen = namedAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() document.Pages.Add() document.Pages.Add() 'Create a named action Dim namedAction As New PdfNamedAction(PdfActionDestination.LastPage) 'Set the destination namedAction.Destination = PdfActionDestination.NextPage 'Add the named action document.Actions.AfterOpen = namedAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Initializes instance. Gets or sets the destination. The object representing destination of an action. //Create a new document PdfDocument document = new PdfDocument(); document.Pages.Add(); document.Pages.Add(); //Create a named action PdfNamedAction namedAction = new PdfNamedAction(PdfActionDestination.LastPage); //Set the destination namedAction.Destination = PdfActionDestination.NextPage; //Add the named action document.Actions.AfterOpen = namedAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() document.Pages.Add() document.Pages.Add() 'Create a named action Dim namedAction As New PdfNamedAction(PdfActionDestination.LastPage) 'Set the destination namedAction.Destination = PdfActionDestination.NextPage 'Add the named action document.Actions.AfterOpen = namedAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Represents additional actions of the annotations. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"Input.txt"); //Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("Output.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("Input.txt") 'Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("Output.pdf") document.Close(True) Class. Class. Class. Internal variable to store enter action. Internal variable to store leave action. Internal variable to store mouse down action. Internal variable to store mouse up action. Internal variable to store get focus action. Internal variable to store lost focus action. Internal variable to store dictionary. Initializes a new instance of the class. PdfAnnotationActions annotationActions = new PdfAnnotationActions(); //Create a new PdfJavaScriptAction PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); annotationActions.MouseEnter = javaAction; Dim annotationActions As PdfAnnotationActions = New PdfAnnotationActions() 'Create a new PdfJavaScriptAction. Dim javaAction As PdfJavaScriptAction = New PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")") annotationActions.MouseEnter = javaAction Class. Class. Gets or sets the action to be performed when the cursor enters the annotation�s active area. The mouse enter action. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseEnter = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseEnter = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") document.Close(True) Class. Class. Class. Gets or sets the action to be performed when the cursor exits the annotation�s active area. The mouse leave action. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") document.Close(True) Class. Class. Class. Gets or sets the action to be performed when the mouse button is pressed inside the annotation�s active area. The mouse down action. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseDown = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseDown = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") document.Close(True) Class. Class. Class. Gets or sets the action to be performed when the mouse button is released inside the annotation�s active area.. The mouse up action. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseUp = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseUp = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") document.Close(True) Class. Class. Class. Gets or sets the action to be performed when the annotation receives the input focus. The got focus action. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.GotFocus = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.GotFocus = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") document.Close(True) Class. Class. Class. Gets or sets the action to be performed when the annotation loses the input focus. The lost focus action. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.LostFocus = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Creata a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.LostFocus = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") document.Close(True) Class. Class. Class. Gets the element. Represents an actions for the PDF document. //Create a new PDF document PdfDocument document = new PdfDocument(); //Create and add new launch action to the document PdfLaunchAction action = new PdfLaunchAction("logo.png"); document.Actions.AfterOpen = action; //Save the document document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create and add new launch action to the document Dim action As New PdfLaunchAction("logo.png") document.Actions.AfterOpen = action 'Save the document document.Save("LaunchAction.pdf") document.Close(True) Class Class Internal variable to store dictionary wrapper. Internal variable to store action to be performed after the document is opened. Internal variable to store action to be perforemed before document closes. Internal variable to store action to be performed before the document saves. Internal variable to store action to be performed after the document saves. Internal variable to store action to be performed before the document prints. Internal variable to store action to be performed after the document prints. Internal variable to store catalog. Initializes a new instance of the class. The catalog. Get the dictionary value of the javascript action Removes javascript action from catalog. Get the dictionary value of the javascript action Get the dictionary value of the javascript action Get the dictionary value of the javascript action Get the dictionary value of the javascript action Get the dictionary value of the javascript action Gets or sets the to execute when the document is opened. A specifying the action to be executed when documents opens in the viewer. //Create a new PDF document PdfDocument document = new PdfDocument(); //Create and add new launch action to the document PdfLaunchAction action = new PdfLaunchAction("logo.png"); document.Actions.AfterOpen = action; //Save the document document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create and add new launch action to the document Dim action As New PdfLaunchAction("logo.png") document.Actions.AfterOpen = action 'Save the document document.Save("LaunchAction.pdf") document.Close(True) Class Class Gets or sets the java script action to be performed before the document is closed. A object specifying the action to be executed before the document is closed. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Add the JavaScript action document.Actions.BeforeClose = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Add the JavaScript action document.Actions.BeforeClose = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets the java script action to be performed before the document is saved. A object specifying the action to be executed before the document is saved. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Add the JavaScript action document.Actions.BeforeSave = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Add the JavaScript action document.Actions.BeforeSave = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets the jave script action to be performed after the document is saved. A object specifying the action to be executed after the document is saved. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Add the JavaScript action document.Actions.AfterSave = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Add the JavaScript action document.Actions.AfterSave = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets the action to be performed before the document is printed. A object specifying the action to be executed before the document is printed. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Add the JavaScript action document.Actions.BeforePrint = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Add the JavaScript action document.Actions.BeforePrint = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets the action to be performed after the document is printed. A object specifying the action to be executed after the document is printed. . //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create JavaScript action PdfJavaScriptAction javaScriptAction = new PdfJavaScriptAction("app.alert(\"Hello World!!!\")"); //Add the JavaScript action document.Actions.AfterPrint = javaScriptAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create JavaScript action Dim javaScriptAction As New PdfJavaScriptAction("app.alert(""Hello World!!!"")") 'Add the JavaScript action document.Actions.AfterPrint = javaScriptAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets the element. Represents actions to be performed as response to field events. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") 'close the document. document.Close(True) Class Class Internal variable to store annotation's actions. Internal variable to store dictionary. Internal variable to store key pressed action. Internal variable to store format action. Internal variable to store validate action. Internal variable to store calculate action. Initializes a new instance of the class with The . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the JavaScript action to be performed when the user types a keystroke into a text field or combo box or modifies the selection in a scrollable list box. This action can check the keystroke for validity and reject or modify it. A object specifying the action to be executed when the user types a keystroke. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Apply"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfJavaScriptAction PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); //Set the javaAction to submitButton submitButton.Actions.KeyPressed = javaAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("JavaScriptAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Apply" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new PdfJavaScriptAction Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") 'Set the javaAction to submitButton submitButton.Actions.KeyPressed = javaAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("JavaScriptAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the JavaScript action to be performed before the field is formatted to display its current value. This action can modify the field�s value before formatting. A object specifying the action to be executed for formatting the field value. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Apply"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfJavaScriptAction PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); //Set the javaAction to submitButton submitButton.Actions.Format = javaAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("JavaScriptAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Apply" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new PdfJavaScriptAction Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") 'Set the javaAction to submitButton submitButton.Actions.Format = javaAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("JavaScriptAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the JavaScript action to be performed when the field�s value is changed. This action can check the new value for validity. A object specifying the action to be executed for validating the field value. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Apply"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfJavaScriptAction PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); //Set the javaAction to submitButton submitButton.Actions.Validate = javaAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("JavaScriptAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Apply" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new PdfJavaScriptAction Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") 'Set the javaAction to submitButton submitButton.Actions.Validate = javaAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("JavaScriptAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the JavaScript action to be performed to recalculate the value of this field when that of another field changes. A object specifying the action to be executed for calculating the field value. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Apply"; submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfJavaScriptAction PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); //Set the javaAction to submitButton submitButton.Actions.Calculate = javaAction; //Add the submit button to the new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("JavaScriptAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Apply" submitButton.BackColor = New PdfColor(181, 191, 203) 'Create a new PdfJavaScriptAction Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") 'Set the javaAction to submitButton submitButton.Actions.Calculate = javaAction 'Add the submit button to the new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("JavaScriptAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the action to be performed when the mouse cursor enters the fields�s area. A specifying the action to be executed when the mouse enters the field's area. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseEnter = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseEnter = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the action to be performed when the cursor exits the fields�s area. A descendant specifying the action to be executed when the mouse leaves the field's area. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseLeave = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the action to be performed when the mouse button is released inside the field�s area. A specifying the action to be executed when the mouse button is released inside the field's area. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseUp = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseUp = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") close the document. document.Close(True) Class Class Gets or sets the action to be performed when the mouse button is pressed inside the field�s area. A specifying the action to be executed when the mouse button is pressed inside the field's area. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.MouseDown = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.MouseDown = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") 'close the document. document.Close(True) Class Class Gets or sets the action to be performed when the field receives the input focus. A specifying the action to be executed when the field receives the input focus. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.GotFocus = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.GotFocus = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") close the document. document.Close(True) Class Class Gets or sets the action to be performed when the field loses the input focus. A specifying the action to be executed when the field losts the input focus. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Launch"; //Create a new PdfLaunchAction PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt"); //Set the launch action to submit button submitButton.Actions.LostFocus = launchAction; //Add the submit button to a new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("LaunchAction.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Launch" 'Create a new PdfLaunchAction Dim launchAction As New PdfLaunchAction("..\..\Data\Sample.txt") 'Set the launch action to submit button submitButton.Actions.LostFocus = launchAction 'Add the submit button to a new document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("LaunchAction.pdf") 'close the document. document.Close(True) Class Class Gets the element. Represents PDF form's reset action,this action allows a user to reset the form fields to their default values. This class is used to reset all the form fields in the PDF document. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Apply"; //Create a new PdfResetAction PdfResetAction resetAction = new PdfResetAction(); //Set the resetAction to submitButton submitButton.Actions.GotFocus = resetAction; //Add the submit button to a document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("ResetAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Apply" 'Create a new PdfResetAction Dim resetAction As New PdfResetAction() 'Set the resetAction to submitButton submitButton.Actions.GotFocus = resetAction 'Add the submit button to a document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("ResetAction.pdf") document.Close(True) Class Class Class Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Apply"; //Create a new PdfResetAction PdfResetAction resetAction = new PdfResetAction(); //Set the resetAction to submitButton submitButton.Actions.GotFocus = resetAction; //Add the submit button to a document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("ResetAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Apply" 'Create a new PdfResetAction Dim resetAction As New PdfResetAction() 'Set the resetAction to submitButton submitButton.Actions.GotFocus = resetAction 'Add the submit button to a document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("ResetAction.pdf") document.Close(True) Class Class Class Initializes an instance. Gets or sets a value indicating whether fields contained in Fields collection will be included for resetting. true if include; otherwise, false. If Include property is true, only the fields in this collection will be reset. If Include property is false, the fields in this collection are not reset and only the remaining form fields are reset. If the collection is null or empty, then all the form fields are reset and the Include property is ignored. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a PdfButtonField PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(25, 160, 100, 20); submitButton.Text = "Apply"; //Create a new PdfResetAction PdfResetAction resetAction = new PdfResetAction(); resetAction.Include=true; //Set the resetAction to submitButton submitButton.Actions.GotFocus = resetAction; //Add the submit button to a document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("ResetAction.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a PdfButtonField Dim submitButton As New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(25, 160, 100, 20) submitButton.Text = "Apply" 'Create a new PdfResetAction Dim resetAction As New PdfResetAction() resetAction.Include=True 'Set the resetAction to submitButton submitButton.Actions.GotFocus = resetAction 'Add the submit button to a document. document.Form.Fields.Add(submitButton) 'Save document to disk. document.Save("ResetAction.pdf") document.Close(True) Class Class Class Represents the sound action,sound action plays a specified music file in the PDF document This class is used to plays a music file in PDF document. Please refer the UG docuemntation link for more details. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document.Save("Output.pdf") document.Close(True) Class Class Internal variable to store the volume at which to play the sound. Internal variable to store sound. Internal variable to store value whether to play sound synchronously or asynchronously. Internal variable to store value whether to repeat playing. Internal variable to store value whether to mix this sound with any other sound already playing. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Initializes instance. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Gets or sets the volume at which to play the sound, in the range -1.0 to 1.0. The volume of the sound. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class The name of the sound file. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; //Get the fileName form soundAction string fileName=soundAction.FileName; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F 'Get the fileName form soundAction Dim fileName as string =soundAction.FileName; 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets the sound. represents the . //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets a value whether to play the sound synchronously or asynchronously. If this flag is true, the viewer application retains control, allowing no further user interaction other than canceling the sound, until the sound has been completely played. Default value: false. true if synchronous; otherwise, false. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; soundAction.Synchronous = true; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F soundAction.Synchronous = True 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets a value indicating whether to repeat the sound indefinitely. If this entry is present, the property is ignored. Default value: false. true if repeat; otherwise, false. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; soundAction.Repeat = true; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F soundAction.Repeat = True 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets a value indicating whether to mix this sound with any other sound already playing. If this flag is false, any previously playing sound is stopped before starting this sound; this can be used to stop a repeating sound. Default value: false. true if mix; otherwise, false. //Create a new document PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create a sound action PdfSoundAction soundAction = new PdfSoundAction("../../Data/Startup.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; soundAction.Mix = true; //Set the sound action document.Actions.AfterOpen = soundAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create a sound action Dim soundAction As New PdfSoundAction("../../Data/Startup.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9F soundAction.Mix = True 'Set the sound action document.Actions.AfterOpen = soundAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Represents PDF form's submit action.submit action allows submission of data that is entered in the PDF form //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Internal variable to store file name. Internal variable to store submit flags. Internal variable to store Http method. Internal variable to store value whether to submit dates in canonical format. Internal variable to store value whether to submit mouse pointer coordinates. Internal variable to store value whether to submit fields without values. Internal variable to store value whether to submit incremental updates. Internal variable to store value indicating whether to submit annotations. Internal variable to store value indicating whether to exclude non-user annotations. Internal variable to store value indicating whether to embed form. Internal variable to store submit data format. Initializes a new instance of the class with URL to submit the form data The URL. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction(""http://www.example.com/Submit.aspx""); submitAction.DataFormat = SubmitDataFormat.Html; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Initializes instance. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Gets an Url address where the data should be transferred. An string value specifying the full URI for the internet resource. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction(""http://www.example.com/Submit.aspx""); submitAction.DataFormat = SubmitDataFormat.Html; string url=submitAction.Url; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Gets the url form the submit action Dim url As String=submitAction.Url submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the HTTP method. The HTTP method. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); //Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); //Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction(""http://www.example.com/Submit.aspx""); submitAction.DataFormat = SubmitDataFormat.Html; //Set the HttpMethod to submit action submitAction.HttpMethod=HttpMethod.Post; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() 'Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) 'Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") 'Set the HttpMethod to submit action submitAction.HttpMethod=HttpMethod.Post submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class If set, any submitted field values representing dates are converted to the standard format. The interpretation of a form field as a date is not specified explicitly in the field itself but only in the JavaScript code that processes it. true if use canonical date time format when submit data; otherwise, false. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; //Sets the CanonicalDateTimeFormat to submit action submitAction.CanonicalDateTimeFormat=true; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Sets the CanonicalDateTimeFormat to submit action submitAction.CanonicalDateTimeFormat=True submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether to submit mouse pointer coordinates. If set, the coordinates of the mouse click that caused the submit-form action are transmitted as part of the form data. The coordinate values are relative to the upper-left corner of the field�s widget annotation rectangle. true if submit coordinates; otherwise, false. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; 'Sets the SubmitCoordinates to submit action submitAction.SubmitCoordinates=true; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Sets the SubmitCoordinates to submit action submitAction.SubmitCoordinates=True submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether to submit fields without value. If set, all fields designated by the Fields collection and the flag are submitted, regardless of whether they have a value. For fields without a value, only the field name is transmitted. true if submit fields without value or the empty ones; otherwise, false. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; //Sets the IncludeNoValueFields to submit action submitAction.IncludeNoValueFields=true; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Sets the IncludeNoValueFields to submit action submitAction.IncludeNoValueFields=true submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether to submit form's incremental updates. Meaningful only when the form is being submitted in Forms Data Format. If set, the submitted FDF file includes the contents of all incremental updates to the underlying PDF document. If clear, the incremental updates are not included. true if incremental updates should be submitted; otherwise, false. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; //Set the IncludeIncrementalUpdates to submit action submitAction.IncludeIncrementalUpdates=true; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Sets the IncludeIncrementalUpdates to submit action submitAction.IncludeIncrementalUpdates=True submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether to submit annotations. Meaningful only when the form is being submitted in Forms Data Format. If set, the submitted FDF file includes all markup annotations in the underlying PDF document. If clear, markup annotations are not included. true if annotations should be submitted; otherwise, false. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; //Sets the IncludeAnnotations to submit action submitAction.IncludeAnnotations=true; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Sets the IncludeAnnotations to submit action submitAction.IncludeAnnotations=True submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether to exclude non user annotations form submit data stream. Meaningful only when the form is being submitted in Forms Data Format and the property is set to true. true if non user annotations should be excluded; otherwise, false. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; //Set the ExcludeNonUserAnnotations to submit action submitAction.ExcludeNonUserAnnotations=true; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Set the ExcludeNonUserAnnotations to submit action submitAction.ExcludeNonUserAnnotations=True submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the The //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Gets or sets a value indicating whether fields contained in Fields collection will be included for submitting. true if include; otherwise, false. If Include property is true, only the fields in this collection will be submitted. If Include property is false, the fields in this collection are not submitted and only the remaining form fields are submitted. If the collection is null or empty, then all the form fields are reset and the Include property is ignored. If the field has Export property set to false it will be not included for submitting in any case. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; //Sets the Include option to submit action submitAction.Include=true; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html 'Sets the Include option to submit action submitAction.Include=True submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Represents an action which resolves unique resource identifier. This class is used to create the hyper link in PDF document. Please refer the UG docuemntation link for more details. //Create a new document with PDF/A standard. PdfDocument document = new PdfDocument(); //Create a Uri action PdfUriAction uriAction = new PdfUriAction("http://www.google.com"); //Add the action to the document document.Actions.AfterOpen = uriAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document with PDF/A standard. Dim document As New PdfDocument() 'Create a Uri action Dim uriAction As New PdfUriAction("http://www.google.com") 'Add the action to the document document.Actions.AfterOpen = uriAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Internal variable to store unique resource identifier. Initializes a new instance of the class. //Create a new document with PDF/A standard. PdfDocument document = new PdfDocument(); //Create a Uri action PdfUriAction uriAction = new PdfUriAction(); //Add the action to the document document.Actions.AfterOpen = uriAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document with PDF/A standard. Dim document As New PdfDocument() 'Create a Uri action Dim uriAction As New PdfUriAction() 'Add the action to the document document.Actions.AfterOpen = uriAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Initializes a new instance of the class. The unique resource identifier. //Create a new document with PDF/A standard. PdfDocument document = new PdfDocument(); //Create a Uri action PdfUriAction uriAction = new PdfUriAction("http://www.google.com"); //Add the action to the document document.Actions.AfterOpen = uriAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document with PDF/A standard. Dim document As New PdfDocument() 'Create a Uri action Dim uriAction As New PdfUriAction("http://www.google.com") 'Add the action to the document document.Actions.AfterOpen = uriAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Initializes instance. Gets or sets the unique resource identifier. The unique resource identifier. //Create a new document with PDF/A standard. PdfDocument document = new PdfDocument(); //Create a Uri action PdfUriAction uriAction = new PdfUriAction(); uriAction.Uri="http://www.google.com"; //Add the action to the document document.Actions.AfterOpen = uriAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new document with PDF/A standard. Dim document As New PdfDocument() 'Create a Uri action Dim uriAction As New PdfUriAction() uriAction.Uri="http://www.google.com"; 'Add the action to the document document.Actions.AfterOpen = uriAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Specifies the file path type. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new PdfButtonField. PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); //Set the bounds to submitButton. submitButton.Bounds = new RectangleF(25, 160, 100, 20); //Set the submit button text. submitButton.Text = "Launch"; //Create a new PdfLaunchAction and set the PdfFilePathType. PdfLaunchAction launchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt",PdfFilePathType.Absolute); //Set the actions to submit button. submitButton.Actions.GotFocus = launchAction; //Save document to disk. document.Save("ActionDestination.pdf"); document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new PdfButtonField. Dim submitButton As PdfButtonField = New PdfButtonField(page, "submitButton") 'Set the bounds to submit button. submitButton.Bounds = New RectangleF(25, 160, 100, 20) 'Set the submit button text. submitButton.Text = "Launch" 'Create a new PdfLaunchAction and set the PdfFilePathType. Dim launchAction As PdfLaunchAction = new PdfLaunchAction(@"..\..\Data\Sample.txt",PdfFilePathType.Absolute) 'Set the actions to submit button. submitButton.Actions.GotFocus = launchAction 'Save document to disk. document.Save("ActionDestination.pdf") document.Close(True) Specifies the file location with out including the domain name. Specifies the location, including the domain name. Specifies the available named actions supported by the viewer. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); //Creates a new page page = document.Pages.Add(); //Creates a new page page = document.Pages.Add(); //Creates a new page page = document.Pages.Add(); //Creates a new page page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Create a new PdfButtonField. PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); //Set the bounds to submitButton. submitButton.Bounds = new RectangleF(25, 160, 100, 20); //Set the font to submitButton. submitButton.Font = font; //Sets the submit button text. submitButton.Text = "First Page"; //Set the back color to submit button. submitButton.BackColor = new PdfColor(181, 191, 203); //Create a new PdfNamedAction. PdfNamedAction namedAction = new PdfNamedAction(PdfActionDestination.FirstPage); //Set the named action destination. namedAction.Destination=PdfActionDestination.PrevPage; //Set the Actions to namedAction. submitButton.Actions.GotFocus = namedAction; //Add the submitButton to the new document. document.Form.Fields.Add(submitButton); //Save document to disk. document.Save("ActionDestination.pdf"); document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() 'Creates a new page page = document.Pages.Add() 'Creates a new page page = document.Pages.Add() 'Creates a new page page = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Create a new PdfButtonField Dim submitButton As PdfButtonField = New PdfButtonField(page, "submitButton") 'Set the bounds to submit button. submitButton.Bounds = New RectangleF(25, 160, 100, 20) 'Set the font to submitButton. submitButton.Font = font 'Sets the submit button text. submitButton.Text = "First Page" 'Set the back color to submit button. submitButton.BackColor = new PdfColor(181, 191, 203) 'Create a new PdfNamedAction Dim namedAction As PdfNamedAction = new PdfNamedAction(PdfActionDestination.FirstPage) 'Set the named action. namedAction.Destination=PdfActionDestination.PrevPage 'Set the Actions to namedAction. submitButton.Actions.GotFocus = namedAction 'Add the submitButton to the new document. document.Form.Fields.Add(gotoAction) 'Save document to disk. document.Save("ActionDestination.pdf") document.Close(True) Navigate to first page. Navigate to last page. Navigate to next page. Navigate to previous page. Specifies the available data formats for submitting the form data. If clear, the Fields array specifies which fields to include in the submission. (All descendants of the specified fields in the field hierarchy are submitted as well.) If set, the Fields array tells which fields to exclude. All fields in the document�s interactive form are submitted except those listed in the Fields array and those whose NoExport flag. If set, all fields designated by the Fields array and the Include/ Exclude flag are submitted, regardless of whether they have a value. For fields without a value, only the field name is transmitted. Meaningful only if the SubmitPDF and XFDF flags are clear. If set, field names and values are submitted in HTML Form format. If clear, they are submitted in Forms Data Format If set, field names and values are submitted using an HTTP GET request. If clear, they are submitted using a POST request. This flag is meaningful only when the ExportFormat flag is set; if ExportFormat is clear, this flag must also be clear. If set, the coordinates of the mouse click that caused the submitform action are transmitted as part of the form data. The coordinate values are relative to the upper-left corner of the field�s widget annotation rectangle. Meaningful only if the SubmitPDF flags are clear. If set, field names and values are submitted as XML Forms Data Format . Meaningful only when the form is being submitted in Forms Data Format (that is, when both the XFDF and ExportFormat flags are clear). If set, the submitted FDF file includes the contents of all incremental updates to the underlying PDF document, as contained in the Differences entry in the FDF dictionary. If clear, the incremental updates are not included. Meaningful only when the form is being submitted in Forms Data Format (that is, when both the XFDF and ExportFormat flags are clear). If set, the submitted FDF file includes all markup annotations in the underlying PDF document. If clear, markup annotations are not included. If set, the document is submitted as PDF, using the MIME content type application/pdf (described in Internet RFC 2045, Multipurpose Internet Mail Extensions (MIME), Part One: Format of Internet Message Bodies; see the Bibliography). If set, all other flags are ignored except GetMethod. If set, any submitted field values representing dates are converted to the standard format described. Meaningful only when the form is being submitted in Forms Data Format (that is, when both the XFDF and ExportFormat flags are clear) and the IncludeAnnotations flag is set. If set, it includes only those markup annotations whose T entry matches the name of the current user, as determined by the remote server to which the form is being submitted. Meaningful only when the form is being submitted in Forms Data Format (that is, when both the XFDF and ExportFormat flags are clear). If set, the submitted FDF excludes the F entry. Meaningful only when the form is being submitted in Forms Data Format (that is, when both the XFDF and ExportFormat flags are clear). If set, the F entry of the submitted FDF is a file specification containing an embedded file stream representing the PDF file from which the FDF is being submitted. Represents the activation states for the 3D annotation. This class is used to set the activation states for the 3D annotation. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); annotation.Activation = activation; annotation.Activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() annotation.Activation = activation annotation.Activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Internal variable to store the activation mode. Internal variable to store the activation state. Internal variable to store the deactivation mode. Internal variable to store the deactivation state. Internal variable reprsents whether to show toolbar or not. Internal variable reprsents whether to show UI or not. Internal variable to store dictionary. Initializes the new instance of class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); activation.ShowUI = false; annotation.Activation = activation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() activation.ShowUI = False annotation.Activation = activation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Initializes the instance. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the activation mode for the annotation. specifies the available modes for activating a 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); annotation.Activation = activation; annotation.Activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() annotation.Activation = activation annotation.Activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets or sets the deactivation mode for the annotation. specifies the available modes for deactivating a 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); //Sets the DeactivationState. activation.DeactivationMode = Pdf3DDeactivationMode.PageClose; activation.ShowToolbar = false; annotation.Activation = activation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() 'Sets the DeactivationState. activation.DeactivationMode = Pdf3DDeactivationMode.PageClose activation.ShowToolbar = False annotation.Activation = activation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Gets or sets the activation state for the annotation. specifies an activation state of the 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @”Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); annotation.Activation = activation; annotation.Activation.ActivationState = Pdf3DActivationState.Live; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150),”Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() annotation.Activation = activation annotation.Activation.ActivationState = Pdf3DActivationState.Live page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets or sets a value indicating whether the toolbar should be displayed when the annotation is activated or not. If true, a toolbar should be displayed by default when the annotation is activated and given focus. If false, a toolbar should not be displayed by default. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation Pdf3DActivation activation = new Pdf3DActivation(); activation.ShowToolbar = false; annotation.Activation = activation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() activation.ShowToolbar = False annotation.Activation = activation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets or sets a value indicating whether the UI for managing the 3D artwork should be displayed when the annotation is activated. If true, the user interface should be made visible when the annotation is activated. If false, the user interface should not be made visible by default. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); activation.ShowUI = false; annotation.Activation = activation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() activation.ShowUI = False annotation.Activation = activation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets the dictionary. The dictionary. Gets the element. Represents the lighting to apply for the 3D artwork. //Create a new Pdf3DAnimation Pdf3DAnimation animation = new Pdf3DAnimation(PDF3DAnimationType.Linear); animation.Type = PDF3DAnimationType.Linear; 'Create a new Pdf3DAnimation Dim animation As Pdf3DAnimation = New Pdf3DAnimation(PDF3DAnimationType.Linear) animation.Type = PDF3DAnimationType.Linear; Initializes a new instance of the class. //Create a new Pdf3DAnimation Pdf3DAnimation animation = new Pdf3DAnimation(); animation.Type = PDF3DAnimationType.Linear; 'Create a new Pdf3DAnimation Dim animation As Pdf3DAnimation = New Pdf3DAnimation() animation.Type = PDF3DAnimationType.Linear Initializes a new instance of the class with specified 3D animation type. PDF 3D Animation Type. //Create a new Pdf3DAnimation Pdf3DAnimation animation = new Pdf3DAnimation(PDF3DAnimationType.Linear); animation.Type = PDF3DAnimationType.Linear; 'Create a new Pdf3DAnimation Dim animation As Pdf3DAnimation = New Pdf3DAnimation(PDF3DAnimationType.Linear) animation.Type = PDF3DAnimationType.Linear Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the type of the animation. //Create a new Pdf3DAnimation Pdf3DAnimation animation = new Pdf3DAnimation(PDF3DAnimationType.Linear); animation.Type = PDF3DAnimationType.Linear; 'Create a new Pdf3DAnimation Dim animation As Pdf3DAnimation = New Pdf3DAnimation(PDF3DAnimationType.Linear) animation.Type = PDF3DAnimationType.Linear Gets or sets the play count. //Create a new Pdf3DAnimation Pdf3DAnimation animation = new Pdf3DAnimation(PDF3DAnimationType.Linear); animation.PlayCount =10; 'Create a new Pdf3DAnimation Dim animation As Pdf3DAnimation = New Pdf3DAnimation(PDF3DAnimationType.Linear) animation.PlayCount =10 Gets or sets the rendering opacity. A positive number specifying the time multiplier to be used when running the animation. A value greater than one shortens the time it takes to play the animation, or effectively speeds up the animation. //Create a new Pdf3DAnimation Pdf3DAnimation animation = new Pdf3DAnimation(PDF3DAnimationType.Linear); animation.Type = 10f; 'Create a new Pdf3DAnimation Dim animation As Pdf3DAnimation = New Pdf3DAnimation(PDF3DAnimationType.Linear) animation.Type = 10f Gets the dictionary. The dictionary. Gets the element. Represents the background appearance for 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground. Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Create a view. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground. Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Create a view. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Max value of color channel. Internal variable to store dictionary. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground. Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Create a view. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground. Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Create a view. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes a new instance of the class with specified color. The object specifying the background color for the 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground. Pdf3DBackground background = new Pdf3DBackground(color); background.ApplyToEntireAnnotation = true; //Create a view. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground. Dim background As New Pdf3DBackground(color) background.ApplyToEntireAnnotation = True 'Create a view. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the background color of the 3D artwork. The object specifying the background color for the 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground. Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Create a view. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground. Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Create a view. Dim view As New Pdf3DView() view.Background = background annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets or sets a value indicating how the background is applied. True if the background is applied to entire annotation, false if the background is applied to annotation's 3D view box only. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground. Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Create a view. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground. Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Create a view. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets the dictionary. The dictionary. Gets the element. Represents the base class for 3D annotation. Internal variable to store stream. Name of the file. Handles the BeginSave event of the Stream control. The source of the event. The instance containing the event data. Saves an instance. Gets or sets the stream. The stream. The name of the file. Gets the element. Represents the clipping portion of the 3D artwork for the purpose of showing artwork cross sections. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Internal variable to store dictionary. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the center of the cutting plane. The list of float value specifies the cutting plane of the section. A three element array specifying the center of rotation on the cutting plane in world space coordinates. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Center = new float[] { 40, 40, 40 }; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Center = New Single() { 40, 40, 40 } 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets or sets the cutting plane color. specifies the cutting plane color of the 3D cross section. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets or sets the intersection color. specifies the intersection color of the 3D cross section. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets or sets a value indicating whether the intersection of cutting plane with 3D artwork is visible. True if the intersection is visible , otherwise false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets or sets the cutting plane opacity. A float value specifies the opacity of the annotation. The opacity is given in percents, 100 is full opacity, 0 is no opacity. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets or sets the orientation of the cutting plane. A three-element array specifying the orientation of the cutting plane in world space, where each value represents the orientation in relation to the X, Y, and Z axes, respectively. If the array has more than 3 elements, only the first 3 will be considered. Exactly one of the values must be null, indicating an initial state of the cutting plane that is perpendicular to the corresponding axis and clipping all geometry on the positive side of that axis. The other two values must be numbers indicating the rotation of the plane, in degrees, around their corresponding axes. The order in which these rotations are applied should match the order in which the values appear in the array. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); object[] orientation = crossSection.Orientation; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CrossSections.Add(crossSection) annotation.Views.Add(view) object[] orientation = crossSection.Orientation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets the dictionary. The dictionary. Gets the element. Represents the collection of objects. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DCrossSectionCollection. Pdf3DCrossSectionCollection crossSectionCollection = view.CrossSections; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() 'Create a new Pdf3DCrossSectionCollection. Dim crossSectionCollection As Pdf3DCrossSectionCollection = view.CrossSections annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Adds the specified value. The 3D cross section to be added. The index value of the section to be added. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); crossSection.Opacity = 100; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CrossSections.Add(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) crossSection.Opacity = 100 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } view.CrossSections.Add(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Class Determines whether the specified cross section is in collection. The if it contains the specified value, set to true. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); bool isExist = view.CrossSections.Contains(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) 'Create a new Pdf3DView. Dim view As New Pdf3DView() Dim isExist As Boolean = view.CrossSections.Contains(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Class Searches and finds the index of the specified cross section from the collection. The . PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); //Add the cross section view.CrossSections.Add(crossSection); //Get the index of specified crossSection int index = view.CrossSections.IndexOf(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) 'Create a new Pdf3DView Dim view As New Pdf3DView() 'Add the cross section view.CrossSections.Add(crossSection) 'Get the index of specified crossSection Dim index As Integer = view.CrossSections.IndexOf(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Inserts the cross section at specified index. The index. The value. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); //Insert the cross section at specified index view.CrossSections.Insert(0,crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) 'Create a new Pdf3DView Dim view As New Pdf3DView() 'Insert the cross section at specified index view.CrossSections.Insert(0,crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Removes the specified cross section form the collection. The cross section to be removed. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DCrossSection. Pdf3DCrossSection crossSection = new Pdf3DCrossSection(); crossSection.Color = new PdfColor(Color.Blue); crossSection.IntersectionIsVisible = true; crossSection.IntersectionColor = new PdfColor(Color.Red); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CrossSections.Add(crossSection); //Remove the cross section view.CrossSections.Remove(crossSection); annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DCrossSection. Dim crossSection As New Pdf3DCrossSection() crossSection.Color = New PdfColor(Color.Blue) crossSection.IntersectionIsVisible = True crossSection.IntersectionColor = New PdfColor(Color.Red) 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CrossSections.Add(crossSection) 'Remove the cross section view.CrossSections.Remove(crossSection) annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Gets or sets the at the specified index. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); //Create a new Pdf3DCrossSectionCollection. Pdf3DCrossSectionCollection crossSectionCollection = view.CrossSections; Pdf3DCrossSection crosssection =view.CrossSections[0]; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() 'Create a new Pdf3DCrossSectionCollection. Dim crossSectionCollection As Pdf3DCrossSectionCollection = view.CrossSections Dim crosssection As Pdf3DCrossSection=view.CrossSections[0] annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Represents the lighting scheme for the 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DLighting. Pdf3DLighting lighting = new Pdf3DLighting(); lighting.Style = Pdf3DLightingStyle.CAD; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new Single[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.LightingScheme = lighting; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DLighting. Dim lighting As New Pdf3DLighting() lighting.Style = Pdf3DLightingStyle.CAD 'Create a new Pdf3DView. Dim view As New Pdf3DView view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.LightingScheme = lighting annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Internal variable to store dictionary. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DLighting. Pdf3DLighting lighting = new Pdf3DLighting(); lighting.Style = Pdf3DLightingStyle.CAD; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.LightingScheme = lighting; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DLighting. Dim lighting As New Pdf3DLighting() lighting.Style = Pdf3DLightingStyle.CAD 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.LightingScheme = lighting annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes a new instance of the class with specified lighting style. The object specifies the style of the 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DLighting. Pdf3DLighting lighting = new Pdf3DLighting(Pdf3DLightingStyle.CAD); //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.LightingScheme = lighting; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annot As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DLighting. Dim lighting As New Pdf3DLighting(Pdf3DLightingStyle.CAD) 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.LightingScheme = lighting annotation.Views.Add(view) page.Annotations.Add(annot) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the lighting style of the 3D artwork. The specifies the available styles for applying light to 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DLighting. Pdf3DLighting lighting = new Pdf3DLighting(); lighting.Style = Pdf3DLightingStyle.CAD; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.LightingScheme = lighting; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DLighting. Dim lighting As New Pdf3DLighting() lighting.Style = Pdf3DLightingStyle.CAD 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.LightingScheme = lighting annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets the dictionary. The dictionary. Gets the element. Represents the particular areas of 3D artwork and the opacity and visibility with which individual nodes are displayed. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "node"; node.Opacity = 1000f; view.Nodes.Add(node); //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "node" node.Opacity = 1000f view.Nodes.Add(node) 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Internal variable to store dictionary. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; view.Nodes.Add(node); //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True view.Nodes.Add(node) 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets a value indicating whether the node is visible or not. True if the node is visible , otherwise false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "node"; node.Opacity = 1000f; view.Nodes.Add(node); //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "node" node.Opacity = 1000f view.Nodes.Add(node) 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the node name. The name of the 3D node. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "node"; node.Opacity = 1000f; view.Nodes.Add(node); //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "node" node.Opacity = 1000f view.Nodes.Add(node) 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the cutting plane opacity. A number indicating the opacity of the cutting plane using a standard additive blend mode. The opacity is given in percents, 100 is full opacity, 0 is no opacity. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "node"; node.Opacity = 1000f; view.Nodes.Add(node); //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "node" node.Opacity = 1000f view.Nodes.Add(node) 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the 3D transformation matrix. A 12-element 3D transformation matrix that specifies the position and orientation of this node, relative to its parent, in world coordinates. If the array has more than 12 elements, only the first 12 will be considered. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Matrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Nodes.Add(node); //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Matrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } view.Nodes.Add(node) 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets the dictionary. The dictionary. Gets the element. Represents a collection of objects. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; view.Nodes.Add(node); //Adds a pdf3d view. annotation.Views.Add(view); //Adds a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True view.Nodes.Add(node) 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Adds the specified node into the collection. The The index of the node to be added. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; view.Nodes.Add(node); //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True view.Nodes.Add(node) 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Determines whether the node is in the collection. The node to search for. if it contains the specified value, set to true. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "Near View"; node.Opacity = 100; node.Matrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //create the node collection Pdf3DNodeCollection nodecollection = new Pdf3DNodeCollection(); nodecollection.Add(node); bool exist = nodecollection.Contains(node); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "Near View" node.Opacity = 100 node.Matrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } 'create the node collection Dim nodecollection As New Pdf3DNodeCollection() nodecollection.Add(node) Dim exist As Boolean = nodecollection.Contains(node) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Searches and finds the index of the specified node from the collection. The node to be searched. The index value of the node to be searched from the collection. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "Near View"; node.Opacity = 100; node.Matrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //create the node collection Pdf3DNodeCollection nodecollection = new Pdf3DNodeCollection(); nodecollection.Add(node); //Search the index of the node int index = nodecollection.IndexOf(node); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "Near View" node.Opacity = 100 node.Matrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } 'create the node collection Dim nodecollection As New Pdf3DNodeCollection() nodecollection.Add(node) 'Search the index of the node Dim index As Integer = nodecollection.IndexOf(node) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Inserts the specified index. The index. The value. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "Near View"; node.Opacity = 100; node.Matrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //create the node collection Pdf3DNodeCollection nodecollection = new Pdf3DNodeCollection(); nodecollection.Add(node); //insert the node nodecollection.Insert(0, node); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "Near View" node.Opacity = 100 node.Matrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } 'create the node collection Dim nodecollection As New Pdf3DNodeCollection() nodecollection.Add(node) 'insert the node nodecollection.Insert(0, node) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Removes the specified value. The value. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; node.Name = "Near View"; node.Opacity = 100; node.Matrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //create the node collection Pdf3DNodeCollection nodecollection = new Pdf3DNodeCollection(); nodecollection.Add(node); //Remove the node nodecollection.Remove(node); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True node.Name = "Near View" node.Opacity = 100 node.Matrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } 'create the node collection Dim nodecollection As New Pdf3DNodeCollection() nodecollection.Add(node) 'Remove the node nodecollection.Remove(node) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the at the specified index. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; //Create a new Pdf3DNode. Pdf3DNode node = new Pdf3DNode(); node.Visible = true; view.Nodes.Add(node); //Adds a pdf3d view. annotation.Views.Add(view); //Adds a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} 'Create a new Pdf3DNode. Dim node As New Pdf3DNode() node.Visible = True view.Nodes.Add(node) 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Represents the mapping of 3D camera co-ordinates onto the target coordinate system of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Internal variable to store type. Internal variable to store Clip Style. Internal variable to store Ortho Scale mode. Internal variable to store far Clip Distance. Internal variable to store field Of View. Internal variable to store near Clip Distance. Internal variable to store scaling. Internal variable to store dictionary. Initializes a new instance of the class. Initializes a new instance of the class with specified projection type. The Pdf3D Projection Type. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.FarClipDistance = 10; projection.Scaling = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.FarClipDistance = 10 projection.Scaling = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the type of the projection. It specifies the projection type of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the projection ClipStyle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the scale mode for orthographic projections. It specifies the scale mode of the . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the far clipping distance. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.FarClipDistance = 10; projection.Scaling = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.FarClipDistance = 10 projection.Scaling = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the field of view. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the near clipping distance. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the projection scaling. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.FarClipDistance = 10; projection.Scaling = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.FarClipDistance = 10 projection.Scaling = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets the dictionary. The dictionary. Gets the element. Represents the rendering mode of the 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10.0F 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Internal variable to store style. Internal variable to store face Color. Internal variable to store auxilary Color. Internal variable to store opacity. Internal variable to store crease Value. Internal variable to store dictionary. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10.0F 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes a new instance of the class with specified rendering style. The object specifies the rendering style of the 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(Pdf3DRenderStyle.Solid); renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.Opacity = 100f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode(Pdf3DRenderStyle.Solid) renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.Opacity = 100.0F 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the type of the projection. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView. Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10.0F 'Create a new Pdf3DView. Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the auxiliary color. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10.0F 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the face color. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10.0F 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the crease value. The crease value is specified in degrees, from 0 to 360. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10.0F 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the rendering opacity. The opacity is given in percents, 100 is full opacity, 0 is no opacity. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(Pdf3DRenderStyle.Solid); renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.Opacity = 100f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode(Pdf3DRenderStyle.Solid) renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.Opacity = 100.0F 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets the dictionary. The dictionary. Gets the element. Represents a attributes to be applied to the virtual camera associated with a 3D annotation. This class is used to represents the 3D view for . Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode Pdf3DRendermode rendermode = new Pdf3DRendermode(); rendermode.Style = Pdf3DRenderStyle.Solid; rendermode.AuxilaryColor = new PdfColor(Color.Green); rendermode.FaceColor = new PdfColor(Color.Black); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Creates a new Pdf3DLighting Pdf3DLighting lighting = new Pdf3DLighting(); lighting.Style = Pdf3DLightingStyle.CAD; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; view.LightingScheme = lighting; view.RenderMode = rendermode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode Dim rendermode As New Pdf3DRendermode() rendermode.Style = Pdf3DRenderStyle.Solid rendermode.AuxilaryColor = New PdfColor(Color.Green) rendermode.FaceColor = New PdfColor(Color.Black) Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Creates a new Pdf3DLighting Dim lighting As New Pdf3DLighting() lighting.Style = Pdf3DLightingStyle.CAD 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background view.LightingScheme = lighting view.RenderMode = rendermode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Class Internal variable to store 3d Background. Internal variable to store 3d Cross Section Collection. Internal variable to store centre to World Matrix. Internal variable to store 3d Lighting. Internal variable to store 3d Node Collection. Internal variable to store 3d Projection. Internal variable to store 3d Render mode. Internal variable to store reset Nodes State. Internal variable to store centre of orbit. Internal variable to store external name. Internal variable to store internal name. Internal variable to store view node name. Internal variable to store dictionary. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode Pdf3DRendermode rendermode = new Pdf3DRendermode(); rendermode.Style = Pdf3DRenderStyle.Solid; rendermode.AuxilaryColor = new PdfColor(Color.Green); rendermode.FaceColor = new PdfColor(Color.Black); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Creates a new Pdf3DLighting Pdf3DLighting lighting = new Pdf3DLighting(); lighting.Style = Pdf3DLightingStyle.CAD; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; view.LightingScheme = lighting; view.RenderMode = rendermode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode Dim rendermode As New Pdf3DRendermode() rendermode.Style = Pdf3DRenderStyle.Solid rendermode.AuxilaryColor = New PdfColor(Color.Green) rendermode.FaceColor = New PdfColor(Color.Black) Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Creates a new Pdf3DLighting Dim lighting As New Pdf3DLighting() lighting.Style = Pdf3DLightingStyle.CAD 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background view.LightingScheme = lighting view.RenderMode = rendermode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Class Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the background for this view. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the 3D transformation matrix. A 12-element 3D transformation matrix that specifies a position and orientation of the camera in world coordinates. If the array has more than 12 elements, only the first 12 will be considered. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Creates a new Pdf3DBackground Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color =new PdfColor(Color.Blue); float[] matrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -300.669f, -112.432f, 45.6829f }; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = matrix; view.Background = background; view.CenterOfOrbit = 10f; view.ExternalName = "Near View"; //Adds a pdf3d view. annotation.Views.Add(view); //Adds a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Creates a new Pdf3DBackground Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = New PdfColor(Color.Blue) Dim matrix() As Single = { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -300.669f, -112.432f, 45.6829f } 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = matrix view.Background = background view.CenterOfOrbit = 10f view.ExternalName = "Near View" 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the center of orbit for 3D artwork. A non-negative number indicating a distance in the camera coordinate system along the z axis to the center of orbit for this view. If this value is negative, the viewer application must determine the center of orbit. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.CenterOfOrbit = 10f; //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As Pdf3DAnnotation = New Pdf3DAnnotation(New RectangleF(10, 300, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As Pdf3DView = New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.CenterOfOrbit = 10f 'Adds a pdf3d view annotation.Views.Add(view) 'Draw a annotation into the new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets the list of cross sections for this view. A list of PDF3DCrossSection objects available for this view. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; Pdf3DCrossSectionCollection crossSectionCollection = view.CrossSections; //Adds a pdf3d view. annotation.Views.Add(view); //Adds a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} Dim crossSectionCollection As Pdf3DCrossSectionCollection = view.CrossSections 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the view's external name. The external name of the view, suitable for presentation in a user interface. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.ExternalName = "Near View"; //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.ExternalName = "Near View" 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the view's internal name. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.InternalName = Guid.NewGuid().ToString("N"); //Adds a pdf3d view. annotation.Views.Add(view); //Adds a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.InternalName = Guid.NewGuid().ToString("N") 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the lighting scheme for this view. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode Pdf3DRendermode rendermode = new Pdf3DRendermode(); rendermode.Style = Pdf3DRenderStyle.Solid; rendermode.AuxilaryColor = new PdfColor(Color.Green); rendermode.FaceColor = new PdfColor(Color.Black); PdfColor color = new PdfColor(Color.Silver); //Create a new Pdf3DBackground Pdf3DBackground background = new Pdf3DBackground(); background.ApplyToEntireAnnotation = true; background.Color = color; //Creates a new Pdf3DLighting Pdf3DLighting lighting = new Pdf3DLighting(); lighting.Style = Pdf3DLightingStyle.CAD; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Background = background; view.LightingScheme = lighting; view.RenderMode = rendermode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode Dim rendermode As New Pdf3DRendermode() rendermode.Style = Pdf3DRenderStyle.Solid rendermode.AuxilaryColor = New PdfColor(Color.Green) rendermode.FaceColor = New PdfColor(Color.Black) Dim color As New PdfColor(Color.Silver) 'Create a new Pdf3DBackground Dim background As New Pdf3DBackground() background.ApplyToEntireAnnotation = True background.Color = color 'Creates a new Pdf3DLighting Dim lighting As New Pdf3DLighting() lighting.Style = Pdf3DLightingStyle.CAD 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Background = background view.LightingScheme = lighting view.RenderMode = rendermode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Class Gets the list of 3D nodes for this view. A list of PDF3DNode objects available for this view. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.ResetNodesState = true; Pdf3DNodeCollection nodes = view.Nodes; //Adds a pdf3d view. annotation.Views.Add(view); //Adds a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.ResetNodesState = True Dim nodes As Pdf3DNodeCollection = view.Nodes 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the projection for this view. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(Pdf3DProjectionType.Perspective); projection.FieldOfView = 10; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.FarClipDistance = 10; projection.Scaling = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Add the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection(Pdf3DProjectionType.Perspective) projection.FieldOfView = 10 projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.FarClipDistance = 10 projection.Scaling = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Add the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the rendering mode for this view. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10f 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets a value indicating whether nodes specified in the Nodes collection are returned to their original states (as specified in the 3D artwork) before applying transformation matrices and opacity settings specified in the node dictionaries. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } view.ResetNodesState = true; //Adds a pdf3d view. annotation.Views.Add(view); //Adds a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.ResetNodesState = True 'Adds a pdf3d view. annotation.Views.Add(view) 'Adds a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the name of the view node. The view node in the content stream defines all the properties for viewing the 3D artwork. If both ViewNodeName and CameraToWorldMatrix are specified, then ViewNodeName takes precedence. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; string name = view.ViewNodeName; //Add a pdf3d view. annotation.Views.Add(view); //Add a annotation. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } Dim name As String = view.ViewNodeName 'Add a pdf3d view. annotation.Views.Add(view) 'Add a annotation. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets the dictionary. The pdf3d view dictionary. Gets the element. Represents a collection of Pdf3DView objects. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Creates a new Pdf3DView Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName="Near View"; defaultView.CameraToWorldMatrix=new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit=131.695f; annotation.Views.Add(defaultView); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Creates a new Pdf3DView Dim defaultView As New Pdf3DView() defaultView.ExternalName="Near View" defaultView.CameraToWorldMatrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit=131.695f annotation.Views.Add(defaultView) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Adds the specified 3d view into collection. The index of the added to the collection. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Creates a new Pdf3DView Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName="Near View"; defaultView.CameraToWorldMatrix=new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit=131.695f; annotation.Views.Add(defaultView); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Creates a new Pdf3DView Dim defaultView As New Pdf3DView() defaultView.ExternalName="Near View" defaultView.CameraToWorldMatrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit=131.695f annotation.Views.Add(defaultView) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Determines whether the specified view is in collection. The . if it contains the specified value, set to true. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create the view Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName="Near View"; defaultView.CameraToWorldMatrix=new Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit=131.695f; annotation.Views.Add(defaultView); //check the specified view exists in the list or not bool exist=annotation.Views.Contains(defaultView); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create the view Dim defaultView As New Pdf3DView() defaultView.ExternalName="Near View" defaultView.CameraToWorldMatrix = New Single() With { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit=131.695f annotation.Views.Add(defaultView) 'check the specified view exists in the list or not Dim exist As Boolean=annotation.Views.Contains(defaultView) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class search and find the Pdf3DView object. Pdf3DView //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create the view Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName = "Near View"; defaultView.CameraToWorldMatrix = new Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; annotation.Views.Add(defaultView); //Get the index of specified view int index = annotation.Views.IndexOf(defaultView); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create the view Dim defaultView As New Pdf3DView() defaultView.ExternalName = "Near View" defaultView.CameraToWorldMatrix = New Single() With { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f annotation.Views.Add(defaultView) 'Get the index of specified view Dim index As Integer = annotation.Views.IndexOf(defaultView) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Inserts the view at specified index. The index where to insert the element. The view to be inserted in the collection.. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create the view Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName = "Near View"; defaultView.CameraToWorldMatrix = new Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; //Insert the view at specified index annotation.Views.Insert(1,defaultView); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create the view Dim defaultView As New Pdf3DView() defaultView.ExternalName = "Near View" defaultView.CameraToWorldMatrix = New Single() With { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f 'Insert the view at specified index annotation.Views.Insert(1,defaultView) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Removes the specified value from the collection. The Pdf3DView object. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create the view Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName = "Near View"; defaultView.CameraToWorldMatrix = new Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; annotation.Views.Add(defaultView); //Remove the specified view annotation.Views.Remove(defaultView); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create the view Dim defaultView As New Pdf3DView() defaultView.ExternalName = "Near View" defaultView.CameraToWorldMatrix = New Single() With { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f annotation.Views.Add(defaultView) 'Remove the specified view annotation.Views.Remove(defaultView) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets or sets the at the specified index. Pdf3DView //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a Pdf3DView Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName="Near View"; defaultView.CameraToWorldMatrix= new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; annotation.Views.Add(defaultView); page.Annotations.Add(annotation); Pdf3DView view=annotation.Views[0] as Pdf3DView; //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a Pdf3DView Dim defaultView As New Pdf3DView() defaultView.ExternalName="Near View" defaultView.CameraToWorldMatrix= New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f annotation.Views.Add(defaultView) page.Annotations.Add(annotation) Dim view As Pdf3DView=TryCast(annotation.Views(0), Pdf3DView) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Specifies an activation state of the 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @”Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); //Set the activation to the annotation. annotation.Activation = activation; annotation.Activation.ActivationState = Pdf3DActivationState.Live; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150),"Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() 'Set the activation to the annotation. annotation.Activation = activation annotation.Activation.ActivationState = Pdf3DActivationState.Live page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Represents that the state in which the artwork has been read and a run-time instance of the artwork has been created. In this state, it can be rendered but script-driven real-time modifications (that is, animations) are disabled. Represents that the artwork is instantiated, and it is being modified in real time to achieve some animation effect. In the case of key frame animation, the artwork is live while it is playing and then reverts to an instantiated state when playing completes or is stopped. Specifies the available modes for activating a 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Set the activation to the annotation. annotation.Activation = activation; //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); annotation.Activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() 'Set the activation to the annotation. annotation.Activation = activation annotation.Activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Represents that the annotation should be activated as soon as the page containing the annotation is opened. Represents that the annotation should be activated as soon as any part of the page containing the annotation becomes visible. Represents that the annotation should remain inactive until explicitly activated by a script or user action. Specifies the available modes for deactivating a 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); //Sets the DeactivationState. activation.DeactivationMode = Pdf3DDeactivationMode.PageClose; activation.ShowToolbar = false; annotation.Activation = activation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() 'Sets the DeactivationState. activation.DeactivationMode = Pdf3DDeactivationMode.PageClose activation.ShowToolbar = False annotation.Activation = activation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Represents that the annotation should be deactivated as soon as the page is closed. Represents that the annotation should be deactivated as soon as the page containing the annotation becomes invisible. Represents that the annotation should remain active until explicitly deactivated by a script or user action. Specifies the available states upon deactivating a 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); activation.DeactivationState = Pdf3DDeactivationState.Uninstantiated; //Set the activation to the annotation. annotation.Activation = activation; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() activation.DeactivationState = Pdf3DDeactivationState.Uninstantiated //Set the activation to the annotation. annotation.Activation = activation page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Represents the initial state of the artwork before it has been used in any way. Represents that the state in which the artwork has been read and a run-time instance of the artwork has been created. In this state, it can be rendered but script-driven real-time modifications (that is, animations) are disabled. Represents that the artwork is instantiated, and it is being modified in real time to achieve some animation effect. In the case of key frame animation, the artwork is live while it is playing and then reverts to an instantiated state when playing completes or is stopped. Specifies the available styles for applying light to 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create pdfFont, pdfFont style and brush. Font font = new Font("Calibri", 11, FontStyle.Regular); PdfFont pdfFont = new PdfTrueTypeFont(font, false); PdfBrush brush = new PdfSolidBrush(Color.DarkBlue); //Create 3D activation. Pdf3DActivation activation = new Pdf3DActivation(); activation.ActivationMode = Pdf3DActivationMode.PageVisible; activation.ShowToolbar = true; pdf3dAnnotation.Activation = activation; Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName = "Near View"; defaultView.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; //Set the 3D background. Pdf3DBackground background=new Pdf3DBackground(); background.Color=new PdfColor(Color.Blue); defaultView.Background = background; //Set the projection. Pdf3DProjection projection = new Pdf3DProjection(Pdf3DProjectionType.Orthographic); defaultView.Projection = projection; //Set the render mode. Pdf3DRendermode renderMode = new Pdf3DRendermode(Pdf3DRenderStyle.Solid); defaultView.RenderMode = renderMode; //Set the lighting scheme. Pdf3DLighting lighting = new Pdf3DLighting(Pdf3DLightingStyle.Night); defaultView.LightingScheme = lighting; //Add the view. pdf3dAnnotation.Views.Add(defaultView); pdf3dAnnotation.Appearance.Normal.Graphics.DrawString("Click to activate", pdfFont, brush, new PointF(40, 40)); //Add this annotation to a new page. pdf3dAnnotation.Appearance.Normal.Draw(page, new PointF(pdf3dAnnotation.Location.X, pdf3dAnnotation.Location.Y)); //Adds annotation to page. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create pdfFont, pdfFont style and brush. Dim font As New Font("Calibri", 11, FontStyle.Regular) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) Dim brush As PdfBrush = New PdfSolidBrush(Color.DarkBlue) Dim activation As New Pdf3DActivation() activation.ActivationMode = Pdf3DActivationMode.PageVisible activation.ShowToolbar = True pdf3dAnnotation.Activation = activation Dim defaultView As New Pdf3DView() defaultView.ExternalName = "Near View" defaultView.CameraToWorldMatrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f 'Set the 3D background. Dim background As New Pdf3DBackground() background.Color = New PdfColor(Color.Blue) defaultView.Background = background 'Set the projection. Dim projection As New Pdf3DProjection(Pdf3DProjectionType.Orthographic) defaultView.Projection = projection 'Set the render mode. Dim renderMode As New Pdf3DRendermode(Pdf3DRenderStyle.Solid) defaultView.RenderMode = renderMode 'Set the lighting scheme. Dim lighting As New Pdf3DLighting(Pdf3DLightingStyle.Night) defaultView.LightingScheme = lighting 'Add the view. pdf3dAnnotation.Views.Add(defaultView) pdf3dAnnotation.Appearance.Normal.Graphics.DrawString("Click to activate", pdfFont, brush, New PointF(40, 40)) 'Add this annotation to a new page. pdf3dAnnotation.Appearance.Normal.Draw(page, New PointF(pdf3dAnnotation.Location.X, pdf3dAnnotation.Location.Y)) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Class Class Class Class The Lights as specified in the 3D artwork. The lighting specified in the 3D artwork is ignored. Three blue-grey infinite lights. Three light-grey infinite lights. One yellow, one aqua, and one blue infinite light. Three grey infinite lights. One red, one green, and one blue infinite light. Three blue infinite lights. Three red infinite lights. Six grey infinite lights aligned with the major axes. Three grey infinite lights and one light attached to the camera. Single infinite light attached to the camera. Specifies the available clipping style of the 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() {-0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Class Represents the explicit Clipping style. Represents the automatic Clipping style. Specifies the available Ortho projection scaling mode of the 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Class Scale to fit the width of the annotation. Scale to fit the height of the annotation. Scale to fit the lesser of width or height of the annotation. Scale to fit the greater of width or height of the annotation. No scaling should occur due to binding. Specifies the available projection type of the 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3DAnnotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DProjection. Pdf3DProjection projection = new Pdf3DProjection(); projection.ProjectionType = Pdf3DProjectionType.Perspective; projection.FieldOfView = 10; projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width; projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar; projection.NearClipDistance = 10; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.Projection = projection; annotation.Views.Add(view); //Adds the annotation in a new page. page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3DAnnotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DProjection. Dim projection As New Pdf3DProjection() projection.ProjectionType = Pdf3DProjectionType.Perspective projection.FieldOfView = 10 projection.OrthoScaleMode = Pdf3DProjectionOrthoScaleMode.Width projection.ClipStyle = Pdf3DProjectionClipStyle.ExplicitNearFar projection.NearClipDistance = 10 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.Projection = projection annotation.Views.Add(view) 'Adds the annotation in a new page. page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Class Represents Orthographic projection Represents Perspective projection. Specifies the type of the 3D annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DActivation. Pdf3DActivation activation = new Pdf3DActivation(); activation.DeactivationState = Pdf3DDeactivationState.Uninstantiated; //Set the activation to the annotation. annotation.Activation = activation; annotation.Type = Pdf3DAnnotationType.U3D; page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DActivation. Dim activation As New Pdf3DActivation() activation.DeactivationState = Pdf3DDeactivationState.Uninstantiated //Set the activation to the annotation. annotation.Activation = activation annotation.Type = Pdf3DAnnotationType.U3D page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Enum Represents U3D Represents PRC Specifies the available rendering style of the 3D artwork. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new Pdf3D Annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new Pdf3DRendermode. Pdf3DRendermode renderMode = new Pdf3DRendermode(); renderMode.Style = Pdf3DRenderStyle.Solid; renderMode.AuxilaryColor = new PdfColor(Color.Green); renderMode.FaceColor = new PdfColor(Color.Black); renderMode.CreaseValue = 10f; //Create a new Pdf3DView Pdf3DView view = new Pdf3DView(); view.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; view.RenderMode = renderMode; annotation.Views.Add(view); page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new Pdf3D Annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new Pdf3DRendermode. Dim renderMode As New Pdf3DRendermode() renderMode.Style = Pdf3DRenderStyle.Solid renderMode.AuxilaryColor = New PdfColor(Color.Green) renderMode.FaceColor = New PdfColor(Color.Black) renderMode.CreaseValue = 10f 'Create a new Pdf3DView Dim view As New Pdf3DView() view.CameraToWorldMatrix = New Single() { -0.382684F, 0.92388F, -7.66026E-08F, 0.18024F, 0.0746579F, 0.980785F, 0.906127F, 0.37533F, -0.19509F, -100, -112.432F, 45.6829F} view.RenderMode = renderMode annotation.Views.Add(view) page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Class Displays textured and lit geometric shapes. In the case of artwork that conforms to the Universal 3D File Format specification, these shapes are triangles. Displays textured and lit geometric shapes (triangles) with single color edges on top of them. Displays textured and lit geometric shapes (triangles) with an added level of transparency. Displays textured and lit geometric shapes (triangles) with an added level of transparency, with single color opaque edges on top of it. Displays the bounding box edges of each node, aligned with the axes of the local coordinate space for that node. Displays bounding boxes faces of each node, aligned with the axes of the local coordinate space for that node, with an added level of transparency. Displays bounding boxes edges and faces of each node, aligned with the axes of the local coordinate space for that node, with an added level of transparency. Displays only edges in a single color. Displays only edges, though interpolates their color between their two vertices and applies lighting. Displays edges in a single color, though removes back-facing and obscured edges. Displays only vertices in a single color. Displays only vertices, though uses their vertex color and applies lighting. Displays silhouette edges with surfaces, removes obscured lines. Displays silhouette edges with lit and textured surfaces, removes obscured lines. Displays silhouette edges with lit and textured surfaces and an additional emissive term to remove poorly lit areas of the artwork. Specifies the available animation style for rendering the 3D artwork. //Create a new Pdf3DAnimation Pdf3DAnimation animation = new Pdf3DAnimation(PDF3DAnimationType.Linear); animation.Type = PDF3DAnimationType.Linear; 'Create a new Pdf3DAnimation Dim animation As Pdf3DAnimation = New Pdf3DAnimation(PDF3DAnimationType.Linear) animation.Type = PDF3DAnimationType.Linear Represents that the Key frame animations should not be driven directly by the viewer application. This value is used by documents that are intended to drive animations through an alternate means, such as JavaScript. Represents that the Key frame animations are driven linearly from beginning to end. This animation style results in a repetitive play through of the animation, such as in a walking motion. Represents that the Key frame animations should oscillate along their time range. This animation style results in a back-and-forth playing of the animation, such as exploding or collapsing parts. Represents the annotation with associated action. Class Represents base class for link annotations with associated action. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(rectangle, @"Input.png"); //Set a action to file link annotation. PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); fileLinkAnnotation.Action = javaAction; //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new file link annotation. Dim fileLinkAnnotation As New PdfFileLinkAnnotation(rectangle, "Input.png") 'Set a action to file link annotation. Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") fileLinkAnnotation.Action = javaAction 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Represents the base class for the link annotations. Class Represents the base class for annotation objects. Class Class Class Class Class Class Class Class Class Indicates Caption name Color of the annotation. Border of the annotation. Bounds of the annotation. Parent page of the annotation. Text of the annotation. Author of the annotation. Subject of the annotation. ModifiedDate of the annotation. NAnootation's style flags. Internal variable to store dictionary. To specifying the Inner color with which to fill the annotation Opacity of the annotation. Indicates annotation is flatten or not. Indicate popups annotation is flatten or not. Annotation's appearance. Internal field to check whether any annotation is modified. Internal field used to indicate to set popup annotation. Internal field for annotation document layer Indicates angle for rotation for annotation Indicates rotation is modified Indicates page margin Indicates annotation review history Indicates annotation comments status Indicates collection holds annotation gets the rotated angle of the annotation. Specifies whether to set the default appearance for the annotation or not. Creates the Constructors. Creates new annotation object with the specified PDF page and text. The page where annotation to be added. The text. Creates new annotation object with the specified bounds. Bounds of the annotation. Initializes a new instance of the class. The annotation's dictionary. The document cross table. The annotation's bounds. Sets related page of the annotation. The page. creates an appearance for annotation used to represent overlaytext of redaction annotation Used to represent the text color of the redaction annotation. Used to represent the font of the redaction annotation Used to represent the text alignment of the redaction annotation. Used to represent the border of the redaction annotation. Used to represent the text repeat of the redaction annotation. creates an border appearance for annotation Used to represent the border color of the redaction annotation. Used to represent the border of the redaction annotation. Find record token Operator Converting Color to hex color Removes annotation from page. Annotation to be removed. Sets the location. The location. Sets the proper name to the field. The annotation's text. Sets the size. The size. Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. returns annotation bounds. Flatten annotation author field the annotation's author text the annotation's subject text the annotation's bounds the annotation's background color brush annotation's brush annotation's page height appearance of an annotation's border Flatten annotation subject field the annotation's subject text the annotation's bounds annotation's page Flatten the Popup annotation Flatten the Popup window annotation's page the annotation's color the annotation's bounds appearance of an annotation's border the annotation's author text the annotation's subject text the annotation's text Save graphics state annotation's blendmode Set the values associated with the specified key. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation and set properties. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points); lineAnnotation.Text = "Line Annotation"; //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; lineAnnotation.Author = "LineAnnotaion"; lineAnnotation.ModifiedDate = DateTime.Now; lineAnnotation.Subject = "LineAnnoataion"; lineAnnotation.SetValues("State", "CustomState"); lineAnnotation.SetValues("StateModel", "CustomStateModel"); page.Annotations.Add(lineAnnotation); document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim lineAnnotation As PdfLineAnnotation = New PdfLineAnnotation(points) lineAnnotation.Text = "Line Annotation" Dim lineBorder As LineBorder = New LineBorder lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension lineAnnotation.Author = "LineAnnotaion" lineAnnotation.ModifiedDate = DateTime.Now lineAnnotation.Subject = "LineAnnoataion" lineAnnotation.SetValues("State", "CustomState") lineAnnotation.SetValues("StateModel", "CustomStateModel") page.Annotations.Add(lineAnnotation) document.Save("Output.pdf") document.Close(true) Obtain Document layer from annotation Finds the excepted object with layer collection Obtain the rotated angle for annotation Calculates the minX, minY, maxX and maxY of the rotated bounds. Bounding box of a rectangular bounds Get rotated transformation matrix. Obtain the roated angle for annotation Returns the appearance matrix is rotated or not Returns the rotated angle value from page graphics Returns the annotation appearance location to be draw in page Returns the annotation appearance location to be draw in page Set the matrix for annotation appearance Obtain the native rectangle for annotation Identify the annotation present in collection Obtain crop or media box values from page Obtain page margin Obtain annotation need flatten Obtain layer graphics To find new axis point using existing axis point ,angle and length. The float array. The double value. The double value. new axis point. To set a line style in measurement annotation. Add Popup annotation in annotation collection Gets or sets the annotation color. The which draws the outline of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Set the color. soundAnnotation.Color = new PdfColor(Color.Red); //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a a new rectangle. Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30); 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Set the color. soundAnnotation.Color = New PdfColor(Color.Red) 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets or Sets the Opacity of the annotation. Get or set the inner color of the annotation. Default color is transparent Gets or sets annotation's border properties like width, horizontal radius etc. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Assign the border to sound annotation. soundAnnotation.Border = new PdfAnnotationBorder(5); //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Assign the border to sound annotation. soundAnnotation.Border = New PdfAnnotationBorder(5) 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets annotation's bounds in the PDF page. The bounds of the annotation. If this property is not set, the bounds are calculated automatically based on Location property and content of annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Assign the bounds to sound annotation. soundAnnotation.Bounds=new RectangleF(50, 100, 30, 30); //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Assign the bounds to sound annotation. soundAnnotation.Bounds=New RectangleF(50, 100, 30, 30) 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets the location of the annotation. The position of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Assign the location to sound annotation. soundAnnotation.Location=new PointF(50, 100); //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Assign the location to sound annotation. soundAnnotation.Location=New PointF(50, 100) 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets the size of the annotation. The size of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Assign the size to sound annotation. soundAnnotation.Size=new SizeF(50, 50); //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Assign the size to sound annotation. soundAnnotation.Size=New SizeF(50, 50) 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets a page of the annotation. Read-Only. The where the annotation is to be added. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Gets the page. PdfPage pdfPage=soundAnnotation.Page; //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Gets the page. Dim pdfPage As PdfPage =soundAnnotation.Page 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets a loaded page of the annotation. Gets or sets content of the annotation. The string value specifies the text of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Set the text to sound annotation. soundAnnotation.Text="Sound Annotation"; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Set the text to sound annotation. soundAnnotation.Text="Sound Annotation" 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets or Sets the Author of the annotation. Gets or Sets the Subject of the annotation. Gets or Sets the ModifiedDate of the annotation. Gets or sets the annotation flags. The Specifies the enumeration of the annotation flags. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"input.wav"); //Set the annotation flags to sound annotation. soundAnnotation.AnnotationFlags = PdfAnnotationFlags.Print; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "input.wav") 'Set the annotation flags to sound annotation. soundAnnotation.AnnotationFlags = PdfAnnotationFlags.Print 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Gets the dictionary. The dictionary. Gets or sets the boolean flag to flatten the annotations. Get or set flatten the Popups annotations Gets or sets the tag for annotation Gets or sets appearance of the annotation. Specifies if any annotation is changed since loading that would affect the appearance. Get or set Popup annotations Get or set the PdfLayer to the annotation Gets or sets the rotation of PDF annotation Gets or sets the Name to the uniquely identifying annotations. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and PDF font style . Font font = new Font("Calibri", 10, FontStyle.Bold); PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Create a new pdf brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); //Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a pdf text markup annotation . PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, new PointF(175, 40), pdfFont); markupAnnotation.TextMarkupColor = new PdfColor(Color.BlueViolet); markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; markupAnnotation.Name = "d5daa6e7-4a7d-4e33-0168-4c4211e2c491"; //Add this annotation to a new page. page.Annotations.Add(markupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create pdf font and pdf font style . Dim font As New Font("Calibri", 10, FontStyle.Bold) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Create a new PDF brush. Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) 'Create a pdf text markup annotation . Dim markupAnnotation As New PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, New PointF(175, 40), pdfFont) markupAnnotation.TextMarkupColor = New PdfColor(Color.BlueViolet) markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight markupAnnotation.Name = "d5daa6e7-4a7d-4e33-0168-4c4211e2c491" 'Add this annotation to a new page. page.Annotations.Add(markupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Gets or sets the rotation of PDF annotation Gets the element. Highlight Mode of the annotation. Initializes new instance of class. Initializes new instance of class with specified bounds. The bounds of the annotation. Initializes annotation object. Gets Hightlight Mode of the annotation. Gets or sets the highlight mode of the link annotation. The enumeration value which sets the highlight mode. Internal variable to store annotation's action. Initializes a new instance of the class with specified bounds. The bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(rectangle, "input.png"); //Set a action to file link annotation. PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); fileLinkAnnotation.Action = javaAction; //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new file link annotation. Dim fileLinkAnnotation As New PdfFileLinkAnnotation(rectangle, "input.png") 'Set a action to file link annotation. Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") fileLinkAnnotation.Action = javaAction 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Initializes a new instance of the class with specified bounds and action to be performed. The bounds specifies the location of the drawn text. The specifies an action to be executed when the link is activated. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF bounds = new RectangleF(10, 40, 30, 30); //Create a new file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(bounds, "Input.png"); //Set a action to file link annotation. PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); fileLinkAnnotation.Action = javaAction; //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new file link annotation. Dim fileLinkAnnotation As New PdfFileLinkAnnotation(rectangle, "Input.png") 'Set a action to file link annotation. Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") fileLinkAnnotation.Action = javaAction 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Gets or sets the action for the link annotation. The action to be executed when the link is activated. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(rectangle, @"Input.png"); //Set a action to file link annotation. PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); fileLinkAnnotation.Action = javaAction; //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new file link annotation. Dim fileLinkAnnotation As New PdfFileLinkAnnotation(rectangle, "Input.png") 'Set a action to file link annotation. Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") fileLinkAnnotation.Action = javaAction 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Initializes a new instance of the class with specified bounds and action. The bounds of the annotation. The PDF action that can be triggered with different actions. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF actionAnnotationBounds = new RectangleF(10, 40, 100, 30); //Set the go to action PdfGoToAction gotoAction = new PdfGoToAction(page); //Set destination location. gotoAction.Destination = new PdfDestination(page, new PointF(0, 100)); //Create Action annotation. PdfActionAnnotation actionAnnotation = new PdfActionAnnotation(actionAnnotationBounds, gotoAction); //Set the text and font. actionAnnotation.Color = new PdfColor(Color.Red); //Add this annotation to a new page. page.Annotations.Add(actionAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim actionAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Set the go to action. Dim gotoAction As New PdfGoToAction(page) 'Set destination location gotoAction.Destination = New PdfDestination(page, New PointF(0, 100)) 'Create Action annotation. Dim actionAnnotation As New PdfActionAnnotation(actionAnnotationBounds, gotoAction) 'Set the text and font. actionAnnotation.Color = New PdfColor(Color.Red) 'Add this annotation to a new page. page.Annotations.Add(actionAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class. Class. Saves annotation object. Represents the appearance of an annotation's border. This class is used to create the annotation border to . Please refer the UG docuemntation link for more details. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation"); //Set the annotation border to popup annotation. popupAnnotation.Border = new PdfAnnotationBorder(4, 0, 0); //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation") 'Set the annotation border to popup annotation. popupAnnotation.Border = New PdfAnnotationBorder(4, 0, 0) 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Horizontal corner radius. Vertical corner radius. Width of the border. Pdf primitive representing this object. Initializes a new instance of the class. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation"); //Set the annotation border. popupAnnotation.Border = new PdfAnnotationBorder(); //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation") 'Set the annotation border. popupAnnotation.Border = New PdfAnnotationBorder() 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Initializes a new instance of the class with specified border width. A float value specifying the width of the annotation's border. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation"); //Set the annotation border. popupAnnotation.Border = new PdfAnnotationBorder(4); //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation") 'Set the annotation border. popupAnnotation.Border = New PdfAnnotationBorder(4) 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("AnnotationBorder.pdf") 'close the document document.Close(True) Class. Class. Initializes a new instance of the class with specified border width, horizontal and vertical radius. A float value specifying the width of the annotation's border. A float value specifying the horizontal corner radius value. A float value specifying the vertical corner radius value. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation"); //Set the annotation border. popupAnnotation.Border = new PdfAnnotationBorder(4, 0, 0); //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation") 'Set the annotation border. popupAnnotation.Border = New PdfAnnotationBorder(4, 0, 0) 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Initializes instance. Width of the border. The horizontal radius. The vertical radius. Sets the number. The index. The value. Gets or sets a horizontal corner radius. The horizontal radius of the annotation. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation"); //Set the horizontal radius to popup annotation border. popupAnnotation.Border.HorizontalRadius = 0; //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation") 'Set the horizontal radius to popup annotation border. popupAnnotation.Border.HorizontalRadius = 0 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Gets or sets a vertical corner radius. The vertical radius of the annotation. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation"); //Set the vertical radius to popup annotation border. popupAnnotation.Border.VerticalRadius = 0; //Add popup annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation") 'Set the vertical radius to popup annotation border. popupAnnotation.Border.VerticalRadius = 0 'Add popup annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Gets or sets the width of annotation's border. A float value specifying the width of the annotation's border. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationBounds = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationBounds, "Test popup annotation"); //Set the width to popup annotation border. popupAnnotation.Border.Width = 4; //Add popup annotation annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationBounds As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationBounds, "Test popup annotation") 'Set the width to popup annotation border. popupAnnotation.Border.Width = 4 'Add popup annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Gets PDF primitive representing this object. Error constant message. Error constant message. Parent page of the collection. Array of the annotations. Dictionary holds popup parent annotations boolean variable indicates whether popup annotation added or not Initializes a new instance of the class. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = new PdfAnnotationCollection(); annotationCollection = page.Annotations; annotationCollection.Add(soundAnnotation); PdfAnnotation annotation = annotationCollection[0] as PdfAnnotation; //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection() annotationCollection = page.Annotations annotationCollection.Add(soundAnnotation) Dim annotation As PdfAnnotation = TryCast(annotationCollection(0), PdfAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. Class. Initializes a new instance of the PdfAnnotationCollection class with the specified page. Page which collection is created for. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = new PdfAnnotationCollection(page); annotationCollection.Add(soundAnnotation); PdfAnnotation annotation = annotationCollection[0] as PdfAnnotation; //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection(page) annotationCollection.Add(soundAnnotation) Dim annotation As PdfAnnotation = TryCast(annotationCollection(0), PdfAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. Class. Adds a new annotation to the collection. The new annotation to be added to the collection. The position of the annotation in the collection. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; annotationCollection.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations annotationCollection.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. To update comment state on PdfArray from annotation To update review state from PdfAnnotaion into PdfArray Removes all the annotations from the collection. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; annotationCollection.Add(soundAnnotation); //Clear the annotation collection. annotationCollection.Clear(); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations annotationCollection.Add(soundAnnotation) 'Clear the annotation collection. annotationCollection.Clear() 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. Determines whether a specified annotation is in the annotation collection. The annotation to search for. True, if annotation is contained in collection. Otherwise - false. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; //Add the sound annotation to annotation collection. annotationCollection.Add(soundAnnotation); bool exist = annotationCollection.Contains(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations 'Add the sound annotation to annotation collection. annotationCollection.Add(soundAnnotation) Dim exist As Boolean = annotationCollection.Contains(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. Searches the index of the specified annotation from the collection. The annotation to be searched. Index of the element in the collection, if exists, or -1 if the element does not exist in the collection. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; annotationCollection.Add(soundAnnotation); //Get the index int index = annotationCollection.IndexOf(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations annotationCollection.Add(soundAnnotation) 'Get the index Dim index As Integer = annotationCollection.IndexOf(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. Inserts an annotation to the collection at the specified index. The index where to insert the element. The annotation to be inserted in the collection. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; annotationCollection.Insert(0, soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations annotationCollection.Insert(0, soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. Removes the annotation at the specified index. The index of the element to be removed. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; annotationCollection.Add(soundAnnotation); //Removes a sound annotation at specified index. annotationCollection.RemoveAt(0); //Save the document to disk. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations annotationCollection.Add(soundAnnotation) 'Removes a sound annotation at specified index. annotationCollection.RemoveAt(0) 'Save the document to disk. document.Save("Output.pdf") 'Close the document. document.Close(True) Class. Class. Removes the specified annotation from the collection. The annotation to be removed. //Create a new PDF Document. PdfDocument document = new PdfDocument(); PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; annotationCollection.Add(soundAnnotation); //Remove a sound annotation. annotationCollection.Remove(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations annotationCollection.Add(soundAnnotation) 'Remove a sound annotation. annotationCollection.Remove(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. prints the specified annotation. The annotation to be printed. Adds annotation to collection. Annotation to be added to collection. Position of the annotation in collection. Inserts annotation to the collection at the specified position. Position. Annotation object. Removes annotation from collection. Annotation to be removed. Removes item from collection at the specified index. Index of element to be removed. Adds a Annotation to collection. The Annotation. To udapte the Annoation review state and comments on PdfArray Inserts a annotation into collection. The index. The annotation. Clears the collection. Removes the annotation at the specified position. The index. Removes the annotation. Parsing Popup annotation Gets the object at the specified index. Read-Only. The specifies the attachment at the specified position. The index value of the annotation in the collection. The annotation object at the specified position. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Add this annotation to a new page. PdfAnnotationCollection annotationCollection = page.Annotations; annotationCollection.Add(soundAnnotation); PdfAnnotation annotation = annotationCollection[0] as PdfAnnotation; //Save the document to disk. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Add this annotation to a new page. Dim annotationCollection As PdfAnnotationCollection = page.Annotations annotationCollection.Add(soundAnnotation) Dim annotation As PdfAnnotation = TryCast(annotationCollection(0), PdfAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'Close the document document.Close(True) Class. Class. Class. Gets the annotations array. The annotations. Gets PDF primitive representing this object. Represents the collection of comments or reviews //Creates a new PDF Document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); //Creates a new rectangle RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30); //Creates a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"logo.png"); //Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin; PdfPopupAnnotation comments1 = new PdfPopupAnnotation(); comments1.Author = "Syncfusion"; comments1.Text = "Hello"; PdfPopupAnnotation comments2 = new PdfPopupAnnotation(); comments2.Author = "Pdf"; comments2.Text = "Welcome"; Set annotation comments to PdfPopupAnnoationCollection PdfPopupAnnotationCollection commentscollection = attachmentAnnotation.Comments; page.Annotations.Add(attachmentAnnotation); commentscollection.Add(comments1); comments1.Comments.Add(comments2); document.Save("Output.pdf"); document.Close(); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim attachmentRectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim attachmentAnnotation As PdfAttachmentAnnotation = New PdfAttachmentAnnotation(attachmentRectangle, "logo.png") 'Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin Dim comments1 As PdfPopupAnnotation = New PdfPopupAnnotation comments1.Author = "Syncfusion" comments1.Text = "Hello" Dim comments2 As PdfPopupAnnotation = New PdfPopupAnnotation comments2.Author = "Pdf" comments2.Text = "Welcome" Dim commentscollection As PdfPopupAnnotationCollection = attachmentAnnotation.Comments page.Annotations.Add(attachmentAnnotation) commentscollection.Add(comments1) comments1.Comments.Add(comments2) document.Save("Output.pdf") document.Close To add comments or reviews on the Annotation. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Rectangle annotation. RectangleF rectannot = new RectangleF(0, 30, 100, 50); PdfRectangleAnnotation rectangleannotation = new PdfRectangleAnnotation(rectannot, "RectangleAnnotation"); rectangleannotation.InnerColor = new PdfColor(Color.Red); rectangleannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Rectangle Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page // Add review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; // Add comments and reviews rectangleannotation.Comments.Add(popupComments); rectangleannotation.ReviewHistory.Add(popup); //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add document.PageSettings.SetMargins(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10!) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim rectannot As RectangleF = New RectangleF(0, 30, 100, 50) Dim rectangleannotation As PdfRectangleAnnotation = New PdfRectangleAnnotation(rectannot, "RectangleAnnotation") rectangleannotation.InnerColor = New PdfColor(Color.Red) rectangleannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Rectangle Annotation", font, brush, New PointF(0, 0)) Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" ' Add comments and reviews rectangleannotation.Comments.Add(popupComments) rectangleannotation.ReviewHistory.Add(popup) 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) To update review state from PdfAnnotaion into PdfArray Removes the reviews or comments //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Rectangle annotation. RectangleF rectannot = new RectangleF(0, 30, 100, 50); PdfRectangleAnnotation rectangleannotation = new PdfRectangleAnnotation(rectannot, "RectangleAnnotation"); rectangleannotation.InnerColor = new PdfColor(Color.Red); rectangleannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Rectangle Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page // Add review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; // remove comments and reviews rectangleannotation.Comments.Remove(popupComments); rectangleannotation.ReviewHistory.Remove(popup); //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add document.PageSettings.SetMargins(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10!) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim rectannot As RectangleF = New RectangleF(0, 30, 100, 50) Dim rectangleannotation As PdfRectangleAnnotation = New PdfRectangleAnnotation(rectannot, "RectangleAnnotation") rectangleannotation.InnerColor = New PdfColor(Color.Red) rectangleannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Rectangle Annotation", font, brush, New PointF(0, 0)) Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" ' remove comments and reviews rectangleannotation.Comments.Remove(popupComments) rectangleannotation.ReviewHistory.Remove(popup) 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Removes the annotation comments or reviews at the specified index. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Rectangle annotation. RectangleF rectannot = new RectangleF(0, 30, 100, 50); PdfRectangleAnnotation rectangleannotation = new PdfRectangleAnnotation(rectannot, "RectangleAnnotation"); rectangleannotation.InnerColor = new PdfColor(Color.Red); rectangleannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Rectangle Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page // Add review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; // remove comments and reviews rectangleannotation.Comments.RemoveAt(0); rectangleannotation.ReviewHistory.RemoveAt(0); //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add document.PageSettings.SetMargins(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10!) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim rectannot As RectangleF = New RectangleF(0, 30, 100, 50) Dim rectangleannotation As PdfRectangleAnnotation = New PdfRectangleAnnotation(rectannot, "RectangleAnnotation") rectangleannotation.InnerColor = New PdfColor(Color.Red) rectangleannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Rectangle Annotation", font, brush, New PointF(0, 0)) Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" ' remove comments and reviews rectangleannotation.Comments.RemoveAt(0) rectangleannotation.ReviewHistory.RemoveAt(0) 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the PdfPopupAnnotation at the specified index. //Creates a new PDF Document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); //Creates a new rectangle RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30); //Creates a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"logo.png"); //Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin; PdfPopupAnnotation comments1 = new PdfPopupAnnotation(); comments1.Author = "Syncfusion"; comments1.Text = "Hello"; PdfPopupAnnotation comments2 = new PdfPopupAnnotation(); comments2.Author = "Pdf"; comments2.Text = "Welcome"; PdfPopupAnnotationCollection commentscollection = attachmentAnnotation.Comments; page.Annotations.Add(attachmentAnnotation); commentscollection.Add(comments1); comments1.Comments.Add(comments2); //Get the index value of PdfPopupAnnotationCollection PdfPopupAnnotation getComments = commentscollection[0]; document.Save("Output.pdf"); document.Close(); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim attachmentRectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim attachmentAnnotation As PdfAttachmentAnnotation = New PdfAttachmentAnnotation(attachmentRectangle, "logo.png") 'Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin Dim comments1 As PdfPopupAnnotation = New PdfPopupAnnotation comments1.Author = "Syncfusion" comments1.Text = "Hello" Dim comments2 As PdfPopupAnnotation = New PdfPopupAnnotation comments2.Author = "Pdf" comments2.Text = "Welcome" Dim commentscollection As PdfPopupAnnotationCollection = attachmentAnnotation.Comments page.Annotations.Add(attachmentAnnotation) commentscollection.Add(comments1) comments1.Comments.Add(comments2) Dim getComments As PdfPopupAnnotation = commentscollection(0) document.Save("Output.pdf") document.Close Represents the states of an annotation's appearance. Internal variable to store template for active (On) state. Internal variable to store template for inactive (Off) state. Internal variable to store dictionary. Internal variable to store dictionary name of checked state. Internal variable to store dictionary name of unchecked state. Initializes a new instance of the class. Handles the BeginSave event of the m_dictionary control. The source of the event. The instance containing the event data. Gets or sets the active state template. The object specifies an active state template. Gets or sets the inactive state. The object specifies an inactive state template. Gets or sets the mapping name of the active state. String specifies the mapping name of the active state. Gets or sets the mapping name of the inactive state. String specifies the mapping name of the inactive state. Gets the element. Represents the appearance of an annotation. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a font PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Create a brush PdfBrush brush = PdfBrushes.Blue; //Create a new pdf3d annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new pdf appearance annotation.Appearance = new PdfAppearance(annotation); annotation.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, new PointF(40, 40)); //Add this annotation to a new page annotation.Appearance.Normal.Draw(page, new PointF(annotation.Location.X, annotation.Location.Y)); //Adds annotation to page page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Create a brush Dim brush As PdfBrush = PdfBrushes.Blue 'Create a new pdf3d annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new pdf appearance annotation.Appearance = New PdfAppearance(annotation) annotation.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, New PointF(40, 40)) 'Add this annotation to a new page annotation.Appearance.Normal.Draw(page, New PointF(annotation.Location.X, annotation.Location.Y)) 'Add annotation to page page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Class. Normal appearance. Mouse hover appearance. Mouse pressed appearance. Internal variable to store annotation. Internal variable to store dictionary. Boolean variable indicates whether validation appearance is completed Initializes a new instance of the class. The object specifies the annotation. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a font PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Create a brush PdfBrush brush = PdfBrushes.Blue; //Create a new pdf3d annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new pdf appearance annotation.Appearance = new PdfAppearance(annotation); annotation.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, new PointF(40, 40)); //Add this annotation to a new page annotation.Appearance.Normal.Draw(page, new PointF(annotation.Location.X, annotation.Location.Y)); //Adds annotation to page page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Create a brush Dim brush As PdfBrush = PdfBrushes.Blue 'Create a new pdf3d annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new pdf appearance annotation.Appearance = New PdfAppearance(annotation) annotation.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, New PointF(40, 40)) 'Add this annotation to a new page annotation.Appearance.Normal.Draw(page, New PointF(annotation.Location.X, annotation.Location.Y)) 'Add annotation to page page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Class. Gets the normal template. Normal appearance template. Gets the pressed template. PDF Template Gets or sets PdfTmplate object which applied to annotation in normal state. The specifies the PDF template object. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a font PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Create a brush PdfBrush brush = PdfBrushes.Blue; //Create a new pdf3d annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new pdf appearance annotation.Appearance = new PdfAppearance(annotation); annotation.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, new PointF(40, 40)); //Add this annotation to a new page annotation.Appearance.Normal.Draw(page, new PointF(annotation.Location.X, annotation.Location.Y)); //Adds annotation to page page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Create a brush Dim brush As PdfBrush = PdfBrushes.Blue 'Create a new pdf3d annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new pdf appearance annotation.Appearance = New PdfAppearance(annotation) annotation.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, New PointF(40, 40)) 'Add this annotation to a new page annotation.Appearance.Normal.Draw(page, New PointF(annotation.Location.X, annotation.Location.Y)) 'Add annotation to page page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Class. Gets or sets object which applied to the annotation on hovering the mouse. The specifies the PDF template object when mouse hover. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a font PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Create a brush PdfBrush brush = PdfBrushes.Blue; //Create a new pdf3d annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new pdf appearance annotation.Appearance = new PdfAppearance(annotation); annotation.Appearance.MouseHover.Graphics.DrawString("Click to activate", font, brush, new PointF(40, 40)); //Add this annotation to a new page annotation.Appearance.MouseHover.Draw(page, new PointF(annotation.Location.X, annotation.Location.Y)); //Adds annotation to page page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Create a brush Dim brush As PdfBrush = PdfBrushes.Blue 'Create a new pdf3d annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new pdf appearance annot.Appearance = New PdfAppearance(annotation) annot.Appearance.MouseHover.Graphics.DrawString("Click to activate", font, brush, New PointF(40, 40)) 'Add this annotation to a new page annot.Appearance.MouseHover.Draw(page, New PointF(annot.Location.X, annot.Location.Y)) 'Add annotation to page page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Class. Gets or sets object which applied to an annotation when mouse button is pressed. The specifies the PDF template object when Pressed. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a font PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Create a brush PdfBrush brush = PdfBrushes.Blue; //Create a new pdf3d annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new pdf appearance annotation.Appearance = new PdfAppearance(annotation); annotation.Appearance.Pressed.Graphics.DrawString("Click to activate", font, brush, new PointF(40, 40)); //Add this annotation to a new page annotation.Appearance.Pressed.Draw(page, new PointF(annotation.Location.X, annotation.Location.Y)); //Adds annotation to page page.Annotations.Add(annotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Create a brush Dim brush As PdfBrush = PdfBrushes.Blue 'Create a new pdf3d annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new pdf appearance annotation.Appearance = New PdfAppearance(annotation) annotation.Appearance.Pressed.Graphics.DrawString("Click to activate", font, brush, New PointF(40, 40)) 'Add this annotation to a new page annotation.Appearance.Pressed.Draw(page, New PointF(annotation.Location.X, annotation.Location.Y)) 'Add annotation to page page.Annotations.Add(annotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. Class. Class. Gets the element. Represents extended appearance of the annotation. It has two states such as On state and Off state. Internal variable to store normal appearance. Internal variable to store appearance for pressed state. Internal variable to store appearance for state when mouse is hovered. Internal variable to store dictionary. Initializes a new instance of the class. Gets the normal appearance of the annotation. The object specifies the normal appearance of the annotation. Gets the appearance when mouse is hovered. The object specifies the annotation appearance when the mouse is hovered on it. Gets the pressed state annotation. The appearance in pressed state. Gets the element. Represents an attachment annotation of the PDF document. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30); //Create a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"Input.png"); //Set the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin; //Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim attachmentRectangle As New RectangleF(10, 40, 30, 30) 'Create a new attachment annotation. Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentRectangle, "Input.png") 'Set the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin 'Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class. Represents a base class for file attachment annotation. Class Class Class Annotation's appearance. Initializes a new instance of the class. Initializes a new instance of the class with specified bounds. Bounds of the annotation. Saves an annotation. Gets or sets file name of the annotation. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a font PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Create a brush PdfBrush brush = PdfBrushes.Blue; //Create a new pdf3d annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Get file name of the annotation. string fileName = annotation.FileName; //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Create a brush Dim brush As PdfBrush = PdfBrushes.Blue 'Create a new pdf3d annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Get file name of the annotation. Dim fileName As String = annotation.FileName 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the appearance of the annotation. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a font PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Create a brush PdfBrush brush = PdfBrushes.Blue; //Create a new pdf3d annotation. Pdf3DAnnotation annotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create a new pdf appearance annot.Appearance = new PdfAppearance(annotation); annot.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, new PointF(40, 40)); //Add this annotation to a new page annot.Appearance.Normal.Draw(page, new PointF(annot.Location.X, annot.Location.Y)); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Create a brush Dim brush As PdfBrush = PdfBrushes.Blue 'Create a new pdf3d annotation. Dim annotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create a new PDF appearance. annot.Appearance = New PdfAppearance(annotation) annot.Appearance.Normal.Graphics.DrawString("Click to activate", font, brush, New PointF(40, 40)) 'Add this annotation to a new page annot.Appearance.Normal.Draw(page, New PointF(annot.Location.X, annot.Location.Y)) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Icon of the annotation. File specification of the annotation. The bounds of the annotation. A string value specifying the full path to the file to be embedded in the PDF file. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF attachmentBounds = new RectangleF(10, 40, 30, 30); //Create a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentBounds, @"Input.jpg"); //Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim attachmentBounds As New RectangleF(10, 40, 30, 30) 'Create a new attachment annotation. Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentBounds, "Input.jpg") 'Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class. The bounds of the annotation. A string value specifying the full path to the file to be embedded in the PDF file. A byte array specifying the content of the annotation's embedded file. If both FileName and FileContent are specified, the FileContent takes precedence. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF attachmentBounds = new RectangleF(10, 40, 30, 30); //Load the image as bytes byte[] imageBytes = File.ReadAllBytes("Input.jpg"); //Create a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentBounds, @"Input.jpg", imageBytes); //Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim attachmentBounds As New RectangleF(10, 40, 30, 30) 'Load the image as bytes Dim imageBytes() As Byte = File.ReadAllBytes("Input.jpg") 'Create a new attachment annotation. Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentBounds, "Input.jpg", imageBytes) 'Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class. The bounds of the annotation. A string value specifying the full path to the file to be embedded in the PDF file. The stream specifying the content of the annotation's embedded file. If both FileName and FileContent are specified, the FileContent takes precedence. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF attachmentBounds = new RectangleF(10, 40, 30, 30); //Load the image as stream. FileStream stream = new FileStream(@"Input.jpg", FileMode.Open); //Create a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentBounds, "Input.jpg", stream); //Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim attachmentBounds As New RectangleF(10, 40, 30, 30) 'Load the image as stream. Dim stream As New FileStream("Input.jpg", FileMode.Open) 'Create a new attachment annotation. Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentBounds, "Input.jpg", stream) 'Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class. Initializes object. Saves annotation object. Gets or Sets the attachment's icon. A enumeration member specifying the icon for the annotation when it is displayed in closed state. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30); //Create a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"Input.png"); //Set the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin; //Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim attachmentRectangle As New RectangleF(10, 40, 30, 30) 'Create a new attachment annotation. Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentRectangle, "Input.png") 'Set the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin 'Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class. A string value specifying the full path to the file to be embedded in the PDF file. //Create a new PDF Document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle. RectangleF attachmentBounds = new RectangleF(10, 40, 30, 30); //Create a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentBounds, @"Input.wav"); //Set the file name. attachmentAnnotation.FileName = "input.wav"; //Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF Document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle. Dim attachmentRectangle As New RectangleF(10, 40, 30, 30) 'Create a new attachment annotation. Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentRectangle, "Input.png") 'Set the file name. attachmentAnnotation.FileName = "input.wav" 'Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class. Gets the annotation reviews //Creates a new PDF Document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); //Creates a new rectangle RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30); //Creates a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"logo.png"); //Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin; //set Review history PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; attachmentAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = attachmentAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim attachmentRectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim attachmentAnnotation As PdfAttachmentAnnotation = New PdfAttachmentAnnotation(attachmentRectangle, "logo.png") 'Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" attachmentAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = attachmentAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Creates a new PDF Document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); //Creates a new rectangle RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30); //Creates a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"logo.png"); //Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin; //set comments PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; attachmentAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = attachmentAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim attachmentRectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim attachmentAnnotation As PdfAttachmentAnnotation = New PdfAttachmentAnnotation(attachmentRectangle, "logo.png") 'Sets the attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" attachmentAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = attachmentAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Represents an annotation object with holds link on another location within a document. This class is used to navigate the specific destination within the document. Please refer the UG docuemntation link for more details. //Create the PDF Document PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF docLinkAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new document link annotation. PdfDocumentLinkAnnotation documentAnnotation = new PdfDocumentLinkAnnotation(docLinkAnnotationRectangle); //Create a new page . PdfPage page2 = document.Pages.Add(); //Set the pdf destination. documentAnnotation.Destination = new PdfDestination(page2); //Set the pdf destination location. documentAnnotation.Destination.Location = new Point(10, 0); //Add this annotation to a new page. page.Annotations.Add(documentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF Document Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim docLinkAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new document link annotation. Dim documentAnnotation As New PdfDocumentLinkAnnotation(docLinkAnnotationRectangle) 'Create a new page . Dim page2 As PdfPage = document.Pages.Add() 'Set the pdf destination. documentAnnotation.Destination = New PdfDestination(page2) 'Set the pdf destination location. documentAnnotation.Destination.Location = New Point(10, 0) 'Add this annotation to a new page. page.Annotations.Add(documentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Destination of the annotation. Initializes new instance with specified bounds. The bounds of the annotation. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF docLinkAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new document link annotation. PdfDocumentLinkAnnotation documentAnnotation = new PdfDocumentLinkAnnotation(docLinkAnnotationRectangle); //Create a new page . PdfPage page2 = document.Pages.Add(); //Set the pdf destination. documentAnnotation.Destination = new PdfDestination(page2); //Set the pdf destination location. documentAnnotation.Destination.Location = new Point(10, 0); //Add this annotation to a new page. page.Annotations.Add(documentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim docLinkAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new document link annotation. Dim documentAnnotation As New PdfDocumentLinkAnnotation(docLinkAnnotationRectangle) 'Create a new page . Dim page2 As PdfPage = document.Pages.Add() 'Set the pdf destination. documentAnnotation.Destination = New PdfDestination(page2) 'Set the pdf destination location. documentAnnotation.Destination.Location = New Point(10, 0) 'Add this annotation to a new page. page.Annotations.Add(documentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Initializes new instance with specified bounds and destination. The bounds of the annotation. The destination of the annotation. //Create the PDF document PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF docLinkAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new page . PdfPage page2 = document.Pages.Add(); //Create a new pdf destination. PdfDestination destination = new PdfDestination(page2); //Create a new document link annotation. PdfDocumentLinkAnnotation documentAnnotation = new PdfDocumentLinkAnnotation(docLinkAnnotationRectangle, destination); //Set the annotation text. documentAnnotation.Text = "Document link annotation"; //Add this annotation to a new page. page.Annotations.Add(documentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create the PDF document Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim docLinkAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new page . Dim page2 As PdfPage = document.Pages.Add() 'Create a new pdf destination. Dim destination As New PdfDestination(page2) 'Create a new document link annotation. Dim documentAnnotation As New PdfDocumentLinkAnnotation(docLinkAnnotationRectangle, destination) 'Set the annotation text. documentAnnotation.Text = "Document link annotation" 'Add this annotation to a new page. page.Annotations.Add(documentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Saves annotation object. Represents the annotation link to an external file. This class is used to link the external file to PDF document. Please refer the UG docuemntation link for more details. //Create a PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new PDF file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(rectangle, @"Input.png"); //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new PDF file link annotation. Dim fileLinkAnnotation As New PdfFileLinkAnnotation(rectangle, "Input.png") 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Internal variable to store file launch action. The bounds of the annotation. A string value specifying the full path to the file to be embedded. //Create a PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new pdf file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(rectangle, @"Input.png"); //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new pdf file link annotation. Dim fileLinkAnnotation As New PdfFileLinkAnnotation(rectangle, "Input.png") 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Saves annotation object. A string value specifying the full path to the file to be embedded. //Create a PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new PDF file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(rectangle, @"Input.png"); //Get the file name. string fileName = fileLinkAnnotation.FileName; //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new PDF file link annotation. Dim fileLinkAnnotation As PdfFileLinkAnnotation = New PdfFileLinkAnnotation(rectangle, "Input.png") 'Gets the file name. Dim fileName As String=fileLinkAnnotation.FileName 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(true); Class Gets or sets the action. The action to be executed when the annotation is activated. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new file link annotation. PdfFileLinkAnnotation fileLinkAnnotation = new PdfFileLinkAnnotation(rectangle, "input.png"); //Set an action to file link annotation. PdfJavaScriptAction javaAction = new PdfJavaScriptAction("app.alert(\"You are looking at Java script action of PDF \")"); fileLinkAnnotation.Action = javaAction; //Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new file link annotation. Dim fileLinkAnnotation As New PdfFileLinkAnnotation(rectangle, "input.png") 'Set an action to file link annotation. Dim javaAction As New PdfJavaScriptAction("app.alert(""You are looking at Java script action of PDF "")") fileLinkAnnotation.Action = javaAction 'Add this annotation to a new page. page.Annotations.Add(fileLinkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Represents the ink annotation class. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //set the points List(float) linePoints = new List(float) { 40, 300, 60, 100, 40, 50, 40, 300 }; //Create a new ink annotation RectangleF rectangle = new RectangleF(0, 0, 300, 400); //Create a inkAnnotation and set the properties PdfInkAnnotation inkAnnotation = new PdfInkAnnotation(rectangle, linePoints); inkAnnotation.Color = new PdfColor(Color.Red); inkAnnotation.BorderWidth = 4; inkAnnotation.BorderStyle = PdfLineBorderStyle.Beveled; //Add annotation to the page page.Annotations.Add(inkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'set the points Dim linePoints As New List(Of Single) (New Single() {40, 300, 60, 100, 40, 50, 40, 300}) 'Create a new ink annotation Dim rectangle As New RectangleF(0, 0, 300, 400) 'Create a inkAnnotation and set the properties Dim inkAnnotation As New PdfInkAnnotation(rectangle, linePoints) inkAnnotation.Color = New PdfColor(Color.Red) inkAnnotation.BorderWidth = 4 inkAnnotation.BorderStyle = PdfLineBorderStyle.Beveled 'Add annotation to the page page.Annotations.Add(inkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Indicate the path of the ink annotation Indicates m_inkList is added into m_inkPointsCollection or not Indicate path collection of the ink annotation Internal variable to store Border Dash. border width Border line width Indicate the border Dictionary Indicat the border style Initializes a new instance of the class. Initializes annotation object. Calculates control points for all the path points input given by Beizer spline curve control points calculation. Calculates single control point for the vector input given. Saves an annotation. Flatten annotation Create appearance for annotation Add Ink points in dictionary Save Ink Dictionary Gets or sets the border line width of an ink annotation. Represents a line annotation. This class is used to represents line annotation in PDF document. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annotation"); //Create PDF line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt; lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond; lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default; //Assign the line color lineAnnotation.InnerLineColor = new PdfColor(Color.Green); lineAnnotation.BackColor = new PdfColor(Color.Green); //Assign the leader line lineAnnotation.LeaderLineExt = 0; lineAnnotation.LeaderLine = 0; //Assign the Line caption type lineAnnotation.LineCaption = true; lineAnnotation.CaptionType = PdfLineCaptionType.Inline; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Create PDF line border Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension 'Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default 'Assign the line color lineAnnotation.InnerLineColor = New PdfColor(Color.Green) lineAnnotation.BackColor = New PdfColor(Color.Green) 'Assign the leader line lineAnnotation.LeaderLineExt = 0 lineAnnotation.LeaderLine = 0 'Assign the Line caption type lineAnnotation.LineCaption = True lineAnnotation.CaptionType = PdfLineCaptionType.Inline 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Indicates PdfLine Begin style Indicates PdfLine End style To Specify the Line Border An array of four numbers specifying the starting and ending coordinates An array of two names specifying the line ending styles To specifying the Leader Line Extension size To specifying the Leader Line size To specifying the caption in the appearance of the line, To specifying the intent of the line annotation To specifying Caption Type To Specifying the LinePoints of the line annotation To Specifying the LinePoints of the line annotation Initializes new instance of class with specified points. The line points is to be drawn. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation and set properties. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points); lineAnnotation.Text = "Line Annotation"; //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt; lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond; lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default; //Assign the line color lineAnnotation.InnerLineColor = new PdfColor(Color.Green); lineAnnotation.BackColor = new PdfColor(Color.Green); //Assign the leader line lineAnnotation.LeaderLineExt = 0; lineAnnotation.LeaderLine = 0; //Assign the Line caption type lineAnnotation.LineCaption = true; lineAnnotation.CaptionType = PdfLineCaptionType.Inline; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation and set properties. Dim lineAnnotation As New PdfLineAnnotation(points) lineAnnotation.Text = "Line Annotation" 'Create pdf line border Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension 'Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default 'Assign the line color lineAnnotation.InnerLineColor = New PdfColor(Color.Green) lineAnnotation.BackColor = New PdfColor(Color.Green) 'Assign the leader line lineAnnotation.LeaderLineExt = 0 lineAnnotation.LeaderLine = 0 'Assign the Line caption type lineAnnotation.LineCaption = True lineAnnotation.CaptionType = PdfLineCaptionType.Inline 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Initializes new instance of class with set of points and annotation text. The line points to be drawn. The line caption text of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new pag . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.DashArray = 1; lineAnnotation.lineBorder = lineBorder; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new pag . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Create pdf line border Dim lineBorder As New LineBorder() lineBorder.DashArray = 1 lineAnnotation.lineBorder = lineBorder 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Initializes new instance of class with specified bounds. The bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation and set properties. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(new RectangleF(80, 420, 150, 420)); lineAnnotation.Text = "Line Annotation"; lineAnnotation.LinePoints = points; //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt; lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond; lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default; //Assign the line color lineAnnotation.InnerLineColor = new PdfColor(Color.Green); lineAnnotation.BackColor = new PdfColor(Color.Green); //Assign the leader line lineAnnotation.LeaderLineExt = 0; lineAnnotation.LeaderLine = 0; //Assign the Line caption type lineAnnotation.LineCaption = true; lineAnnotation.CaptionType = PdfLineCaptionType.Inline; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation and set properties. Dim lineAnnotation As New PdfLineAnnotation(New RectangleF(80, 420, 150, 420)) lineAnnotation.Text = "Line Annotation" lineAnnotation.LinePoints = points 'Create pdf line border Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension 'Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default 'Assign the line color lineAnnotation.InnerLineColor = New PdfColor(Color.Green) lineAnnotation.BackColor = New PdfColor(Color.Green) 'Assign the leader line lineAnnotation.LeaderLineExt = 0 lineAnnotation.LeaderLine = 0 'Assign the Line caption type lineAnnotation.LineCaption = True lineAnnotation.CaptionType = PdfLineCaptionType.Inline 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Initializes annotation object. Gets line points of the annotation. line points. Saves an annotation. Obtain Line bounds from line points Save line annotation required dictionary Create appearance for annotation Flatten annotation Gets or sets whether the line annotation caption should be displayed. true if the line caption should be displayed, otherwise false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the line caption. lineAnnotation.LineCaption = true; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the line caption. lineAnnotation.LineCaption = True 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the leader line The value specifies the leader line of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the leader line. lineAnnotation.LeaderLine = 10; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the leader line. lineAnnotation.LeaderLine = 10 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the LeaderLineExtension. The value specifies the leader line extension of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the leader line extension. lineAnnotation.LeaderLineExt = 10; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the leader line extension. lineAnnotation.LeaderLineExt = 10 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the border style of the LineAnnotation. A enumeration member specifying the border style for the line. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the line border. LineBorder lineBorder = new LineBorder(); lineBorder.DashArray = 1; lineAnnotation.lineBorder = lineBorder; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the line border. Dim lineBorder As LineBorder = New LineBorder() lineBorder.DashArray = 1 lineAnnotation.lineBorder = lineBorder 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the style used for the beginning of the line. A enumeration member specifying the begin style for the line. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the begin line style. lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the begin line style. lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the style used for the end of the line. A enumeration member specifying the end style for the line. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the line ending style. lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the line ending style. lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the line caption text type of annotation. A enumeration specifying the line caption type. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Inline; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Inline 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the LineIntent of the annotation. A specifies the Line Intent Style is to be used in the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the line intent. lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the line intent. lineAnnotation.LineIntent = PdfLineIntent.LineDimension 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets an InnerColor of the PdfLineAnnotation. The which draws the outline of the inner color of the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the inner line color. lineAnnotation.InnerLineColor = new PdfColor(Color.Green); //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the inner line color. lineAnnotation.InnerLineColor = New PdfColor(Color.Green) 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the BackgroundColor of the PdfLineAnnotation. The which draws the border of the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the line back color. lineAnnotation.BackColor = new PdfColor(Color.Green); //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the line back color. lineAnnotation.BackColor = New PdfColor(Color.Green) 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the LinePoints of the PdfLineAnnotation. The value specifies array of the line points to be drawn. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(new RectangleF(100, 100, 100, 20)); //Sets the LinePoints. lineAnnotation.LinePoints = points; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(New RectangleF(100, 100, 100, 20)) 'Sets the LinePoints. lineAnnotation.LinePoints = points 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation and set properties. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points); lineAnnotation.Text = "Line Annotation"; //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //set comments PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; lineAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = lineAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim lineAnnotation As PdfLineAnnotation = New PdfLineAnnotation(points) lineAnnotation.Text = "Line Annotation" Dim lineBorder As LineBorder = New LineBorder lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" lineAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = lineAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Represents the border style of the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annotation"); //Create pdf line border. LineBorder lineBorder = new LineBorder(); lineBorder.DashArray = 1; lineAnnotation.lineBorder = lineBorder; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = {80, 420, 150, 420} 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annotation") 'Create pdf line border. Dim lineBorder As New LineBorder() lineBorder.DashArray = 1 lineAnnotation.lineBorder = lineBorder 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Internal variable to store border width in float. Internal variable to store border width. Internal variable to store Border Dash. Internal variable to store border style; Internal variable to store dictionary. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annotation"); //Create pdf line border. LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annotation") 'Create pdf line border. Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Converts border style to string. The style. Gets or sets the width of the line border. The width of the line border. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annotation"); //Create pdf line border. LineBorder lineBorder = new LineBorder(); lineBorder.DashArray = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.lineBorder.BorderWidth = 4; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = {80, 420, 150, 420} 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annotation") 'Create pdf line border. Dim lineBorder As New LineBorder() lineBorder.DashArray = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.lineBorder.BorderWidth = 4 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets or sets the border style. The Specifies the available styles for a field border //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annotation"); //Create pdf line border. LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annotation") 'Create pdf line border. Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets or sets the line dash of the annotation The dash array of the line border. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annotation"); //Create pdf line border. LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineBorder.DashArray = 1; lineAnnotation.lineBorder = lineBorder; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annotation") 'Create pdf line border. Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineBorder.DashArray = 1 lineAnnotation.lineBorder = lineBorder 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Gets the element. Represents the 3D annotation for a PDF document. This class is used to represents the 3D annotation for a PDF document. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Create pdfFont, pdfFont style and brush. Font font = new Font("Calibri", 11, FontStyle.Regular); PdfFont pdfFont = new PdfTrueTypeFont(font, false); PdfBrush brush = new PdfSolidBrush(Color.DarkBlue); //Create 3D activation. Pdf3DActivation activation = new Pdf3DActivation(); activation.ActivationMode = Pdf3DActivationMode.PageVisible; activation.ShowToolbar = true; pdf3dAnnotation.Activation = activation; Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName = "Near View"; defaultView.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; //Set the 3D background. Pdf3DBackground background=new Pdf3DBackground(); background.Color=new PdfColor(Color.Blue); defaultView.Background = background; //Set the projection. Pdf3DProjection projection = new Pdf3DProjection(Pdf3DProjectionType.Orthographic); defaultView.Projection = projection; //Set the render mode. Pdf3DRendermode renderMode = new Pdf3DRendermode(Pdf3DRenderStyle.Solid); defaultView.RenderMode = renderMode; //Set the lighting scheme. Pdf3DLighting lighting = new Pdf3DLighting(Pdf3DLightingStyle.Night); defaultView.LightingScheme = lighting; //Add the view. pdf3dAnnotation.Views.Add(defaultView); pdf3dAnnotation.Appearance.Normal.Graphics.DrawString("Click to activate", pdfFont, brush, new PointF(40, 40)); //Add this annotation to a new page. pdf3dAnnotation.Appearance.Normal.Draw(page, new PointF(pdf3dAnnotation.Location.X, pdf3dAnnotation.Location.Y)); //Adds annotation to page. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Create pdfFont, pdfFont style and brush. Dim font As New Font("Calibri", 11, FontStyle.Regular) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) Dim brush As PdfBrush = New PdfSolidBrush(Color.DarkBlue) Dim activation As New Pdf3DActivation() activation.ActivationMode = Pdf3DActivationMode.PageVisible activation.ShowToolbar = True pdf3dAnnotation.Activation = activation Dim defaultView As New Pdf3DView() defaultView.ExternalName = "Near View" defaultView.CameraToWorldMatrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f 'Set the 3D background. Dim background As New Pdf3DBackground() background.Color = New PdfColor(Color.Blue) defaultView.Background = background 'Set the projection. Dim projection As New Pdf3DProjection(Pdf3DProjectionType.Orthographic) defaultView.Projection = projection 'Set the render mode. Dim renderMode As New Pdf3DRendermode(Pdf3DRenderStyle.Solid) defaultView.RenderMode = renderMode 'Set the lighting scheme. Dim lighting As New Pdf3DLighting(Pdf3DLightingStyle.Night) defaultView.LightingScheme = lighting 'Add the view. pdf3dAnnotation.Views.Add(defaultView) pdf3dAnnotation.Appearance.Normal.Graphics.DrawString("Click to activate", pdfFont, brush, New PointF(40, 40)) 'Add this annotation to a new page. pdf3dAnnotation.Appearance.Normal.Draw(page, New PointF(pdf3dAnnotation.Location.X, pdf3dAnnotation.Location.Y)) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Class Class Class Class Class Internal variable to store U3D. Internal variable to store apperance. Initializes a new instance of the class with specified bounds. The bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150)); //Adds the annotation. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150)) 'Adds the annotation. page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True). Class The bounds of the annotation. The name of the sound file. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150),"Input.u3d"); //Adds the annotation. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Adds the annotation on a page. page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True). Class Initializes instance. Saves instance. Gets the list of available views for the current 3D artwork. Read-Only. The specifies the collection of PDF 3D views. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); Pdf3DView defaultView = new Pdf3DView(); defaultView.ExternalName = "Near View"; defaultView.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; //Add views. pdf3dAnnotation.Views.Add(defaultView); //Get the views. Pdf3DViewCollection viewCollection = pdf3dAnnotation.Views; //Add the annotation. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") Dim defaultView As New Pdf3DView() defaultView.ExternalName = "Near View" defaultView.CameraToWorldMatrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f 'Add views. pdf3dAnnotation.Views.Add(defaultView) 'Get the views. Dim viewCollection As Pdf3DViewCollection = pdf3dAnnotation.Views 'Add the annotation. page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Class Gets or sets the default view. The default view of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); pdf3dAnnotation.DefaultView = 0; page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") pdf3dAnnotation.DefaultView = 0 page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Gets or sets the type of 3DAnnoation. The type of the 3DAnnotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); pdf3dAnnotation.Type = Pdf3DAnnotationType.PRC; page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") pdf3dAnnotation.Type = Pdf3DAnnotationType.PRC page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Enum Gets or sets the code to execute when the 3D artwork is instantiated. JavaScript code to be executed when the 3D artwork is instantiated. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); pdf3dAnnotation.OnInstantiate = "host.getURL(\"http://www.syncfusion.com\")"; //Create a pdf 3d view. Pdf3DView defaultView = new Pdf3DView(); defaultView.CameraToWorldMatrix = new float[] { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f }; defaultView.CenterOfOrbit = 131.695f; pdf3dAnnotation.Views.Add(defaultView); //Adds the annotation. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") pdf3dAnnotation.OnInstantiate = "host.getURL(\"http://www.syncfusion.com\")" 'Create a pdf 3d view. Dim defaultView As New Pdf3DView() defaultView.CameraToWorldMatrix = New Single() { -0.382684f, 0.92388f, -0.0000000766026f, 0.18024f, 0.0746579f, 0.980785f, 0.906127f, 0.37533f, -0.19509f, -100, -112.432f, 45.6829f } defaultView.CenterOfOrbit = 131.695f pdf3dAnnotation.Views.Add(defaultView) 'Adds the annotation. page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True). Class Class Gets or sets the activation options for the annotation. specifies activation states for the annotation. Defines the times at which the annotation should be activated and deactivated and the state of the 3D artwork instance at those times. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Creates a new pdf3d activation. Pdf3DActivation activation = new Pdf3DActivation(); activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation; activation.ShowToolbar = false; pdf3dAnnotation.Activation = activation; //Adds the annotation. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Creatas a new pdf3d actviation. Dim activation As New Pdf3DActivation() activation.ActivationMode = Pdf3DActivationMode.ExplicitActivation activation.ShowToolbar = False pdf3dAnnotation.Activation = activation 'Adds the annotation. page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Class Class Filename with Full path //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf3d annotation. Pdf3DAnnotation pdf3dAnnotation = new Pdf3DAnnotation(new RectangleF(10, 50, 300, 150), @"Input.u3d"); //Gets the filename. string fileName = pdf3dAnnotation.FileName; //Adds the annotation. page.Annotations.Add(pdf3dAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf3d annotation. Dim pdf3dAnnotation As New Pdf3DAnnotation(New RectangleF(10, 50, 300, 150), "Input.u3d") 'Gets the filename. Dim fileName As String = pdf3dAnnotation.FileName 'Adds the annotation. page.Annotations.Add(pdf3dAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True). Class Base class for annotation objects. Color of the annotation. Border of the annotation. Bounds of the annotation. Parent page of the annotation. Text of the annotation. NAnootation's style flags. Internal variable to store dictionary. Creates new annotation object. Creates new annotation object with the specified bounds. Bounds of the annotation. Sets related page of the annotation. Sets the location. The location. Sets the size. The size. Initializes annotation object. Handles the BeginSave event of the Dictionary. The source of the event. The instance containing the event data. Saves an annotation. Gets or sets the background of the annotation�s icon when closed. The title bar of the annotation�s pop-up window. The border of a link annotation. The color. Gets or sets annotation's border. Gets or sets annotation's bounds. If this property is not set bounds are calculated automatically based on Location property and content of annotation. Gets or sets location of the annotation. Gets or sets size of the annotation. Gets a page which this annotation is connected to. Gets or sets content of the annotation. Gets or sets annotation flags. Gets the dictionary. The dictionary. Gets the element. It's a base class for all annotations Internal variable to store dictinary. Cross table of the document; Collection of the descend annotation. Initializes a new instance of the class. Note that the Type field shouldn't be generated. Initializes a new instance of the class. The dictionary. The cross table. Creates and adds an annotation. The title of the new annotation. The annotation created. Updates all outline dictionary fields. Gets an instance at the specified index. Read-Only. The object at the specified index. Gets the sub items. Gets the dictionary. The dictionary. Gets the cross table. Represents the border effect style of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 ,40 ,800 }; //Create a polygon annotation. PdfPolygonAnnotation polygonannotation = new PdfPolygonAnnotation(points, "Polygon Annotation"); //Create pdf border Effect. PdfBorderEffect borderEffect = new PdfBorderEffect(); borderEffect.Style = PdfBorderEffectStyle.Cloudy; borderEffect.Intensity = 1; polygonannotation.BorderEffect = borderEffect; //Add this annotation to a new page. page.Annotations.Add(polygonannotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420, 40, 800 } 'Create a new Polygon annotation. Dim polygonannotation As New PdfPolygonAnnotation(points, "Polygon Annotation") 'Create pdf border Effect. Dim borderEffect As New PdfBorderEffect() borderEffect.Style = PdfBorderEffectStyle.Cloudy borderEffect.Intensity=1; polygonannotation.BorderEffect = borderEffect 'Add this annotation to a new page. page.Annotations.Add(polygonannotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Internal variable to store dictionary. Used to represent the border effect of the annotation. To specifying the Intensity of the cloud Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 ,40 ,800 }; //Create a polygon annotation. PdfPolygonAnnotation polygonannotation = new PdfPolygonAnnotation(points, "Polygon Annotation"); //Create pdf border effect. PdfBorderEffect borderEffect = new PdfBorderEffect(); polygonannotation.BorderEffect = borderEffect; //Add this annotation to a new page. page.Annotations.Add(polygonannotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420, 40, 800 } 'Create a new polygon annotation. Dim polygonannotation As New PdfPolygonAnnotation(points, "Polygon Annotation") 'Create pdf border Effect. Dim borderEffect As New PdfBorderEffect() polygonannotation.BorderEffect = borderEffect 'Add this annotation to a new page. page.Annotations.Add(polygonannotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Initializes instance. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Converts border effect to string. The effect. Converts string to border effect. The beffect. Gets or sets the border effect style. The Specifies the available styles for a field border //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 ,40 ,800 }; //Create a polygon annotation. PdfPolygonAnnotation polygonannotation = new PdfPolygonAnnotation(points, "Polygon Annotation"); //Create pdf border Effect. PdfBorderEffect borderEffect = new PdfBorderEffect(); PdfBorderEffectStyle effect = PdfBorderEffectStyle.Cloudy; borderEffect.Style = effect; borderEffect.Intensity = 1; polygonannotation.BorderEffect = borderEffect; //Add this annotation to a new page. page.Annotations.Add(polygonannotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420, 40, 800 } 'Create a new Polygon annotation. Dim polygonannotation As New PdfPolygonAnnotation(points, "Polygon Annotation") 'Create pdf border Effect. Dim borderEffect As New PdfBorderEffect() PdfBorderEffectStyle effect = PdfBrderEffectStle.Cloudy; borderEffect.Style = effect; borderEffect.Intensity=1; polygonannotation.BorderEffect = borderEffect 'Add this annotation to a new page. page.Annotations.Add(polygonannotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Gets or sets the Intensity of border effect. This property has store the range of value 0 to 2. The Specifies the available Intensity for a field border //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 ,40 ,800 }; //Create a polygon annotation. //PdfPolygonAnnotation polygonannotation = new PdfPolygonAnnotation(points, "Polygon Annotation"); //Create pdf border effect. PdfBorderEffect borderEffect = new PdfBorderEffect(); borderEffect.Style = PdfBorderEffectStyle.Cloudy; borderEffect.Intensity = 1; polygonannotation.BorderEffect = borderEffect; //Add this annotation to a new page. page.Annotations.Add(polygonannotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420, 40, 800 } 'Create a new polygon annotation. Dim polygonannotation As New PdfPolygonAnnotation(points, "Polygon Annotation") 'Create pdf border Effect. Dim borderEffect As New PdfBorderEffect() borderEffect.Style = PdfBorderEffectStyle.Cloudy borderEffect.Intensity=1; polygonannotation.BorderEffect = borderEffect 'Add this annotation to a new page. page.Annotations.Add(polygonannotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Gets the dictionary. The dictionary. Gets the element. Represents the PDF text annotation. This class is used to add the text directly on the page. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Initializes a new instance of the PdfFreeTextAnnotation class. Initializes a new instance of the PdfFreeTextAnnotation class with specified bounds. The bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Initializes Annotation object. Saves an Text Markup Annotation . Flatten annotation Save free text required dictionary Obtain bounds for create appearance Create appearance for annotation Draw arrow for callout line Draw callout line in appearance Calculate arrow points Draw Free text rectangle Draw free markup text in appearance Set rectangle differance for free text annotation Gets or sets value that indicates the vertical distance between the baselines of adjacent lines of text. Default value is 0. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond; //Set the line spacing textAnnotation.LineSpacing = 5.5f; textAnnotation.SetAppearance(true); //Sets the points array to be called out the lines textAnnotation.CalloutLines = new PointF[] { new PointF(0, 0), new PointF(1, 1) }; //Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red; //Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond 'Set the Line spacing. textAnnotation.LineSpacing=5.5f textAnnotation.SetAppearance(True) 'Sets the points array to be called out the lines textAnnotation.CalloutLines = New PointF() {New PointF(0, 0), New PointF(1, 1)} 'Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red 'Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Gets or sets the line ending style of the text annotation. The object selects the different line ending styles of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond; //Sets the points array to be called out the lines textAnnotation.CalloutLines = new PointF[] { new PointF(0, 0), new PointF(1, 1) }; //Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red; //Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond 'Sets the points array to be called out the lines textAnnotation.CalloutLines = New PointF() {New PointF(0, 0), New PointF(1, 1)} 'Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red 'Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Gets or sets the intent of the text annotation The object sets the annotation intent. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond; //Sets the points array to be called out the lines textAnnotation.CalloutLines = new PointF[] { new PointF(0, 0), new PointF(1, 1) }; //Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red; //Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond 'Sets the points array to be called out the lines textAnnotation.CalloutLines = New PointF() {New PointF(0, 0), New PointF(1, 1)} 'Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red 'Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Gets or sets the markup text of the text annotation The string value which contains the markup text of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond; //Sets the points array to be called out the lines textAnnotation.CalloutLines = new PointF[] { new PointF(0, 0), new PointF(1, 1) }; //Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red; //Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond 'Sets the points array to be called out the lines textAnnotation.CalloutLines = New PointF() {New PointF(0, 0), New PointF(1, 1)} 'Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red 'Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Gets or sets the font of the text annotation ` The object which defines the annotation text font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond; //Sets the points array to be called out the lines textAnnotation.CalloutLines = new PointF[] { new PointF(0, 0), new PointF(1, 1) }; //Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red; //Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond 'Sets the points array to be called out the lines textAnnotation.CalloutLines = New PointF() {New PointF(0, 0), New PointF(1, 1)} 'Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red 'Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Gets or sets the points array to be called out the lines. The array of points to call out lines. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond; //Sets the points array to be called out the lines textAnnotation.CalloutLines = new PointF[] { new PointF(0, 0), new PointF(1, 1) }; //Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red; //Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple; //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond 'Sets the points array to be called out the lines textAnnotation.CalloutLines = New PointF() {New PointF(0, 0), New PointF(1, 1)} 'Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red 'Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple 'Add this annotation to a new page. page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Gets the annotation reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation freeTextAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font freeTextAnnotation.MarkupText = "Text Annotation"; freeTextAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //set review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; freeTextAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = freeTextAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim textAnnotationBounds As RectangleF = New RectangleF(10, 40, 100, 30) Dim freeTextAnnotation As PdfFreeTextAnnotation = New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font freeTextAnnotation.MarkupText = "Text Annotation" freeTextAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" freeTextAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = freeTextAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation freeTextAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font freeTextAnnotation.MarkupText = "Text Annotation"; freeTextAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //set Comments state PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; freeTextAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = freeTextAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim textAnnotationBounds As RectangleF = New RectangleF(10, 40, 100, 30) Dim freeTextAnnotation As PdfFreeTextAnnotation = New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font freeTextAnnotation.MarkupText = "Text Annotation" freeTextAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" freeTextAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = freeTextAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets or sets the complex script to add different languages texts in free text annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation freeTextAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font freeTextAnnotation.MarkupText = "Text Annotation"; freeTextAnnotation.ComplexScript = true; freeTextAnnotation.Font = new PdfTrueTypeFont(new Font("Nirmala UI", 14), true); //Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //set Comments state PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "पत्र‍ांक दिनांक"; freeTextAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = freeTextAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim textAnnotationBounds As RectangleF = New RectangleF(10, 40, 100, 30) Dim freeTextAnnotation As PdfFreeTextAnnotation = New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font freeTextAnnotation.MarkupText = "Text Annotation" freeTextAnnotation.Font = New PdfTrueTypeFont(New Font("Nirmala UI", 14), True) freeTextAnnotation.ComplexScript = True 'Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "पत्र‍ांक दिनांक" freeTextAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = freeTextAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets or sets the text alignment to free text annotations //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation textAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font textAnnotation.MarkupText = "Text Annotation"; textAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond; //Sets the points array to be called out the lines textAnnotation.CalloutLines = new PointF[] { new PointF(0, 0), new PointF(1, 1) }; //Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red; //Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple; //Sets the text alignment of the text annotation. textAnnotation.TextAlignment = PdfTextAlignment.Right; textAnnotation.setAppearance(true); //Add this annotation to a new page. page.Annotations.Add(textAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim textAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font textAnnotation.MarkupText = "Text Annotation" textAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. textAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Set the line ending style. textAnnotation.LineEndingStyle = PdfLineEndingStyle.Diamond 'Sets the points array to be called out the lines textAnnotation.CalloutLines = New PointF() {New PointF(0, 0), New PointF(1, 1)} 'Sets the markup color of the text annotation. textAnnotation.TextMarkupColor = Color.Red 'Sets the border color of the text annotation. textAnnotation.BorderColor = Color.Purple 'Add this annotation to a new page. 'Sets the text alignment of the text annotation. textAnnotation.TextAlignment = PdfTextAlignment.Right textAnnotation.setAppearance(true) page.Annotations.Add(textAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Gets or sets the text direction to free text annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation freeTextAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font freeTextAnnotation.MarkupText = "Text Annotation"; freeTextAnnotation.ComplexScript = true; freeText.TextDirection = PdfTextDirection.RightToLeft; freeTextAnnotation.Font = new PdfTrueTypeFont(new Font("Nirmala UI", 14), true); //Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //set Comments state PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "أهلا بك"; freeTextAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = freeTextAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim textAnnotationBounds As RectangleF = New RectangleF(10, 40, 100, 30) Dim freeTextAnnotation As PdfFreeTextAnnotation = New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font freeTextAnnotation.MarkupText = "Text Annotation" freeTextAnnotation.Font = New PdfTrueTypeFont(New Font("Nirmala UI", 14), True) freeTextAnnotation.ComplexScript = True freeText.TextDirection = PdfTextDirection.RightToLeft 'Set the line caption type. freeTextAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "أهلا بك" freeTextAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = freeTextAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Represents a PDF circle annotation Used to represent the border style of the circle annotation. Initialise the new instance of the circle annotation with bounds and text. Used to represent the bounds of the annotation Used to represents the text of the annotation Initialise the new instance of the circle annotation with bounds. Used to represent the bounds of the annotation Initializes annotation object. Saves an annotation. Flatten Annotation Create appearance for annotation Gets the annotation reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new line annotation and set properties. PdfCircleAnnotation circleAnnotation = new PdfCircleAnnotation(rectangle); circleAnnotation.Text = "Circle"; //Add Review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; popup.Author = "Test1"; circleAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = circleAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim circleAnnotation As PdfCircleAnnotation = New PdfCircleAnnotation(rectangle) circleAnnotation.Text = "Circle" Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" popup.Author = "Test1" circleAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = circleAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new line annotation and set properties. PdfCircleAnnotation circleAnnotation = new PdfCircleAnnotation(rectangle); circleAnnotation.Text = "Circle"; //Add comment state PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; circleAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = circleAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim circleAnnotation As PdfCircleAnnotation = New PdfCircleAnnotation(rectangle) circleAnnotation.Text = "Circle" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" circleAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = circleAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Get or set the border style of the circle annotaion. Represents a PDF ellipse annotation Initialise the new instance of the ellipse annotation with bounds and text. Used to represent the bounds of the annotation Used to represents the text of the annotation Initializes annotation object. Saves an annotation. Gets the annotation reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new line annotation and set properties. PdfEllipseAnnotation ellipseAnnotation = new PdfEllipseAnnotation(rectangle, "Ellipse"); ellipseAnnotation.Text = "Circle"; //Add Review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; ellipseAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = ellipseAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim ellipseAnnotation As PdfEllipseAnnotation = New PdfEllipseAnnotation(rectangle, "Ellipse") ellipseAnnotation.Text = "Circle" Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" ellipseAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = ellipseAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim ellipseAnnotation As PdfEllipseAnnotation = New PdfEllipseAnnotation(rectangle, "Ellipse") ellipseAnnotation.Text = "Circle" Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" ellipseAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = ellipseAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation Comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new line annotation and set properties. PdfEllipseAnnotation ellipseAnnotation = new PdfEllipseAnnotation(rectangle, "Ellipse"); ellipseAnnotation.Text = "Circle"; //Add Comments state PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; ellipseAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = ellipseAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim ellipseAnnotation As PdfEllipseAnnotation = New PdfEllipseAnnotation(rectangle, "Ellipse") ellipseAnnotation.Text = "Circle" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" ellipseAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = ellipseAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Represents a Polygon annotation. Used to represent the border style of the circle annotation. An array of four numbers specifying the starting and ending coordinates To specifying the Leader Line Extension size Used to represent the border effect style of the polygon annotation. Initialise the new instance of the polygon annotation with bounds and text. Used to represent the poloygon points Used to represents the text of the annotation Initializes annotation object. Gets line points of the annotation. line points. Saves an annotation. Flatten Annotation Gets the annotation reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfPolygonAnnotation PolyConAnnotation = new PdfPolygonAnnotation(points, "Ploycon"); //Set the text and font PolyConAnnotation.Text = "Hello"; //set review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; PolyConAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = PolyConAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim PolyConAnnotation As PdfPolygonAnnotation = New PdfPolygonAnnotation(points, "Ploycon") 'Set the text and font PolyConAnnotation.Text = "Hello" Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" PolyConAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = PolyConAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfPolygonAnnotation PolyConAnnotation = new PdfPolygonAnnotation(points, "Ploycon"); //Set the text and font PolyConAnnotation.Text = "Hello"; // set comments PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; PolyConAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = PolyConAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim PolyConAnnotation As PdfPolygonAnnotation = New PdfPolygonAnnotation(points, "Ploycon") 'Set the text and font PolyConAnnotation.Text = "Hello" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" PolyConAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = PolyConAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Get or set the border effect of the Polygon annotation. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Create a new polygon Line int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfPolygonAnnotation polygonannotation = new PdfPolygonAnnotation(points, "Polygon"); //Set the text and font polygonannotation.Text = "Hello"; polygonannotation.InnerColor = new PdfColor(Color.Red); PdfBorderEffect borderEffect = new PdfBorderEffect(); borderEffect.Intensity=2; borderEffect.Style = PdfBorderEffectStyle.Cloudy; polygonannotation.BorderEffect = borderEffect; polygonannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Polygon Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page. page.Annotations.Add(polygonannotation); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim polygonannotation As PdfPolygonAnnotation = New PdfPolygonAnnotation(points, "Ploycon") 'Set the text and font polygonannotation.Text = "Hello" polygonannotation.InnerColor = New PdfColor(Color.Red) Dim borderEffect As PdfBorderEffect = New PdfBorderEffect() borderEffect.Intensity=2; borderEffect.Style = PdfBorderEffectStyle.Cloudy polygonannotation.BorderEffect = borderEffect polygonannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Polygon Annotation", font, brush, New PointF(0, 0)) 'Add annotation to the page. page.Annotations.Add(polygonannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Get or sets the border style of the square annotation. Gets or sets Leading Line Extension, Default value is 0 Represents a PolyLine annotation. To Specify the Border An array of four numbers specifying the starting and ending coordinates To specifying the Leader Line Extension size An array of two names specifying the line ending styles Indicates PdfLine Begin style Indicates PdfLine End style Initialise the new instance of the poly line annotation with bounds and text. Used to represent the poloygon points Used to represents the text of the annotation Initializes annotation object. Saves an annotation. Gets the annotation reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfPolyLineAnnotation PolylineAnnotation = new PdfPolyLineAnnotation(points, "Ployline"); //Set the text and font PolylineAnnotation.Text = "Hello"; //set review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; PolylineAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = PolylineAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim PolyConAnnotation As PdfPolygonAnnotation = New PdfPolygonAnnotation(points, "Ploycon") 'Set the text and font PolyConAnnotation.Text = "Hello" Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" PolyConAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = PolyConAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfPolyLineAnnotation PolylineAnnotation = new PdfPolyLineAnnotation(points, "Ployline"); //Set the text and font PolylineAnnotation.Text = "Hello"; //set comments PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; PolylineAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = PolylineAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim PolylineAnnotation As PdfPolyLineAnnotation = New PdfPolyLineAnnotation(points, "Ployline") 'Set the text and font PolylineAnnotation.Text = "Hello" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" PolylineAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = PolylineAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Get or sets the border style of the square annotaion. Gets or sets Leading Line Extension, Defacult value is 0 Gets or sets the style used for the beginning of the line, Default value is None Gets or sets the style used for the ending of the line, Default value is None Represents a PDF rectangle annotation //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Rectangle annotation. RectangleF rectannot = new RectangleF(0, 30, 100, 50); PdfRectangleAnnotation rectangleannotation = new PdfRectangleAnnotation(rectannot, "RectangleAnnotation"); rectangleannotation.InnerColor = new PdfColor(Color.Red); rectangleannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Rectangle Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page page.Annotations.Add(rectangleannotation); //Save the documnet. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) 'Creates a new Rectangle annotation. Dim rectannot As RectangleF = New RectangleF(0, 30, 100, 50) Dim rectangleannotation As PdfRectangleAnnotation = New PdfRectangleAnnotation(rectannot, "RectangleAnnotation") rectangleannotation.InnerColor = New PdfColor(Color.Red) rectangleannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Rectangle Annotation", font, brush, New PointF(0, 0)) 'Add the annotation to the page page.Annotations.Add(rectangleannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Represents a PDF square annotation //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Square annotation. PdfSquareAnnotation squareannotation = new PdfSquareAnnotation(new RectangleF(0, 30, 80, 80)); squareannotation.Text = "SquareAnnotation"; squareannotation.InnerColor = new PdfColor(Color.Red); squareannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Square Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page. page.Annotations.Add(squareannotation); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) 'Creates a new Square annotation. Dim squareannotation As PdfSquareAnnotation = New PdfSquareAnnotation(New RectangleF(0, 30, 80, 80)) squareannotation.Text = "SquareAnnotation" squareannotation.InnerColor = New PdfColor(Color.Red) squareannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Square Annotation", font, brush, New PointF(0, 0)) 'Add annotation to the page. page.Annotations.Add(squareannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Used to represent the border style of the square annotation. Used to represent the border effect style of the square annotation. Initialise the new instance of the square annotation with bounds and text. Used to represent the bounds of the annotation Used to represents the text of the annotation //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Square annotation. PdfSquareAnnotation squareannotation = new PdfSquareAnnotation(new RectangleF(0, 30, 80, 80),"SquareAnnotation"); squareannotation.InnerColor = new PdfColor(Color.Red); squareannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Square Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page. page.Annotations.Add(squareannotation); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) 'Creates a new Square annotation. Dim squareannotation As PdfSquareAnnotation = New PdfSquareAnnotation(New RectangleF(0, 30, 80, 80),"SquareAnnotation") squareannotation.InnerColor = New PdfColor(Color.Red) squareannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Square Annotation", font, brush, New PointF(0, 0)) 'Add annotation to the page. page.Annotations.Add(squareannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Initializes annotation object. Saves an annotation. Gets the annotation reviews PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Square annotation. PdfSquareAnnotation squareannotation = new PdfSquareAnnotation(new RectangleF(0, 30, 80, 80)); squareannotation.Text = "SquareAnnotation"; squareannotation.InnerColor = new PdfColor(Color.Red); squareannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Square Annotation", font, brush, new PointF(0, 0)); //Add review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; squareannotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = squareannotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add document.PageSettings.SetMargins(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10!) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim squareannotation As PdfSquareAnnotation = New PdfSquareAnnotation(New RectangleF(0, 30, 80, 80)) squareannotation.Text = "SquareAnnotation" squareannotation.InnerColor = New PdfColor(Color.Red) squareannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Square Annotation", font, brush, New PointF(0, 0)) Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" squareannotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = squareannotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Square annotation. PdfSquareAnnotation squareannotation = new PdfSquareAnnotation(new RectangleF(0, 30, 80, 80)); squareannotation.Text = "SquareAnnotation"; squareannotation.InnerColor = new PdfColor(Color.Red); squareannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Square Annotation", font, brush, new PointF(0, 0)); PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; squareannotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = squareannotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add document.PageSettings.SetMargins(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10!) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim squareannotation As PdfSquareAnnotation = New PdfSquareAnnotation(New RectangleF(0, 30, 80, 80)) squareannotation.Text = "SquareAnnotation" squareannotation.InnerColor = New PdfColor(Color.Red) squareannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Square Annotation", font, brush, New PointF(0, 0)) Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" squareannotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = squareannotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Get or set the border effect of the square annotation. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new square annotation. PdfSquareAnnotation squareannotation = new PdfSquareAnnotation(new RectangleF(0, 30, 80, 80)); squareannotation.Text = "SquareAnnotation"; squareannotation.InnerColor = new PdfColor(Color.Red); PdfBorderEffect borderEffect = new PdfBorderEffect(); borderEffect.Intensity=2; borderEffect.Style = PdfBorderEffectStyle.Cloudy; squareannotation.BorderEffect = borderEffect; squareannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Square Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page. page.Annotations.Add(squareannotation); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) 'Creates a new square annotation. Dim squareannotation As PdfSquareAnnotation = New PdfSquareAnnotation(New RectangleF(0, 30, 80, 80)) squareannotation.Text = "SquareAnnotation" squareannotation.InnerColor = New PdfColor(Color.Red) Dim borderEffect As PdfBorderEffect() borderEffect.Intensity=2; borderEffect.Style = PdfBorderEffectStyle.Cloudy squareannotation.BorderEffect = borderEffect squareannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Square Annotation", font, brush, New PointF(0, 0)) 'Add annotation to the page. page.Annotations.Add(squareannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Get or set the border style of the square annotation. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Square annotation. PdfSquareAnnotation squareannotation = new PdfSquareAnnotation(new RectangleF(0, 30, 80, 80)); squareannotation.Text = "SquareAnnotation"; squareannotation.InnerColor = new PdfColor(Color.Red); LineBorder border = new LineBorder(); border.BorderStyle = PdfBorderStyle.Solid; border.BorderWidth = 2; squareannotation.Border = border; squareannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Square Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page. page.Annotations.Add(squareannotation); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) 'Creates a new Square annotation. Dim squareannotation As PdfSquareAnnotation = New PdfSquareAnnotation(New RectangleF(0, 30, 80, 80)) squareannotation.Text = "SquareAnnotation" squareannotation.InnerColor = New PdfColor(Color.Red) Dim border As LineBorder = New LineBorder() border.BorderStyle = PdfBorderStyle.Solid border.BorderWidth = 2 squareannotation.Border = border squareannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Square Annotation", font, brush, New PointF(0, 0)) 'Add annotation to the page. page.Annotations.Add(squareannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Initialise the new instance of the rectangle annotation with bounds and text. Used to represent the bounds of the annotation Used to represents the text of the annotation //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Rectangle annotation. RectangleF rectannot = new RectangleF(0, 30, 100, 50); PdfRectangleAnnotation rectangleannotation = new PdfRectangleAnnotation(rectannot, "RectangleAnnotation"); rectangleannotation.InnerColor = new PdfColor(Color.Red); rectangleannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Rectangle Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page page.Annotations.Add(rectangleannotation); //Save the documnet. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) 'Creates a new Rectangle annotation. Dim rectannot As RectangleF = New RectangleF(0, 30, 100, 50) Dim rectangleannotation As PdfRectangleAnnotation = New PdfRectangleAnnotation(rectannot, "RectangleAnnotation") rectangleannotation.InnerColor = New PdfColor(Color.Red) rectangleannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Rectangle Annotation", font, brush, New PointF(0, 0)) 'Add the annotation to the page page.Annotations.Add(rectangleannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Initializes annotation object. Saves an annotation. Gets the annotation reviews //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Rectangle annotation. RectangleF rectannot = new RectangleF(0, 30, 100, 50); PdfRectangleAnnotation rectangleannotation = new PdfRectangleAnnotation(rectannot, "RectangleAnnotation"); rectangleannotation.InnerColor = new PdfColor(Color.Red); rectangleannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Rectangle Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page // Add review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; rectangleannotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = rectangleannotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add document.PageSettings.SetMargins(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10!) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim rectannot As RectangleF = New RectangleF(0, 30, 100, 50) Dim rectangleannotation As PdfRectangleAnnotation = New PdfRectangleAnnotation(rectannot, "RectangleAnnotation") rectangleannotation.InnerColor = New PdfColor(Color.Red) rectangleannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Rectangle Annotation", font, brush, New PointF(0, 0)) Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" rectangleannotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = rectangleannotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Rectangle annotation. RectangleF rectannot = new RectangleF(0, 30, 100, 50); PdfRectangleAnnotation rectangleannotation = new PdfRectangleAnnotation(rectannot, "RectangleAnnotation"); rectangleannotation.InnerColor = new PdfColor(Color.Red); rectangleannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Rectangle Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; rectangleannotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = rectangleannotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add document.PageSettings.SetMargins(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10!) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim rectannot As RectangleF = New RectangleF(0, 30, 100, 50) Dim rectangleannotation As PdfRectangleAnnotation = New PdfRectangleAnnotation(rectannot, "RectangleAnnotation") rectangleannotation.InnerColor = New PdfColor(Color.Red) rectangleannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Rectangle Annotation", font, brush, New PointF(0, 0)) Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" rectangleannotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = rectangleannotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Represents the PdfRedactionAnnotation. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Used to represent the border color of the redaction annotation. Used to represent the text color of the redaction annotation. Used to represent the font of the redaction annotation. Used to represent the text alignment of the redaction annotation. Used to represent the border of the redaction annotation. Used to represent the overlaytext of the redaction annotation. Used to represent the text repeat of the redaction annotation. Initialize the new instance of the redaction annotation. Initializes annotation object. Saves an annotation. Applyredaction for loadedpage. Get or set the textcolor of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Get or set the textalignment of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Get or set the overlaytext of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Get or set the font of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Get or set the bordercolor of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Get or set the border of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Get or set the text repeat of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.SetAppearance(true); ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.RepeatText = True annot.SetAppearance(True) page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Get or set flatten of redaction annotation //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Creates a new Redaction annotation. PdfRedactionAnnotation annot = new PdfRedactionAnnotation(); //set the bounds annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor annot.InnerColor = Color.Aqua; //set the bordercolor annot.BorderColor = Color.Orange; //set the textcolor annot.TextColor = Color.Yellow; //set the font annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext annot.OverlayText = "Redact"; //set textalignment annot.TextAlignment = PdfTextAlignment.Right; annot.Repeat = true; annot.Flatten=true; ////Add the annotation to the page. page.Annotations.Add(annot); //Saves the document to disk. doc.Save("empty.pdf"); doc.Close(true); System.Diagnostics.Process.Start("empty.pdf"); //Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() //Create a new page. Dim page As PdfPage = doc.Pages.Add() //Creates a new Redaction annotation. Dim annot As PdfRedactionAnnotation = New PdfRedactionAnnotation() //set the bounds annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor annot.InnerColor = Color.Aqua //set the bordercolor annot.BorderColor = Color.Orange //set the textcolor annot.TextColor = Color.Yellow annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) annot.OverlayText = "Redact" annot.TextAlignment = PdfTextAlignment.Right annot.Repeat = True annot.Flatten=true; page.Annotations.Add(annot) //Saves the document to disk. doc.Save("empty.pdf") doc.Close(True) System.Diagnostics.Process.Start("empty.pdf"); Represents the annotation with Angle Measurement. To Specify the Border An array of four numbers specifying the starting and ending coordinates To specifying the Leader Line Extension size Initializes new instance of class with specified points. Initializes annotation object. Gets line points of the annotation. line points. Save an annotation. Get or sets the border style of the Angle annotaion. Gets or sets the font of the angle text annotation Get or set the angle of Annotation. Represents the annotation with Circle Measurement. Used to represent the border style of the circle annotation. Initializes new instance of class with bounds. Used to represent the bounds of the annotation Initializes annotation object. Saves an annotation. Get or set the border style of the circle annotaion. Get or set PdfMeasurement Unit. Get or set the PdfCircleMeasurementType Gets or sets the font of the text annotation ` Represents the annotation with Line Measurement. To Specify the Line Border An array of four numbers specifying the starting and ending coordinates To specifying the Leader Line Extension size To specifying the Leader Line size To specifying the caption in the appearance of the line, To specifying the intent of the line annotation To specifying Caption Type To Specifying the LinePoints of the line annotation To specifying the Leader offset size To specifying the Begin line style. To specifying the End line style. Initializes new instance of class with specified points. The line points is to be drawn. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation and set properties. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points); lineAnnotation.Text = "Line Annotation"; //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt; lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond; lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default; //Assign the line color lineAnnotation.InnerLineColor = new PdfColor(Color.Green); lineAnnotation.BackColor = new PdfColor(Color.Green); //Assign the leader line lineAnnotation.LeaderLineExt = 0; lineAnnotation.LeaderLine = 0; //Assign the Line caption type lineAnnotation.LineCaption = true; lineAnnotation.CaptionType = PdfLineCaptionType.Inline; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation and set properties. Dim lineAnnotation As New PdfLineAnnotation(points) lineAnnotation.Text = "Line Annotation" 'Create pdf line border Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension 'Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Butt lineAnnotation.EndLineStyle = PdfLineEndingStyle.Diamond lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Default 'Assign the line color lineAnnotation.InnerLineColor = New PdfColor(Color.Green) lineAnnotation.BackColor = New PdfColor(Color.Green) 'Assign the leader line lineAnnotation.LeaderLineExt = 0 lineAnnotation.LeaderLine = 0 'Assign the Line caption type lineAnnotation.LineCaption = True lineAnnotation.CaptionType = PdfLineCaptionType.Inline 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Class Initializes annotation object. Gets line points of the annotation. line points. Obtain Line bounds from line points Saves an annotation. Gets or sets whether the line annotation caption should be displayed. true if the line caption should be displayed, otherwise false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the line caption. lineAnnotation.LineCaption = true; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the line caption. lineAnnotation.LineCaption = True 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the leader line The value specifies the leader line of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the leader line. lineAnnotation.LeaderLine = 10; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the leader line. lineAnnotation.LeaderLine = 10 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the LeaderLineExtension. The value specifies the leader line extension of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the leader line extension. lineAnnotation.LeaderLineExt = 10; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the leader line extension. lineAnnotation.LeaderLineExt = 10 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the border style of the LineAnnotation. A enumeration member specifying the border style for the line. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the line border. LineBorder lineBorder = new LineBorder(); lineBorder.DashArray = 1; lineAnnotation.lineBorder = lineBorder; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the line border. Dim lineBorder As LineBorder = New LineBorder() lineBorder.DashArray = 1 lineAnnotation.lineBorder = lineBorder 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the line caption text type of annotation. A enumeration specifying the line caption type. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Inline; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Inline 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the LineIntent of the annotation. A specifies the Line Intent Style is to be used in the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the line intent. lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the line intent. lineAnnotation.LineIntent = PdfLineIntent.LineDimension 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class To specifying the Inner Line color color with which to fill the annotation’s line endings. The which draws the outline of the inner color of the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the inner line color. lineAnnotation.InnerLineColor = new PdfColor(Color.Green); //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the inner line color. lineAnnotation.InnerLineColor = New PdfColor(Color.Green) 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the font of the text annotation ` Gets or sets the BackgroundColor of the PdfLineAnnotation. The which draws the border of the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Sets the line back color. lineAnnotation.BackColor = new PdfColor(Color.Green); //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Sets the line back color. lineAnnotation.BackColor = New PdfColor(Color.Green) 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the LinePoints of the PdfLineAnnotation. The value specifies array of the line points to be drawn. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(new RectangleF(100, 100, 100, 20)); //Sets the LinePoints. lineAnnotation.LinePoints = points; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(New RectangleF(100, 100, 100, 20)) 'Sets the LinePoints. lineAnnotation.LinePoints = points 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Get or set PdfMeasurement Unit. Gets or sets the leader offset The value specifies the leader offset of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(new RectangleF(100, 100, 100, 20)); //Sets the LinePoints. lineAnnotation.LinePoints = points; lineAnnotation.LeaderOffset = 20; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); Class Class Gets or sets the style used for the beginning of the line. A enumeration member specifying the begin style for the line. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(new RectangleF(100, 100, 100, 20)); //Sets the LinePoints. lineAnnotation.LinePoints = points; lineAnnotation.LeaderOffset = 20; lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Circle; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); Class Class Gets or sets the style used for the end of the line. A enumeration member specifying the end style for the line. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(new RectangleF(100, 100, 100, 20)); //Sets the LinePoints. lineAnnotation.LinePoints = points; lineAnnotation.LeaderOffset = 20; lineAnnotation.EndLineStyle = PdfLineEndingStyle.Circle; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); Class Class Represents the annotation with Square Measurement. Used to represent the border style of the square annotation. Initializes annotation object. Saves an annotation. Get or set PdfMeasurement Unit. Get or set the border style of the square annotaion. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); document.PageSettings.SetMargins(0); //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10f); PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); //Creates a new Square annotation. PdfSquareMeasurementAnnotation squareannotation = new PdfSquareMeasurementAnnotation(new RectangleF(0, 30, 80, 80)); squareannotation.Text = "SquareAnnotation"; squareannotation.InnerColor = new PdfColor(Color.Red); LineBorder border = new LineBorder(); border.BorderStyle = PdfBorderStyle.Solid; border.BorderWidth = 2; squareannotation.Border = border; squareannotation.Color = new PdfColor(Color.Yellow); page.Graphics.DrawString("Square Measurement Annotation", font, brush, new PointF(0, 0)); //Add the annotation to the page. page.Annotations.Add(squareannotation); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() document.PageSettings.SetMargins(0) 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10.0F) Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) 'Creates a new Square annotation. Dim squareannotation As PdfSquareMeasurementAnnotation = New PdfSquareMeasurementAnnotation(New RectangleF(0, 30, 80, 80)) squareannotation.Text = "SquareAnnotation" squareannotation.InnerColor = New PdfColor(Color.Red) Dim border As LineBorder = New LineBorder() border.BorderStyle = PdfBorderStyle.Solid border.BorderWidth = 2 squareannotation.Border = border squareannotation.Color = New PdfColor(Color.Yellow) page.Graphics.DrawString("Square Measurement Annotation", font, brush, New PointF(0, 0)) 'Add annotation to the page. page.Annotations.Add(squareannotation) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets or sets the font of the text annotation ` Check and handle Image metadata based on PDF/A conformance standard. Mapping complete glyph to width table for inconsistent character width Gets the details of character in the word. Get the text of glyph. Gets the bounds of glyph. Gets the font size of glyph. Gets the font name of glyph. Gets the font style of glyph. Details of the text present in a line Gets the text. Gets the font size of the text. It will be exposed to public once its implemented for Pdfium. Gets the font name of the text. It will be exposed to public once its implemented for Pdfium. Gets the font style of the text. It will be exposed to public once its implemented for Pdfium. Gets the collection of words present in the line. Gets the bounds of the text. Text lines collection in the page. Details of a word present in the line. Gets the text. Gets the bounds of the text. Gets the font size of the text. It will be exposed to public once its implemented for Pdfium. Gets the font name of the text. It will be exposed to public once its implemented for Pdfium. Gets the font style of the text. It will be exposed to public once its implemented for Pdfium. Gets the text glyph with bounds in the word. Represents the XFA Button Field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", new SizeF(70, 20)); //Set the caption text. buttonField.Content = "Click"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", New SizeF(70, 20)) 'Set the caption text. buttonField.Content = "Click" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Represents the abstract calss of the XFA form field's style parameters. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Represents abstract class of the field in the XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Convet XFA text alignment to PdfTextAlignment. Gets or sets the name. The name of the field. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Set field name. field.Name = "firstName"; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Set field name. field.Name = "firstName" 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the margins of the field. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Set margin. field.Margins.All = 2; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Set margin. field.Margins.All = 2 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the visibility of the field //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Set fields visibility. field.Visibility = PdfXfaVisibility.Visible; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Set fields visibility. field.Visibility = PdfXfaVisibility.Visible 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Set Margins, font, tooltip and alignments. Get the size of the field. Get the fields rotation angle. Gets or sets width of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets height of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the Border //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the tool tip //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the readonly //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set readonly. textBoxField.ReadOnly = true; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set readonly. textBoxField.ReadOnly = True 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the font //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the fore color of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the horizontal alignment of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the vertical alignment of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the rotation angle //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set fields width and height. textBoxField.Width = 200; textBoxField.Height = 30; //Set border. textBoxField.Border.Color = Color.Red; //Set font. textBoxField.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. textBoxField.ForeColor = Color.Yellow; //Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set fields width and height. textBoxField.Width = 200 textBoxField.Height = 30 'Set border. textBoxField.Border.Color = Color.Red 'Set font. textBoxField.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. textBoxField.ForeColor = Color.Yellow 'Set rotation angle. textBoxField.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set horizontal alignment. textBoxField.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set vertical alignment. textBoxField.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initialize the instance of the class. Name of the field Width and height of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", new SizeF(70, 20)); //Set the caption text. buttonField.Content = "Click"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", New SizeF(70, 20)) 'Set the caption text. buttonField.Content = "Click" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initialize the instance of the class. Name of the field Field width Field height //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", 70, 20); //Set the caption text. buttonField.Content = "Click"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", 70, 20) 'Set the caption text. buttonField.Content = "Click" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Save button field Save the acroform button field Creates a new object that is a copy of the current instance. The copy of the new object for this instance //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", 70, 20); //Set the caption text. buttonField.Content = "Click"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Clone the button field. PdfXfaButtonField clonedButton = buttonField.Clone() as PdfXfaButtonField; clonedButton.Content = "Submit"; mainForm.Fields.Add(clonedButton); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", 70, 20) 'Set the caption text. buttonField.Content = "Click" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Clone the button field. Dim clonedButton As PdfXfaButtonField = TryCast(buttonField.Clone(), PdfXfaButtonField) clonedButton.Content = "Submit" mainForm.Fields.Add(clonedButton) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the hightlight mode of the button field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", new SizeF(70, 20)); //Set the caption text. buttonField.Content = "Click"; //Set highlight mode. buttonField.Highlight = PdfHighlightMode.Push; //Set mouse rollover text. buttonField.MouseRolloverText = "Mouse entered"; //Set mouse down text. buttonField.MouseDownText = "Mouse pressed"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", New SizeF(70, 20)) 'Set the caption text. buttonField.Content = "Click" 'Set highlight mode. buttonField.Highlight = PdfHighlightMode.Push 'Set mouse rollover text. buttonField.MouseRolloverText = "Mouse entered" 'Set mouse down text. buttonField.MouseDownText = "Mouse pressed" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the mouse rollover text //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", new SizeF(70, 20)); //Set the caption text. buttonField.Content = "Click"; //Set highlight mode. buttonField.Highlight = PdfHighlightMode.Push; //Set mouse rollover text. buttonField.MouseRolloverText = "Mouse entered"; //Set mouse down text. buttonField.MouseDownText = "Mouse pressed"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", New SizeF(70, 20)) 'Set the caption text. buttonField.Content = "Click" 'Set highlight mode. buttonField.Highlight = PdfHighlightMode.Push 'Set mouse rollover text. buttonField.MouseRolloverText = "Mouse entered" 'Set mouse down text. buttonField.MouseDownText = "Mouse pressed" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the mouse down text of the button field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", new SizeF(70, 20)); //Set the caption text. buttonField.Content = "Click"; //Set highlight mode. buttonField.Highlight = PdfHighlightMode.Push; //Set mouse rollover text. buttonField.MouseRolloverText = "Mouse entered"; //Set mouse down text. buttonField.MouseDownText = "Mouse pressed"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", New SizeF(70, 20)) 'Set the caption text. buttonField.Content = "Click" 'Set highlight mode. buttonField.Highlight = PdfHighlightMode.Push 'Set mouse rollover text. buttonField.MouseRolloverText = "Mouse entered" 'Set mouse down text. buttonField.MouseDownText = "Mouse pressed" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the content of the button field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a button field and add the properties. PdfXfaButtonField buttonField = new PdfXfaButtonField("buttonField", new SizeF(70, 20)); //Set the caption text. buttonField.Content = "Click"; //Add the field to the XFA form. mainForm.Fields.Add(buttonField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a button field and add the properties. Dim buttonField As New PdfXfaButtonField("buttonField", New SizeF(70, 20)) 'Set the caption text. buttonField.Content = "Click" 'Add the field to the XFA form. mainForm.Fields.Add(buttonField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Represents the Caption of XFA fields //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initialize the instance of the caption //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() save the fields caption text Measure the caption string Measure the caption string Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); PdfXfaTextBoxField field1 = new PdfXfaTextBoxField("TextBox1", new SizeF(200, 20)); //Clone the caption. field1.Caption = caption.Clone() as PdfXfaCaption; mainForm.Fields.Add(field1); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) Dim field1 As New PdfXfaTextBoxField("TextBox1", New SizeF(200, 20)) 'Clone the caption. field1.Caption = TryCast(caption.Clone(), PdfXfaCaption) mainForm.Fields.Add(field1) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Read the existing node save the existing node set the new attribute for existing node convert string to point value read the font informations Gets or sets the caption text //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the font //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the horizontal alignment of the caption //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the vertical alignment of the caption //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the position of the caption //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the forecolor of the caption //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the width of the caption //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Represents the border of the XFA fields //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(); border.Color = Color.Red; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder() border.Color = Color.Red 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initialize the instance of class. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(); border.Color = Color.Red; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder() border.Color = Color.Red 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initialize the instance of class. Border color. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Get the border brush Get the border pen read the node save the existing node create a new edge node Set the new attribute for existing node Gets or sets the fill color of the border //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border fill color. border.FillColor = new PdfXfaSolidBrush(Color.Green); //Set handedness of the border. border.Handedness = PdfXfaHandedness.Right; //Set the style of the border. border.Style = PdfXfaBorderStyle.Raised; //Set the border visibility. border.Visibility = PdfXfaVisibility.Visible; //Set the border with. border.Width = 2; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border fill color. border.FillColor = New PdfXfaSolidBrush(Color.Green) 'Set handedness of the border. border.Handedness = PdfXfaHandedness.Right 'Set the style of the border. border.Style = PdfXfaBorderStyle.Raised 'Set the border visibility. border.Visibility = PdfXfaVisibility.Visible 'Set the border with. border.Width = 2 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets handedness of a line or edge //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border fill color. border.FillColor = new PdfXfaSolidBrush(Color.Green); //Set handedness of the border. border.Handedness = PdfXfaHandedness.Right; //Set the style of the border. border.Style = PdfXfaBorderStyle.Raised; //Set the border visibility. border.Visibility = PdfXfaVisibility.Visible; //Set the border with. border.Width = 2; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border fill color. border.FillColor = New PdfXfaSolidBrush(Color.Green) 'Set handedness of the border. border.Handedness = PdfXfaHandedness.Right 'Set the style of the border. border.Style = PdfXfaBorderStyle.Raised 'Set the border visibility. border.Visibility = PdfXfaVisibility.Visible 'Set the border with. border.Width = 2 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the visibility of the border //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border fill color. border.FillColor = new PdfXfaSolidBrush(Color.Green); //Set handedness of the border. border.Handedness = PdfXfaHandedness.Right; //Set the style of the border. border.Style = PdfXfaBorderStyle.Raised; //Set the border visibility. border.Visibility = PdfXfaVisibility.Visible; //Set the border with. border.Width = 2; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border fill color. border.FillColor = New PdfXfaSolidBrush(Color.Green) 'Set handedness of the border. border.Handedness = PdfXfaHandedness.Right 'Set the style of the border. border.Style = PdfXfaBorderStyle.Raised 'Set the border visibility. border.Visibility = PdfXfaVisibility.Visible 'Set the border with. border.Width = 2 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the left edge //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.LeftEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.LeftEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the right edge //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.RightEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.RightEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the top edge //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.TopEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.TopEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the bottom edge //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.BottomEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.BottomEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the border color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(); border.Color = Color.Red; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder() border.Color = Color.Red 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the border width //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border fill color. border.FillColor = new PdfXfaSolidBrush(Color.Green); //Set handedness of the border. border.Handedness = PdfXfaHandedness.Right; //Set the style of the border. border.Style = PdfXfaBorderStyle.Raised; //Set the border visibility. border.Visibility = PdfXfaVisibility.Visible; //Set the border with. border.Width = 2; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border fill color. border.FillColor = New PdfXfaSolidBrush(Color.Green) 'Set handedness of the border. border.Handedness = PdfXfaHandedness.Right 'Set the style of the border. border.Style = PdfXfaBorderStyle.Raised 'Set the border visibility. border.Visibility = PdfXfaVisibility.Visible 'Set the border with. border.Width = 2 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the border style //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border fill color. border.FillColor = new PdfXfaSolidBrush(Color.Green); //Set handedness of the border. border.Handedness = PdfXfaHandedness.Right; //Set the style of the border. border.Style = PdfXfaBorderStyle.Raised; //Set the border visibility. border.Visibility = PdfXfaVisibility.Visible; //Set the border with. border.Width = 2; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border fill color. border.FillColor = New PdfXfaSolidBrush(Color.Green) 'Set handedness of the border. border.Handedness = PdfXfaHandedness.Right 'Set the style of the border. border.Style = PdfXfaBorderStyle.Raised 'Set the border visibility. border.Visibility = PdfXfaVisibility.Visible 'Set the border with. border.Width = 2 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Represents the Edge of the XFA border //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.TopEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.TopEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.TopEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.TopEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() read the existing node Save the existing node Set new attribute clone the object Gets or sets the border color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.TopEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.TopEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the visibility //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.TopEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.TopEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the thickness of the edge //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.TopEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.TopEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the border style //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Create new PDF XFA edge instance. PdfXfaEdge edge = new PdfXfaEdge(); //Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered; //Set edge color. edge.Color = Color.HotPink; //Set edge thickness. edge.Thickness = 2; //Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible; //Set the edge to XFA border. border.TopEdge = edge; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Create new PDF XFA edge instance. Dim edge As New PdfXfaEdge() 'Set edge border style. edge.BorderStyle = PdfXfaBorderStyle.Lowered 'Set edge color. edge.Color = Color.HotPink 'Set edge thickness. edge.Thickness = 2 'Set edge visibility. edge.Visibility = PdfXfaVisibility.Visible 'Set the edge to XFA border. border.TopEdge = edge 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Represents the XFA corner //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the shape of the corner //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Specifies whether the corner appears convex or is inverted and appears concave. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the border color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the visibility //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the thickness //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the radius of the corner //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the border style //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the XFA brush //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the XFA solid brush. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaBrush brush = new PdfXfaSolidBrush(Color.Red); //Set the brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaBrush = New PdfXfaSolidBrush(Color.Red) 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize the instaces of the class. The fill color of the brush. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaBrush brush = new PdfXfaSolidBrush(Color.Red); //Set the brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaBrush = New PdfXfaSolidBrush(Color.Red) 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the solid brush color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaSolidBrush brush= new PdfXfaSolidBrush(Color.Red); //Set the color. brush.Color = Color.Green; //Set the brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaSolidBrush = New PdfXfaSolidBrush(Color.Red) 'Set the color. brush.Color = Color.Green 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the XFA linear brush //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() iniatilaize the new instance of the class. The start color of the linear brush. The end color of the linear brush. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() iniatilaize the new instance of the class. The start color of the linear brush. The end color of the linear brush. The type of the linar brush. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow, PdfXfaLinearType.RightToLeft); //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow, PdfXfaLinearType.RightToLeft) 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the starting color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaLinearBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaLinearType.RightToLeft; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaLinearBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaLinearType.RightToLeft 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the ending color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaLinearBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaLinearType.RightToLeft; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaLinearBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaLinearType.RightToLeft 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the direction of the color transition //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaLinearBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaLinearType.RightToLeft; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaLinearBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaLinearType.RightToLeft 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the XFA Radial brush //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaRadialType.CenterToEdge; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaRadialType.CenterToEdge 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() initialize the new instance of the class. The start color of the radial brush. The end color of the radial brush. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaRadialType.CenterToEdge; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaRadialType.CenterToEdge 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() initialize the new instance of the class. The start color of the radial brush. The end color of the radial brush. The radial type. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow, PdfXfaRadialType.CenterToEdge); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow, PdfXfaRadialType.CenterToEdge) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the starting color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaRadialType.CenterToEdge; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaRadialType.CenterToEdge 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the ending color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaRadialType.CenterToEdge; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaRadialType.CenterToEdge 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or set the direction of the color transition //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaRadialType.CenterToEdge; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaRadialType.CenterToEdge 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() The number of degrees by which the field should be rotated clockwise when displayed or printed. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Set rotation. rectangnle.Rotate = PdfXfaRotateAngle.RotateAngle90; //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Set rotation. rectangnle.Rotate = PdfXfaRotateAngle.RotateAngle90 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Indicates 0 degree rotation angle. Indicates 90 degree rotation angle. Indicates 180 degree rotation angle. Indicates 270 degree rotation angle. Specifies the available type for a XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() The content of the element is flowed in a direction proceeding from left to right. The content of the element is flowed in a direction proceeding from top to bottom. Specifies the corner shapes //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the border style. rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Squared corner Rounded corner Specifies the direction of the color transition. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaLinearBrush brush = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaLinearType.RightToLeft; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As PdfXfaLinearBrush = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaLinearType.RightToLeft 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() The start color appears at the left side of the object and transitions into the end color at the right side. The start color appears at the right side of the object and transitions into the end color at the left side. The start color appears at the bottom side of the object and transitions into the end color at the top side. The start color appears at the top side of the object and transitions into the end color at the bottom side. Specifies the direction of the color transition. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create new XFA brush. PdfXfaRadialBrush brush = new PdfXfaRadialBrush(Color.Red, Color.Yellow); //Set the start color. brush.StartColor = Color.Black; //Set the end color. brush.EndColor = Color.HotPink; //Set the type. brush.Type = PdfXfaRadialType.CenterToEdge; //Set the linear brush rect.Border.FillColor = brush; //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create new XFA brush. Dim brush As New PdfXfaRadialBrush(Color.Red, Color.Yellow) 'Set the start color. brush.StartColor = Color.Black 'Set the end color. brush.EndColor = Color.HotPink 'Set the type. brush.Type = PdfXfaRadialType.CenterToEdge 'Set the linear brush rect.Border.FillColor = brush 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() The start color appears at the center of the object and transitions into the end color at the outer edge. The start color appears at the outer edge of the object and transitions into the end color at the center. Represents the visibility of the XFA field //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Set fields visibility. field.Visibility = PdfXfaVisibility.Visible; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Set fields visibility. field.Visibility = PdfXfaVisibility.Visible 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Participate in interaction, layout, and rendering. Participate in interaction but not layout or rendering Do not participate in interaction, layout, or rendering Participate in interaction and layout but not rendering. Specifies the caption text position of fields //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Left side of the field Right side of the field Top of the field Bottom of the field Specifies Horizontal alignment //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Specifies the element is aligned to Left. Specifies the element is aligned to Center. Specifies the element is aligned to Right. Specifies the element is aligned with Justify Spread-justify all lines to fill the available region. Specifies the Vertical alignment //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Create new XFA caption instance. PdfXfaCaption caption = new PdfXfaCaption(); //Set caption text. caption.Text = "First Name"; //Set the caption font. caption.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the caption fore color. caption.ForeColor = new PdfColor(Color.Red); //Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set the caption position. caption.Position = PdfXfaPosition.Left; //Set the caption reserved width. caption.Width = 100; //Set the caption to text box. textBoxField.Caption = caption; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Create new XFA caption instance. Dim caption As New PdfXfaCaption() 'Set caption text. caption.Text = "First Name" 'Set the caption font. caption.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the caption fore color. caption.ForeColor = New PdfColor(Color.Red) 'Set the horizontal alignment. caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the vertical alignment. caption.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set the caption position. caption.Position = PdfXfaPosition.Left 'Set the caption reserved width. caption.Width = 100 'Set the caption to text box. textBoxField.Caption = caption 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Specifies the element is aligned to Top. Specifies the element is aligned to Middle. Specifies the element is aligned to Bottom. Represents the Appearance of the circle field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set start angle. circle.StartAngle = 90; //Set sweep angle. circle.SweepAngle = 270; //Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set start angle. circle.StartAngle = 90 'Set sweep angle. circle.SweepAngle = 270 'Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the circle shape Represents the ellipse shape Represents the arc shape Specifies the date pattern. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(200, 30)); //Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Date; //Set date pattern. field.DatePattern = PdfXfaDatePattern.Full; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(200, 30)) 'Set the default value field.Value = DateTime.Now 'Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Date 'Set date pattern. field.DatePattern = PdfXfaDatePattern.Full 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Appears the Default value eg: Nov 13, 2015 eg:11/13/2015. eg: Nov 13, 2015. November 13,2015. Thursday, November 12, 2015. 11/13/15. Nov 13,2015. November 13,2015. Friday, November 13, 2015. 11/13/2015. 11/13/15. 11/13/2015. 15/11/13. 2015-11-13. 13-Nov-15. Friday, November 13, 2015 November 13,15. Friday, 13 November, 2015. 13 November, 2015. November 2015. 30/10/2015 Represents the time patterns //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time; //Set time pattern. field.TimePattern = PdfXfaTimePattern.Long; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time //Set time pattern. field.TimePattern = PdfXfaTimePattern.Long 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() default value (eg: 10:43:01 AM) short(eg: 10:43 AM) Medium (eg: 10:43:01 AM) Long (eg: 10:43:01 AM GMT+05:30) full (eg: 10:43:01 AM GMT+05:30) eg:1:30 PM eg:1:30:30 PM eg:1:30:43 PM GMT+05:30 eg:01:30:30 PM eg:13:30:30 eg:13:30:30 Represents the date and time patterns default date time pattern short Medium Loing full Represent the datetime field format //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents date only Represents time onluy Represents date and times Represents the XFA checkBox style //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() default checked state. A check mark is used for the checked state. A circle is used for the checked state. A cross is used for the checked state. A diamond symbol is used for the checked state. A square is used for the checked state. A star is used for the checked state. Represents the XFA checkBox shape //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Squred checkBox Rounded checkBox Represent XFA border style //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border fill color. border.FillColor = new PdfXfaSolidBrush(Color.Green); //Set handedness of the border. border.Handedness = PdfXfaHandedness.Right; //Set the style of the border. border.Style = PdfXfaBorderStyle.Raised; //Set the border visibility. border.Visibility = PdfXfaVisibility.Visible; //Set the border with. border.Width = 2; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border fill color. border.FillColor = New PdfXfaSolidBrush(Color.Green) 'Set handedness of the border. border.Handedness = PdfXfaHandedness.Right 'Set the style of the border. border.Style = PdfXfaBorderStyle.Raised 'Set the border visibility. border.Visibility = PdfXfaVisibility.Visible 'Set the border with. border.Width = 2 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() No Border A solid rectangle surrounding. A dashed rectangle surrounding. A dotted rectangle surrounding. A dashed dotted rectangle surrounding. A dashed dotted dotted rectangle surrounding. A lowered rectangle surrounding. Raised rectangle surrounding. Etched rectangle surrounding. Embossed rectangle surrounding. Represents the handness of the XFA border //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set caption text. textBoxField.Caption.Text = "First Name"; //Create new PDF XFA border instance. PdfXfaBorder border = new PdfXfaBorder(Color.Red); //Set border fill color. border.FillColor = new PdfXfaSolidBrush(Color.Green); //Set handedness of the border. border.Handedness = PdfXfaHandedness.Right; //Set the style of the border. border.Style = PdfXfaBorderStyle.Raised; //Set the border visibility. border.Visibility = PdfXfaVisibility.Visible; //Set the border with. border.Width = 2; //Set border to text box field. textBoxField.Border = border; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200, 20)) 'Set caption text. textBoxField.Caption.Text = "First Name" 'Create new PDF XFA border instance. Dim border As New PdfXfaBorder(Color.Red) 'Set border fill color. border.FillColor = New PdfXfaSolidBrush(Color.Green) 'Set handedness of the border. border.Handedness = PdfXfaHandedness.Right 'Set the style of the border. border.Style = PdfXfaBorderStyle.Raised 'Set the border visibility. border.Visibility = PdfXfaVisibility.Visible 'Set the border with. border.Width = 2 'Set border to text box field. textBoxField.Border = border 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Position the displayed line immediately to the right of the underlying vector. Position the displayed line immediately to the left of the underlying vector. Center the displayed line on the underlying vector. Represents the Pdf XFA numeric field types //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Set field type. numericField.FieldType = PdfXfaNumericType.Integer; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Set field type. numericField.FieldType = PdfXfaNumericType.Integer 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the floating values Represents the decimal values Represents the integer values Represents the currency values Represents the persentage values Enumerator that implements XFA page orientations. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new PDF XFA page settings instance. PdfXfaPageSettings settings = new PdfXfaPageSettings(); //Set margin. settings.Margins.All = 40; //Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape; //Set page size. settings.PageSize = new SizeF(new SizeF(500, 700)); //Set page settings to document. document.PageSettings = settings; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new PDF XFA page settings instance. Dim settings As New PdfXfaPageSettings() 'Set margin. settings.Margins.All = 40 'Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape 'Set page size. settings.PageSize = New SizeF(New SizeF(500, 700)) 'Set page settings to document. document.PageSettings = settings 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Portrait orientation. Landscape orientation. Represents the XFA document type //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Preserved the XFA fields only. Preserved both the XFA and Acroform fields. Represents the text box type //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("Address", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "Address"; //Set the text box type. textBoxField.Type = PdfXfaTextBoxType.Multiline; //Set the tool tip. textBoxField.ToolTip = "Address"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("Address", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "Address" 'Set the text box type. textBoxField.Type = PdfXfaTextBoxType.Multiline 'Set the tool tip. textBoxField.ToolTip = "Address" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Specifies the single line of text. Specifies the multiline of text. Specifies the password character. Specifies comb of characters. Represents checkbox field of the XFA form. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The name of the check box field. The size of the check box field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The name of the check box field The size of the check box field The checked state of the check box //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30), true); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30), True) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. Name of the check box field. Check box field width. Check box field height. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", 100, 30); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", 100, 30) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. Name of the check box field. Check box field width. Check box field height. Checked state of the field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", 100, 30, true); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", 100, 30, True) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Save checkbox. Save acrform checkbox field. Get the acroform checkbox style. Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); //Clone the check box field. xfaForm.Fields.Add(field.Clone() as PdfXfaCheckBoxField); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) 'Clone the check box field. xfaForm.Fields.Add(TryCast(field.Clone(), PdfXfaCheckBoxField)) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the caption of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets a value indicating whether this is checked or not //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the checked Style of the check box field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the appearance of the check box field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the check box size //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create new XFA check box field. PdfXfaCheckBoxField field = new PdfXfaCheckBoxField("check1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "CheckBox"; //Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square; //Set the check box size. field.CheckBoxSize = 10; //Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross; //Set the check box checked state. field.IsChecked = true; //Add the field to form. xfaForm.Fields.Add(field); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create new XFA check box field. Dim field As New PdfXfaCheckBoxField("check1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "CheckBox" 'Set checkbox appearance. field.CheckBoxAppearance = PdfXfaCheckBoxAppearance.Square 'Set the check box size. field.CheckBoxSize = 10 'Set the checked style. field.CheckedStyle = PdfXfaCheckedStyle.Cross 'Set the check box checked state. field.IsChecked = True 'Add the field to form. xfaForm.Fields.Add(field) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the circle of the XFA form. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. Name of the field size of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. Name of the field. width of the field. height of the field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", 100, 100); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", 100, 100) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Save the circle field Draw the circle to PDF document. Get the fields rotation angle. Get the size of the field. Creates a new object that is a copy of the current instance. The copy of the new object for this instance //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Add the field to form. xfaForm.Fields.Add(circle); //Clone the circle field. xfaForm.Fields.Add(circle.Clone() as PdfXfaCircleField); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Add the field to form. xfaForm.Fields.Add(circle) 'Clone the circle field. xfaForm.Fields.Add(TryCast(circle.Clone() , PdfXfaCircleField)) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the border of the circle //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the tool tip of the circle //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the start angle of the arc The start angle only support when the circle is an arc type. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set start angle. circle.StartAngle = 90; //Set sweep angle. circle.SweepAngle = 270; //Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set start angle. circle.StartAngle = 90 'Set sweep angle. circle.SweepAngle = 270 'Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the sweep angle of the Arc The sweep angle only support when the circle is an arc type. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set start angle. circle.StartAngle = 90; //Set sweep angle. circle.SweepAngle = 270; //Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set start angle. circle.StartAngle = 90 'Set sweep angle. circle.SweepAngle = 270 'Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the apperance of the circle field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set start angle. circle.StartAngle = 90; //Set sweep angle. circle.SweepAngle = 270; //Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set start angle. circle.StartAngle = 90 'Set sweep angle. circle.SweepAngle = 270 'Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the rotation angle //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set start angle. circle.StartAngle = 90; //Set sweep angle. circle.SweepAngle = 270; //Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc; //Set rotation. circle.Rotate = PdfXfaRotateAngle.RotateAngle270; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set start angle. circle.StartAngle = 90 'Set sweep angle. circle.SweepAngle = 270 'Set the circle appearance. circle.Appearance = PdfXfaCircleAppearance.Arc 'Set rotation. circle.Rotate = PdfXfaRotateAngle.RotateAngle270 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets width of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Set the width. circle.Width = 200; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Set the width. circle.Width = 200 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets height of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm xfaForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); //Set margin of the form. xfaForm.Margins.All = 10; //Create a new XFA circle field. PdfXfaCircleField circle = new PdfXfaCircleField("circle1", new SizeF(100, 100)); //Set border. circle.Border = new PdfXfaBorder(); //Set border color. circle.Border.Color = new PdfColor(Color.Green); //Set tooltip. circle.ToolTip = "Circle"; //Set height. circle.Height = 200; //Add the field to form. xfaForm.Fields.Add(circle); document.XfaForm = xfaForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim xfaForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) 'Set margin of the form. xfaForm.Margins.All = 10 'Create a new XFA circle field. Dim circle As New PdfXfaCircleField("circle1", New SizeF(100, 100)) 'Set border. circle.Border = New PdfXfaBorder() 'Set border color. circle.Border.Color = New PdfColor(Color.Green) 'Set tooltip. circle.ToolTip = "Circle" 'Set height. circle.Height = 200 'Add the field to form. xfaForm.Fields.Add(circle) document.XfaForm = xfaForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the combo box field of the XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA combo box field PdfXfaComboBoxField field = new PdfXfaComboBoxField("combo1", new SizeF(100, 30)); //Add items. field.Items.Add("One"); field.Items.Add("Two"); field.Items.Add("Three"); field.Items.Add("Four"); field.Items.Add("Five"); //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA combo box field Dim field As New PdfXfaComboBoxField("combo1", New SizeF(100, 30)) 'Add items. field.Items.Add("One") field.Items.Add("Two") field.Items.Add("Three") field.Items.Add("Four") field.Items.Add("Five") 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. The name of the field. The size of the field. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA combo box field PdfXfaComboBoxField field = new PdfXfaComboBoxField("combo1", new SizeF(100, 30)); //Add items. field.Items.Add("One"); field.Items.Add("Two"); field.Items.Add("Three"); field.Items.Add("Four"); field.Items.Add("Five"); //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA combo box field Dim field As New PdfXfaComboBoxField("combo1", New SizeF(100, 30)) 'Add items. field.Items.Add("One") field.Items.Add("Two") field.Items.Add("Three") field.Items.Add("Four") field.Items.Add("Five") 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. The name of the field. Width of the field. Height of the field. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA combo box field PdfXfaComboBoxField field = new PdfXfaComboBoxField("combo1", 100, 30); //Add items. field.Items.Add("One"); field.Items.Add("Two"); field.Items.Add("Three"); field.Items.Add("Four"); field.Items.Add("Five"); //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA combo box field Dim field As New PdfXfaComboBoxField("combo1", 100, 30) 'Add items. field.Items.Add("One") field.Items.Add("Two") field.Items.Add("Three") field.Items.Add("Four") field.Items.Add("Five") 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Save combo box field. Save the acroform combo box field. set the size of the Choice list field Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA combo box field PdfXfaComboBoxField field = new PdfXfaComboBoxField("combo1", new SizeF(100, 30)); //Add items. field.Items.Add("One"); field.Items.Add("Two"); field.Items.Add("Three"); field.Items.Add("Four"); field.Items.Add("Five"); //Add the field to the form form.Fields.Add(field); //Clone the combo box field. form.Fields.Add(field.Clone() as PdfXfaComboBoxField); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA combo box field Dim field As New PdfXfaComboBoxField("combo1", New SizeF(100, 30)) 'Add items. field.Items.Add("One") field.Items.Add("Two") field.Items.Add("Three") field.Items.Add("Four") field.Items.Add("Five") 'Add the field to the form form.Fields.Add(field) 'Clone the combo box field. xfaForm.Fields.Add( TryCast(field.Clone(), PdfXfaComboBoxField)) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the date time field of the XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. Name of the field. Size of the field. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. Name of the field. Width of the field. Height of the field. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", 100, 30); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", 100, 30) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Save the Date time field. Save the acroform text box field. Set size set the date Pattern Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); //Clone the date time field. xfaForm.Fields.Add(field.Clone() as PdfXfaDateTimeField); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) 'Clone the date time field. xfaForm.Fields.Add(TryCast(field.Clone(), PdfXfaDateTimeField)) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the padding //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set paddings. field.Padding.All = 2; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set paddings. field.Padding.All = 2 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the caption of the field //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set caption. field.Caption.Text = "Date"; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set caption. field.Caption.Text = "Date" 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or Sets the value of date time field //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the date format //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(200, 30)); //Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Date; //Set date pattern. field.DatePattern = PdfXfaDatePattern.Full; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(200, 30)) 'Set the default value field.Value = DateTime.Now 'Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Date 'Set date pattern. field.DatePattern = PdfXfaDatePattern.Full 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the date time field format //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the time patterns //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time; //Set time pattern. field.TimePattern = PdfXfaTimePattern.Long; //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time //Set time pattern. field.TimePattern = PdfXfaTimePattern.Long 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the validations The validations doesn't supports to the dateTime type //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time; //Set time pattern. field.TimePattern = PdfXfaTimePattern.Long; //Set the default value field.Value = DateTime.Now; //Set validation. field.RequireValidation = true; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the format of the date time field. field.Format = PdfXfaDateTimeFormat.Time //Set time pattern. field.TimePattern = PdfXfaTimePattern.Long 'Set the default value field.Value = DateTime.Now 'Set validation. field.RequireValidation = True 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() The Syncfusion.Pdf.Xfa namespace contains classes used to create or fill the XFA form fields. Represents the XFA document //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initialize a new instance of the class. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Save XFA form. Save the document The output file name. The XFA form type. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Save the document The stream where to save the document. The type of the XFA form. The HTTP response stream object. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; MemoryStream stream = new MemoryStream(); //Save the document document.Save(stream, PdfXfaType.Dynamic, Response); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form Dim stream As MemoryStream = New MemoryStream() 'Save the document document.Save(stream, PdfXfaType.Dynamic, Response) 'Close the document document.Close() Save the document The name of the document. The type of the XFA form. The HTTP response stream object. The type of the reading document. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic, Response, HttpReadType.Open); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic, Response, HttpReadType.Open) 'Close the document document.Close() save the document The output stream. The xfa form type. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; MemoryStream stream = new MemoryStream(); //Save the document document.Save(stream, PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form Dim stream As MemoryStream = New MemoryStream() 'Save the document document.Save(stream, PdfXfaType.Dynamic) 'Close the document document.Close() Close the document //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Clone //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Clone the document. PdfXfaDocument cDocument = document.Clone() as PdfXfaDocument; //Save the document cDocument.Save("output.pdf", PdfXfaType.Dynamic); //Close the document cDocument.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Clone the document. PdfXfaDocument cDocument = TryCast(document.Clone(), PdfXfaDocument) 'Save the document cDocument.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document cDocument.Close() Gets or set page settings. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new PDF XFA page settings instance. PdfXfaPageSettings settings = new PdfXfaPageSettings(); //Set margin. settings.Margins.All = 40; //Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape; //Set page size. settings.PageSize = new SizeF(new SizeF(500, 700)); //Set page settings to document. document.PageSettings = settings; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new PDF XFA page settings instance. Dim settings As New PdfXfaPageSettings() 'Set margin. settings.Margins.All = 40 'Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape 'Set page size. settings.PageSize = New SizeF(New SizeF(500, 700)) 'Set page settings to document. document.PageSettings = settings 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Get the XFA page //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage page = document.Pages.Add(); //Set form name. document.FormName = "topmostform"; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim page As PdfXfaPage = document.Pages.Add() 'Set form name. document.FormName = "topmostform" 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the XFA form //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the form name. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Set form name. document.FormName = "topmostform"; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Set form name. document.FormName = "topmostform" 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the field collection of the XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Adds the specified field. The field item which is added in the PDF XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Remove the field. The field to be removed by the current collection. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); //Remove the field. collection.Remove(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) 'Remove the field. collection.Remove(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Remove field at the specified index. The index of the field to be removed by this collection. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); //Remove the field. collection.RemoveAt(0); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) 'Remove the field. collection.RemoveAt(0) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Clear all the fields. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); //Clear the fields. collection.Clear(); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) 'Clear the fields. collection.Clear() document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Insert field to the specified index. The index of the field to be inserted in the collection. The field to be inserted in the collection. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); //Insert the field. collection.Insert(0, field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) 'Insert the field. collection.insert(0, field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Determines the index of a specific field. The field. Retruns the index of the specific field. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); //Get the field index. int index = collection.IndexOf(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) 'Get the field index. Dim index As Integer = collection.IndexOf(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Clone the fields collection Get the field with the specific index. index. PdfXfaField. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); //Get the specific field by index. PdfXfaField field1 = collection[0]; document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) 'Get specific field by index. Dim field1 As PdfXfaField = collection(0) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Get the fields count. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Get the fields collection. PdfXfaFieldCollection collection = form.Fields; //Add the field to the collection. collection.Add(field); //Get the fields count. int count = collection.Count; document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Get the fields collection. Dim collection As PdfXfaFieldCollection = form.Fields 'Add the field to the collection. collection.Add(field) 'Get the fields count. Dim count As Integer = collection.Count document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents interactive XFA form of the Pdf document. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Reperesents the XFA form type Represents the XFA form field collections Data set writer of the XFA Represents the field count Repersents the current document Image array of the XFA Repersents the boder of the form Represents the width of the form Represents the readonly flag of the form Represents the xfa page Represents the PDF page Parent form Form save type Represents the PDF xfa document Represents the start point. Current position of the form Maximum size of the field Name of the subform. Acroform field collection. suform names field names. Size of the form. maximum size of the current field. Represents the current position of the form. Represents the page size. Represents the subform's current height. Represents the background heigh. Represents the background count. Dublicate of the xfa page. Represents the subform readOnly property. Initializes a new instance of the class. The width fo the form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The name of the form. The width of the form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm("form1", 595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm("form1", 595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The name of the form. The page. The width of the form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA page. PdfXfaPage page = document.Pages.Add(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm("form1", page, 595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA page. Dim page As PdfXfaPage = document.Pages.Add() 'Create a new XFA form Dim form As New PdfXfaForm("form1", page, 595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The name of the form. The flow direction of the XFA form The width of the form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm("form1", PdfXfaFlowDirection.Horizontal, 595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm("form1", PdfXfaFlowDirection.Horizontal, 595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The XFA page. The flow direction of the XFA form The width of the form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA page. PdfXfaPage page = document.Pages.Add(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(page, PdfXfaFlowDirection.Horizontal, 595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA page. Dim page As PdfXfaPage = document.Pages.Add() 'Create a new XFA form Dim form As New PdfXfaForm(page, PdfXfaFlowDirection.Horizontal, 595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The flow direction of the XFA form The width of the XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Initializes a new instance of the class. The name of the XFA form. The XFA page. The flow direction of the XFA form. The width of the XFA form. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA page. PdfXfaPage page = document.Pages.Add(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm("form1", page, PdfXfaFlowDirection.Horizontal, 595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA page. Dim page As PdfXfaPage = document.Pages.Add() 'Create a new XFA form Dim form As New PdfXfaForm("form1", page, PdfXfaFlowDirection.Horizontal, 595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() save XFA form Save the top most form Add the second level Parent form Draw the edge Get pens dash style. Add all the subforms Get the field names Get the sub form names Add all the subforms Break the subform to new page. Get the subforms background height. Draw the background color. Add a PDF page Set the current pont Set the background height. Find the subform width and height Write unsupported message in Dynamic XFA. Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Clone the form. form.Fields.Add(form.Clone() as PdfXfaForm); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Clone the form. form.Fields.Add(TryCase(form.Clone(), PdfXfaForm)); 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the XFA flow direction //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the border //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set border. form.Border = new PdfXfaBorder(Color.Red); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set border. form.Border = New PdfXfaBorder(Color.Red) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets the fields. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets readonly //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set readonly form. form.ReadOnly = true; //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set readonly form. form.ReadOnly = True 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets width of the form //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new XFA form PdfXfaForm form = new PdfXfaForm(595); //Set width. form.Width = 565; //Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal; //Create a new XFA Field PdfXfaTextBoxField field = new PdfXfaTextBoxField("textBox1", new SizeF(200, 30)); //Set text. field.Text = "Text Box Field."; //Add the field to the XFA form. form.Fields.Add(field); //Assign the form to document. document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new XFA form Dim form As New PdfXfaForm(595) 'Set width. form.Width = 565 'Set the flow direction. form.FlowDirection = PdfXfaFlowDirection.Horizontal 'Create a new XFA Field Dim field As New PdfXfaTextBoxField("textBox1", New SizeF(200, 30)) 'Set text. field.Text = "Text Box Field." 'Add the field to the XFA form. form.Fields.Add(field) 'Assign the form to document. document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or set the XFA Page. Represents image field in the XFA form. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", "image.jpg"); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", "image.jpg") 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image path. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", "image.jpg"); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", "image.jpg") 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image path. Image size. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", "image.jpg", new SizeF(100,100)); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", "image.jpg", New SizeF(100,100)) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. The image name. The image path. The width of the image. The height of the image. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", "image.jpg", 100, 100); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", "image.jpg", 100, 100) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", Image.FromFile("image.jpg")); //Set image size. image.Size = new SizeF(100, 100); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", Image.FromFile("image.jpg")) 'Set image size. image.Size = New SizeF(100, 100) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image. Width. Height. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", Image.FromFile("image.jpg"), 100, 100); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", Image.FromFile("image.jpg"), 100, 100) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image. Image size. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", Image.FromFile("image.jpg"), new SizeF(100,100)); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", Image.FromFile("image.jpg"), New SizeF(100,100)) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. PDF bitmap //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", new PdfBitmap("image.jpg")); //Set image size. image.Size = new SizeF(100, 100); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", New PdfBitmap("image.jpg")) 'Set image size. image.Size = New SizeF(100, 100) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image stream //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); Stream imageStream = new MemoryStream(File.ReadAllBytes("image.jpg")); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", imageStream); //Set image size. image.Size = new SizeF(100, 100); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) Dim imageStream As Stream = New MemoryStream(File.ReadAllBytes("image.jpg")) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", imageStream) 'Set image size. image.Size = New SizeF(100, 100) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image stream. Size of the image. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); Stream imageStream = new MemoryStream(File.ReadAllBytes("image.jpg")); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", imageStream, new SizeF(100,100)); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) Dim imageStream As Stream = New MemoryStream(File.ReadAllBytes("image.jpg")) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", imageStream, New SizeF(100,100)) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Image name. Image to be drawn in XFA form. Image width Image height //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); Stream imageStream = new MemoryStream(File.ReadAllBytes("image.jpg")); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", imageStream, 100, 100); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) Dim imageStream As Stream = New MemoryStream(File.ReadAllBytes("image.jpg")) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", imageStream, 100, 100) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'close the document document.Close() initialize a new instance of the class Save the image field. Save the image to the PDF document. Get the fields rotation angle. Clone. Gets or sets the image stream Gets or sets the image size //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", "image.jpg"); //Set image size. image.Size = new SizeF(100, 100); //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", "image.jpg") 'Set image size. image.Size = New SizeF(100, 100) 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Bounds of the image Get or set the subform name Gets or sets the rotation angle //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a image and add the properties. PdfXfaImage image = new PdfXfaImage("image1", "image.jpg"); //Set image size. image.Size = new SizeF(100, 100); //Set the rotation angle. image.Rotate = PdfXfaRotateAngle.RotateAngle90; //Add the image to the XFA form. mainForm.Fields.Add(image); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a image and add the properties. Dim image As New PdfXfaImage("image1", "image.jpg") 'Set image size. image.Size = New SizeF(100, 100) 'Set the rotation angle. image.Rotate = PdfXfaRotateAngle.RotateAngle90 'Add the image to the XFA form. mainForm.Fields.Add(image) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the line of the XFA form //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a line and add the properties. PdfXfaLine line = new PdfXfaLine(new PointF(0, 0), new PointF(200, 0), 3); //Set the line color line.Color = new PdfColor(Color.Red); //Add the text line to the XFA form. mainForm.Fields.Add(line); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a line and add the properties. Dim line As New PdfXfaLine(New PointF(0,0),New PointF(200,0),3) 'Set the line color line.Color = New PdfColor(Color.Red) 'Add the text line to the XFA form. mainForm.Fields.Add(line) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Start location of the Line. End location of the Line. Thickness of the Line. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a line and add the properties. PdfXfaLine line = new PdfXfaLine(new PointF(0, 0), new PointF(200, 0), 3); //Set the line color line.Color = new PdfColor(Color.Red); //Add the text line to the XFA form. mainForm.Fields.Add(line); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a line and add the properties. Dim line As New PdfXfaLine(New PointF(0,0),New PointF(200,0),3) 'Set the line color line.Color = New PdfColor(Color.Red) 'Add the text line to the XFA form. mainForm.Fields.Add(line) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the line. Draw the line in PDF document. Get the size of the field. Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a line and add the properties. PdfXfaLine line = new PdfXfaLine(new PointF(0, 0), new PointF(200, 0), 3); //Set the line color line.Color = new PdfColor(Color.Red); //Add the text line to the XFA form. mainForm.Fields.Add(line); //Clone the line object. mainForm.Fields.Add(line.Clone() as PdfXfaLine); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a line and add the properties. Dim line As New PdfXfaLine(New PointF(0,0),New PointF(200,0),3) 'Set the line color line.Color = New PdfColor(Color.Red) 'Add the text line to the XFA form. mainForm.Fields.Add(line) 'Clone the line object. mainForm.Fields.Add(TryCase(line.Clone(), PdfXfaLine)) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the line color //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a line and add the properties. PdfXfaLine line = new PdfXfaLine(new PointF(0, 0), new PointF(200, 0), 3); //Set the line color line.Color = new PdfColor(Color.Red); //Add the text line to the XFA form. mainForm.Fields.Add(line); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a line and add the properties. Dim line As New PdfXfaLine(New PointF(0,0),New PointF(200,0),3) 'Set the line color line.Color = New PdfColor(Color.Red) 'Add the text line to the XFA form. mainForm.Fields.Add(line) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the thickness of the line //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a line and add the properties. PdfXfaLine line = new PdfXfaLine(new PointF(0, 0), new PointF(200, 0), 3); //Set the line color line.Color = new PdfColor(Color.Red); //Set thickness. line.Thickness = 2; //Add the text line to the XFA form. mainForm.Fields.Add(line); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a line and add the properties. Dim line As New PdfXfaLine(New PointF(0,0),New PointF(200,0),3) 'Set the line color line.Color = New PdfColor(Color.Red) 'Set thickness line.Thickness = 2 'Add the text line to the XFA form. mainForm.Fields.Add(line) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the list box field of the XFA form. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Field name. Field size. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Field name. Field width. Field height. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", 150, 50); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", 150, 50) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the list box field. Save the acroform list box. set the size of the list field Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Clone the list box. mainForm.Fields.Add(listBoxField.Clone() as PdfXfaListBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Clone the list box. mainForm.Fields.Add(TryCase(listBoxField.Clone(), PdfXfaListBoxField)) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the padding //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set padding. listBoxField.Padding.All = 2; //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set padding. listBoxField.Padding.All = 2 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the caption of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the list box items //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the selected index //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Set the selected index. listBoxField.SelectedIndex = 1; //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Set the selected index. listBoxField.SelectedIndex = 1 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the selected value //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Set the selected value. listBoxField.SelectedValue = "French"; //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Set the selected value. listBoxField.SelectedValue = "French" 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets selection mode of the list box field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Set the selection mode. listBoxField.SelectionMode = PdfXfaSelectionMode.Single; //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Set the selection mode. listBoxField.SelectionMode = PdfXfaSelectionMode.Single 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the List box selection mode. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a list box field and add the properties. PdfXfaListBoxField listBoxField = new PdfXfaListBoxField("listBoxField", new SizeF(150, 50)); //Set the caption text. listBoxField.Caption.Text = "Known Languages"; listBoxField.Caption.Position = PdfXfaPosition.Top; listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Add the list box items listBoxField.Items.Add("English"); listBoxField.Items.Add("French"); listBoxField.Items.Add("German"); //Set the selection mode. listBoxField.SelectionMode = PdfXfaSelectionMode.Single; //Add the field to the XFA form. mainForm.Fields.Add(listBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a list box field and add the properties. Dim listBoxField As New PdfXfaListBoxField("listBoxField", New SizeF(150, 50)) 'Set the caption text. listBoxField.Caption.Text = "Known Languages" listBoxField.Caption.Position = PdfXfaPosition.Top listBoxField.Caption.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Add the list box items listBoxField.Items.Add("English") listBoxField.Items.Add("French") listBoxField.Items.Add("German") 'Set the selection mode. listBoxField.SelectionMode = PdfXfaSelectionMode.Single 'Add the field to the XFA form. mainForm.Fields.Add(listBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Single item selection mode. Multiple item selection mode. Represents the numeric field of the XFA form. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Field name. Field size. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Field name. Field width. Field height. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", 200, 20); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", 200,20) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the numeric field. Save acroform textbox field. set the size of the numeric field Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Clone the numeric field. mainForm.Fields.Add(numericField.Clone() as PdfXfaNumericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) //Clone the numeric field. mainForm.Fields.Add(TryCast(numericField.Clone(), PdfXfaNumericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or set the Culture. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set culture. numericField.Culture = "fr-FR"; //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set culture. numericField.Culture = "fr-FR" 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the caption of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the padding of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set padding. numericField.Padding.All = 2; //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set padding. numericField.Padding = 2 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the numeric field value //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Set the value. numericField.Value = 12345; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Set the value. numericField.Value = 12345; 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the comb length //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Set the comb lengh. numericField.CombLengh = 5; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Set the comb length. numericField.CombLength = 5 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the numeric field types //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Set field type. numericField.FieldType = PdfXfaNumericType.Integer; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Set field type. numericField.FieldType = PdfXfaNumericType.Integer 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the pattern string //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add new XFA page PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form with horizontal flow direction PdfXfaForm mainForm = new PdfXfaForm(xfaPage, PdfXfaFlowDirection.Horizontal, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Set the pattern string numericField.PatternString = "zzzzzzzzz9"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add new XFA page Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form with horizontal flow direction Dim mainForm As New PdfXfaForm(xfaPage, PdfXfaFlowDirection.Horizontal, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200, 20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Set the pattern string numericField.PatternString = "zzzzzzzzz9" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Represents the PDF Xfa page. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialized the new instance of the class. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the page. Get the content area Returns the client size of the page. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the XFA page collection //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Intialize the new instance of the class. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Add new XFA page XFA page object //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets the page using index value. page index. PdfXfaPage //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", document.Pages[0], xfaPage.GetClientSize().Width); //Create a numeric field and add the properties. PdfXfaNumericField numericField = new PdfXfaNumericField("numericField", new SizeF(200, 20)); //Set the caption text. numericField.Caption.Text = "Numeric Field"; //Add the field to the XFA form. mainForm.Fields.Add(numericField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", document.Pages[0], xfaPage.GetClientSize().Width) 'Create a numeric field and add the properties. Dim numericField As New PdfXfaNumericField("numericField", New SizeF(200,20)) 'Set the caption text. numericField.Caption.Text = "Numeric Field" 'Add the field to the XFA form. mainForm.Fields.Add(numericField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("output.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the XFA page settings. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new PDF XFA page settings instance. PdfXfaPageSettings settings = new PdfXfaPageSettings(); //Set margin. settings.Margins.All = 40; //Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape; //Set page size. settings.PageSize = new SizeF(new SizeF(500, 700)); //Set page settings to document. document.PageSettings = settings; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new PDF XFA page settings instance. Dim settings As New PdfXfaPageSettings() 'Set margin. settings.Margins.All = 40 'Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape 'Set page size. settings.PageSize = New SizeF(New SizeF(500, 700)) 'Set page settings to document. document.PageSettings = settings 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the XFA page orientation //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new PDF XFA page settings instance. PdfXfaPageSettings settings = new PdfXfaPageSettings(); //Set margin. settings.Margins.All = 40; //Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape; //Set page size. settings.PageSize = new SizeF(new SizeF(500, 700)); //Set page settings to document. document.PageSettings = settings; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new PDF XFA page settings instance. Dim settings As New PdfXfaPageSettings() 'Set margin. settings.Margins.All = 40 'Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape 'Set page size. settings.PageSize = New SizeF(New SizeF(500, 700)) 'Set page settings to document. document.PageSettings = settings 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the XFA page size //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new PDF XFA page settings instance. PdfXfaPageSettings settings = new PdfXfaPageSettings(); //Set margin. settings.Margins.All = 40; //Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape; //Set page size. settings.PageSize = new SizeF(new SizeF(500, 700)); //Set page settings to document. document.PageSettings = settings; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new PDF XFA page settings instance. Dim settings As New PdfXfaPageSettings() 'Set margin. settings.Margins.All = 40 'Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape 'Set page size. settings.PageSize = New SizeF(New SizeF(500, 700)) 'Set page settings to document. document.PageSettings = settings 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or set margins. //Create a new XFA document PdfXfaDocument document = new PdfXfaDocument(); //Create a new PDF XFA page settings instance. PdfXfaPageSettings settings = new PdfXfaPageSettings(); //Set margin. settings.Margins.All = 40; //Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape; //Set page size. settings.PageSize = new SizeF(new SizeF(500, 700)); //Set page settings to document. document.PageSettings = settings; //Create a new XFA form PdfXfaForm form = new PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595); //Create a new XFA Field PdfXfaDateTimeField field = new PdfXfaDateTimeField("dateTime1", new SizeF(100, 30)); //Set the default value field.Value = DateTime.Now; //Add the field to the form form.Fields.Add(field); document.XfaForm = form; //Save the document document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new XFA document Dim document As New PdfXfaDocument() 'Create a new PDF XFA page settings instance. Dim settings As New PdfXfaPageSettings() 'Set margin. settings.Margins.All = 40 'Set page orientation. settings.PageOrientation = PdfXfaPageOrientation.Landscape 'Set page size. settings.PageSize = New SizeF(New SizeF(500, 700)) 'Set page settings to document. document.PageSettings = settings 'Create a new XFA form Dim form As New PdfXfaForm(PdfXfaFlowDirection.Horizontal, 595) 'Create a new XFA Field Dim field As New PdfXfaDateTimeField("dateTime1", New SizeF(100, 30)) 'Set the default value field.Value = DateTime.Now 'Add the field to the form form.Fields.Add(field) document.XfaForm = form 'Save the document document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Represents the XFA radio button field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Name of the radio button field. Size of the radio button field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Name of the radio button field. Width of the radio button field. Height of the radio button field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", 80, 20); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", 80, 20); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", 80, 20) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", 80, 20) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the radio button field. Set Margins, font, tooltip and alignments. Save acroform radio button field. Convert XFA check box style to acroform check box style. Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Clone the radio button. group.Items.Add(radioButtonField2.Clone() as PdfXfaRadioButtonField); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Clone the radio button. group.Items.Add( TryCase(radioButtonField2.Clone(), PdfXfaRadioButtonField)) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets a value indicating whether this is checked or not. true if checked; otherwise, false. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; radioButtonField2.IsChecked = true; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" radioButtonField2.IsChecked = True 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the caption of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the checked style of the radio button //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Set the checked style. radioButtonField2.CheckedStyle = PdfXfaCheckedStyle.Cross; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Set the checked style. radioButtonField2.CheckedStyle = PdfXfaCheckedStyle.Cross 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the appearance of the radio button //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Set the button appearance. radioButtonField2.RadioButtonAppearance = PdfXfaCheckBoxAppearance.Square; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Set the button appearance. radioButtonField2.RadioButtonAppearance = PdfXfaCheckBoxAppearance.Square 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the size of the radio button //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Set the radio button size. radioButtonField2.RadioButtonSize = 10; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Set the radio button size. radioButtonField2.RadioButtonSize = 10 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the XFA radio button group field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initalize the instance of the PdfXFARadioButtonItemGroup class The name of the radio button group field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the radio button Group Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Clone the radio group. mainForm.Fields.Add(group.Clone() as PdfXfaRadioButtonGroup); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Clone the radio group. mainForm.Fields.Add(TryCase(group.Clone(), PdfXfaRadioButtonGroup)) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the readonly //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); //Set read only. group.ReadOnly = true; group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") 'Set read only. group.ReadOnly = True group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the radio list items //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the layout type //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the radio button list item. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a radio button group PdfXfaRadioButtonGroup group = new PdfXfaRadioButtonGroup("radioGroup"); group.FlowDirection = PdfXfaFlowDirection.Vertical; //Create a radio button field and add the properties. PdfXfaRadioButtonField radioButtonField1 = new PdfXfaRadioButtonField("r1", new SizeF(80, 20)); //Set the caption text. radioButtonField1.Caption.Text = "Male"; PdfXfaRadioButtonField radioButtonField2 = new PdfXfaRadioButtonField("r2", new SizeF(80, 20)); radioButtonField2.Caption.Text = "Female"; //Add the radio button fields to the radio button group group.Items.Add(radioButtonField1); group.Items.Add(radioButtonField2); //Add the field to the XFA form. mainForm.Fields.Add(group); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a radio button group Dim group As New PdfXfaRadioButtonGroup("radioGroup") group.FlowDirection = PdfXfaFlowDirection.Vertical 'Create a radio button field and add the properties. Dim radioButtonField1 As New PdfXfaRadioButtonField("r1", New SizeF(80, 20)) 'Set the caption text. radioButtonField1.Caption.Text = "Male" Dim radioButtonField2 As New PdfXfaRadioButtonField("r2", New SizeF(80, 20)) radioButtonField2.Caption.Text = "Female" 'Add the radio button fields to the radio button group group.Items.Add(radioButtonField1) group.Items.Add(radioButtonField2) 'Add the field to the XFA form. mainForm.Fields.Add(group) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents the XFA rectangle field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Field name. Field size. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Field name. Field width. Field height. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", 100, 50); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", 100,50) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the rectangle field. Draw the rectangle field to PDF document. Get the fields rotation angle. Get the size of the field. Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Clone the rectangle field. mainForm.Fields.Add(rectangle.Clone() as PdfXfaRectangleField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Clone the rectangle field. mainForm.Fields.Add(TryCase(rectangle.Clone(), PdfXfaRectangleField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the border //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the tool tip //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Set tool tip. rectangle.ToolTip ="This the rectangle"; //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Set tool tip. rectangle.ToolTip = "This is the rectangle" 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the cornor shaps //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Create a form. PdfXfaForm parentForm = new PdfXfaForm(PdfXfaFlowDirection.Vertical, 595); parentForm.Margins.All = 10; //Create new XFA rectangle instance. PdfXfaRectangleField rect = new PdfXfaRectangleField("rect1", new SizeF(200, 100)); //Create a new corner instance. PdfXfaCorner corner = new PdfXfaCorner(); //Set inverted. corner.IsInverted = true; //Set corner shape. corner.Shape = PdfXfaCornerShape.Round; //Set corner thickness corner.Thickness = 5; //Set corner border color. corner.BorderColor = Color.Green; //Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid; //Set the radius of the corner. corner.Radius = 5f; //Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible; //Set the corner of the rectangle rect.Corner = corner; //Set the fill color of the rectangle rect.Border.Style = PdfXfaBorderStyle.Solid; //Set rectangle border width. rect.Border.Width = 5; //Set the linear brush rect.Border.FillColor = new PdfXfaLinearBrush(Color.Red, Color.Yellow); //Add the field to form. parentForm.Fields.Add(rect); document.XfaForm = parentForm; //Save the document. document.Save("output.pdf", PdfXfaType.Dynamic); //Close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Create a form. Dim parentForm As New PdfXfaForm(PdfXfaFlowDirection.Vertical, 595) parentForm.Margins.All = 10 'Create new XFA rectangle instance. Dim rect As New PdfXfaRectangleField("rect1", New SizeF(200, 100)) 'Create a new corner instance. Dim corner As New PdfXfaCorner() 'Set inverted. corner.IsInverted = True 'Set corner shape. corner.Shape = PdfXfaCornerShape.Round 'Set corner thickness corner.Thickness = 5 'Set corner border color. corner.BorderColor = Color.Green 'Set the corner border style. corner.BorderStyle = PdfXfaBorderStyle.Solid 'Set the radius of the corner. corner.Radius = 5F 'Set the visibility of the corner. corner.Visibility = PdfXfaVisibility.Visible 'Set the corner of the rectangle rect.Corner = corner 'Set the fill color of the rectangle rect.Border.Style = PdfXfaBorderStyle.Solid 'Set rectangle border width. rect.Border.Width = 5 'Set the linear brush rect.Border.FillColor = New PdfXfaLinearBrush(Color.Red, Color.Yellow) 'Add the field to form. parentForm.Fields.Add(rect) document.XfaForm = parentForm 'Save the document. document.Save("output.pdf", PdfXfaType.Dynamic) 'Close the document document.Close() Gets or sets the rotation angle //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Set rotation. rectangnle.Rotate = PdfXfaRotateAngle.RotateAngle90; //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Set rotation. rectangnle.Rotate = PdfXfaRotateAngle.RotateAngle90 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets width of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Set width. rectangle.Width = 150; //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Set width. rectangle.Width = 150 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets sets height of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a rectangle field and add the properties. PdfXfaRectangleField rectangle = new PdfXfaRectangleField("rect1", new SizeF(100, 50)); //Set the fill color rectangle.Border.FillColor = new PdfXfaSolidBrush(Color.Red); //Set height. rectangle.Height = 100; //Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a rectangle field and add the properties. Dim rectangle As New PdfXfaRectangleField("rect1", New SizeF(100,50)) 'Set the fill color rectangle.Border.FillColor = New PdfXfaSolidBrush(Color.Red) 'Set height. rectangle.Height = 100 'Add the rectangle field to the XFA form. mainForm.Fields.Add(rectangle) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents textbox field in the XFA form. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. Name of the text box field. Minimum size of the text box field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Name of the text box field Minimum size of the text box Default value of the text box //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20), "John"); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20), "John") 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Name of the text box field Minimum size of the text box Default value of the text box Text box field type //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20), "John", PdfXfaTextBoxType.SingleLine); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20), "John", PdfXfaTextBoxType.SingleLine) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Name of the text box field Minimum size of the text box Text box field type //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20), PdfXfaTextBoxType.SingleLine); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20), PdfXfaTextBoxType.SingleLine) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Name of the text box field Minimum width of the text box field. Minimum height of the text box field. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", 200, 20); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", 200,20) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Name of the text box field Minimum width of the text box field. Minimum height of the text box field. Default value of the text box //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", 200, 20, "John"); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", 200, 20, "John") 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Name of the text box field Minimum width of the text box field. Minimum height of the text box field. ext box field type //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", 200, 20, PdfXfaTextBoxType.SingleLine); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", 200, 20, PdfXfaTextBoxType.SingleLine) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Name of the text box field Minimum width of the text box field. Minimum height of the text box field. Default value of the text box Text box field type //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", 200, 20, "John", PdfXfaTextBoxType.SingleLine); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", 200, 20, "John", PdfXfaTextBoxType.SingleLine) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the text box field. Save the text box field. Save the acroform textbox field. set the size of the textbox field Get the size of the text box field. Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Clone the text box field. mainForm.Fields.Add(textBoxField.Clone() as PdfXfaTextBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Clone the text box field. mainForm.Fields.Add(TryCast(textBoxField.Clone(), PdfXfaTextBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the caption of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the field type of the text box //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("Address", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "Address"; //Set the text box type. textBoxField.Type = PdfXfaTextBoxType.Multiline; //Set the tool tip. textBoxField.ToolTip = "Address"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("Address", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "Address" 'Set the text box type. textBoxField.Type = PdfXfaTextBoxType.Multiline 'Set the tool tip. textBoxField.ToolTip = "Address" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the padding //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Set padding. textBoxField.Padding.All = 2; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Set padding. textBoxField.Padding.All = 2 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets minimum height of the text box, this will be expandable //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Set minimum height. textBoxField.MinimumHeight = 30; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Set minimum height. textBoxField.MinimumHeight = 30; 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the minimum width of the text box, this will be expandable //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Set minimum width. textBoxField.MinumWidth = 220; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Set minum width. textBoxField.MinimumWidth = 220 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets maximum height of the text box field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Set maxium height. textBoxField.MaximumHeight = 30; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Set maximum height. textBoxField.MaximumHeight = 30; 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets maximum width of the text box field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Set maximum width. textBoxField.MaximumWidth = 300; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Set maximum width. textBoxField.MaximumWidth = 300; 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the value of the text box field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Set text. textBoxField.Text = "John"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Set text. textBoxField.Text = "John" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the character limit //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; //Set maxium length. textBoxField.MaximumLength = 10; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" 'Set maximum length. textBoxField.MaximumLength = 10 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the comb cell //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; textBoxField.Type = PdfXfaTextBoxType.Comb; textBoxField.CombLength = 5; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" textBoxField.Type = PdfXfaTextBoxType.Comb //Set comb length. textBoxField.CombLength = 5 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the password character //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a textbox field and add the properties. PdfXfaTextBoxField textBoxField = new PdfXfaTextBoxField("FirstName", new SizeF(200, 20)); //Set the caption text. textBoxField.Caption.Text = "First Name"; //Set the tool tip. textBoxField.ToolTip = "First Name"; textBoxField.Type = PdfXfaTextBoxType.Password; //Set password character. textBoxField.PasswordCharacter = "*"; //Add the field to the XFA form. mainForm.Fields.Add(textBoxField); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a textbox field and add the properties. Dim textBoxField As New PdfXfaTextBoxField("FirstName", New SizeF(200,20)) 'Set the caption text. textBoxField.Caption.Text = "First Name" 'Set the tool tip. textBoxField.ToolTip = "First Name" textBoxField.Type = PdfXfaTextBoxField.Password //Set password character. textBoxField.PasswordCharacter = "*" 'Add the field to the XFA form. mainForm.Fields.Add(textBoxField) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Represents text field in the XFA form. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement("Hello World!"); //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement("Hello World!") 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. value of the text element //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement("Hello World!"); //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement("Hello World!") 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initialize a new instance of the class. Value of the text element Text element width. Text element height. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement("Hello World!", 200, 20); //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement("Hello World!", 200, 20) 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. value of the text element Font of the text element //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement("Hello World!", new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement("Hello World!", New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold)) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Initializes a new instance of the class. value of the text element Font of the text element //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement("Hello World!", new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold), 200, 20); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement("Hello World!", New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold), 200, 20) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Save the text element. Draw the tex to the PDF document. Get the fields rotation angle. Get the size of the field. Creates a new object that is a copy of the current instance. The copy of the new object for this instance. //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement("Hello World!"); //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Clone the element. mainForm.Fields.Add(textElement.Clone() as PdfXfaTextElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement("Hello World!") 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Clone the element. mainForm.Fields.Add(TryCast(textElement.Clone(), PdfXfaTextElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the Horizontal alignment //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the vertical alignment //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the text //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the rotation angle //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the font //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement("Hello World!"); //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement("Hello World!") 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf",PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets the fore color of the field //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets width of the TextBox //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Gets or sets height of the TextBox //Create a new PDF XFA document. PdfXfaDocument document = new PdfXfaDocument(); //Add a new XFA page. PdfXfaPage xfaPage = document.Pages.Add(); //Create a new PDF XFA form PdfXfaForm mainForm = new PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width); //Create a text element and add the properties. PdfXfaTextElement textElement = new PdfXfaTextElement(); //Set text. textElement.Text = "Hello World!."; //Set width. textElement.Width = 200; //Set height. textElement.Height = 20; //Set fore color. textElement.ForeColor = Color.Yellow; //Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90; //Set font textElement.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Add the text element to the XFA form. mainForm.Fields.Add(textElement); //Add the XFA form to the document. document.XfaForm = mainForm; //Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic); //close the document document.Close(); 'Create a new PDF XFA document. Dim document As New PdfXfaDocument() 'Add a new XFA page. Dim xfaPage As PdfXfaPage = document.Pages.Add() 'Create a new PDF XFA form Dim mainForm As New PdfXfaForm("subform1", xfaPage, xfaPage.GetClientSize().Width) 'Create a text element and add the properties. Dim textElement As New PdfXfaTextElement() 'Set text. textElement.Text = "Hello World!." 'Set width. textElement.Width = 200 'Set height. textElement.Height = 20 'Set fore color. textElement.ForeColor = Color.Yellow 'Set vertical alignment. textElement.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Set horizontal alignment. textElement.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Set the rotatio angle. textElement.Rotate = PdfXfaRotateAngle.RotateAngle90 'Set font textElement.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Add the text element to the XFA form. mainForm.Fields.Add(textElement) 'Add the XFA form to the document. document.XfaForm = mainForm 'Save the document. document.Save("XfaForm.pdf", PdfXfaType.Dynamic) 'close the document document.Close() Writes the XFA document templates Writes the preamble dictionary Start the datasets End element of the datasets Writes the postable dictionary Writes configuration section Writes the XFA UI tag Writes the XFA UI tag Writes the XFA UI tag Writes the XFA UI tag. Writes the XFA field value tag. Write the XFA field value with numeric Writes the XFA field margins Draw the margin write the font info Writes the font information Write the width and height of the fields Write the width and height of the fields Draws the XFA line value Writes the caption of the field Writes the items of fields Writes the items of fields Writes the list of items Writes the toolTip of fields Draw's the fill color of the field Writes the location of the field Write the paragraph alignments Write patterns Draws the edges of the border Draws a field Border Draw the button field fill color and border Draws the edge Draws the corner Drw the color Draws the stroke Draws the fill color Draws the radial brush Draws the linear brush Set rotation presence and readOnly Get the date pattern string. Get the time pattern string. Get the date time pattern string. Get date pattern. Get time pattern. Represents an named destination which goes to a destination in the current document. Internal variable to store named destination's destination. Internal variable to store dictinary. Internal variable to store cross table. Initializes a new instance of the class. The title to be displayed. Initializes a new instance of the class. The dictionary. The cross table. Initializes instance. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Gets or sets the named destination title. A string value which contains the named destination title Gets the dictionary. The dictionary. Gets the cross table. The crossTable. Gets the element. Implements a collection of named destinations in the document. Collection of the named destinations. Internal variable to store dictinary. Cross table of the document; It counts the index of the named destination Array of the named destinations. variable to hold the named destination collection to sort in aplhabetical order. Initializes a new instance of the class. Initializes a new instance of the class. The dictionary. The cross table. Creates and adds a named destination. The new named destination to be added to the collection. PdfNamedDestination //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document named destinations. PdfNamedDestination namedDestination = new PdfNamedDestination("Page 1"); //Set the destination page. namedDestination.Destination = new PdfDestination(page); //Set the destination location. namedDestination.Destination.Location = new PointF(20, 20); //Add the named destination. document.NamedDestinationCollection.Add(namedDestination); //Save and close the PDF document. document.Save("NamedDestination.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document named destinations. Dim namedDestination As PdfNamedDestination = New PdfNamedDestination("Page 1") 'Set the destination page. namedDestination.Destination = New PdfDestination(page) 'Set the destination location. namedDestination.Destination.Location = New PointF(20, 20) 'Add the named destination. document.NamedDestinationCollection.Add(namedDestination) 'Save and close the PDF document. document.Save("NamedDestination.pdf") document.Close(True) Determines whether the specified named destinations presents in the collection. The named destinations. true if the specified named destinations is in the collection; otherwise, false. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document named destinations. PdfNamedDestination namedDestination = new PdfNamedDestination("Page 1"); //Set the destination page. namedDestination.Destination = new PdfDestination(page); //check whether the specified named destination present in the collection document.NamedDestinationCollection.Contains(namedDestination); //Save and close the PDF document. document.Save("NamedDestination.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document named destinations. Dim namedDestination As PdfNamedDestination = New PdfNamedDestination("Page 1") 'Set the destination page. namedDestination.Destination = New PdfDestination(page) 'Set the destination location. namedDestination.Destination.Location = New PointF(20, 20) 'check whether the specified named destination present in the collection Dim isNamedDestinationContained As Boolean = document.NamedDestinationCollection.Contains(namedDestination) 'Save and close the PDF document. document.Save("NamedDestination.pdf") document.Close(True) Remove the specified named destination from the document. The title of the named destination. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get all the named destinations. PdfNamedDestinationCollection namedCollection = loadedDocument.NamedDestinationCollection; //Remove named destination by named destination name. namedCollection.Remove("Page 1"); //Remove named destination by index. namedCollection.RemoveAt(1); //Save and close the document. loadedDocument.Save("NamedDestination.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("input.pdf") 'Get all the named destinations. Dim namedCollection As PdfNamedDestinationCollection = loadedDocument.NamedDestinationCollection 'Remove named destination by named destination name. namedCollection.Remove("Page 1") 'Remove named destination by index. namedCollection.RemoveAt(1) 'Save and close the document. loadedDocument.Save("NamedDestination.pdf") loadedDocument.Close(True) Remove the specified named destination from the document. The title of the named destination. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get all the named destinations. PdfNamedDestinationCollection namedCollection = loadedDocument.NamedDestinationCollection; //Remove named destination by named destination name. namedCollection.Remove("Page 1"); //Remove named destination by index. namedCollection.RemoveAt(1); //Save and close the document. loadedDocument.Save("NamedDestination.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("input.pdf") 'Get all the named destinations. Dim namedCollection As PdfNamedDestinationCollection = loadedDocument.NamedDestinationCollection 'Remove named destination by named destination name. namedCollection.Remove("Page 1") 'Remove named destination by index. namedCollection.RemoveAt(1) 'Save and close the document. loadedDocument.Save("NamedDestination.pdf") loadedDocument.Close(True) Removes all the named destination from the collection. //Load the PDF document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get the Named destinations PdfNamedDestinationCollection namedCollection = loadedDocument.NamedDestinationCollection; //Remove all the named destination form the collection namedCollection.Clear(); //Save and close the PDF document loadedDocument.Save("NamedDestination.pdf"); loadedDocument.Close(true); 'Load the PDF document Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get the Named destination Dim namedCollection As PdfNamedDestinationCollection = loadedDocument.NamedDestinationCollection 'Remove all the named destination form the collection namedCollection.Clear() 'Save and close the document loadedDocument.Save("NamedDestination.pdf") loadedDocument.Close(True) Inserts a new named destination at the specified index. The index. The named destination to be added to the collection.. The new named destination. /// //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Insert a new named destination in the existing named destinations. PdfNamedDestination namedDestination = new PdfNamedDestination("Page 2"); //Set the destination page and location. namedDestination.Destination = new PdfDestination(loadedDocument.Pages[0]); namedDestination.Destination.Location = new PointF(0, 300); //Insert the named destination loadedDocument.NamedDestinationCollection.Insert(1, namedDestination); //Save and close the PDF document. loadedDocument.Save("NamedDestination.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Insert a new named destination in the existing named destinations. Dim namedDestination As PdfNamedDestination = New PdfNamedDestination("Page 2") 'Set the destination page and location. namedDestination.Destination = New PdfDestination(loadedDocument.Pages(0)) namedDestination.Destination.Location = New PointF(0, 300) Insert the named destination loadedDocument.NamedDestinationCollection.Insert(1, namedDestination) 'Save and close the PDF document. loadedDocument.Save("NamedDestination.pdf") loadedDocument.Close(True) Initializes instance. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Rearrange named destination(m_namedDestination) based on its title. Parse and find the named destination collection Create named destination from existing collection Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Gets number of the elements in the collection. The total number of elements in the collection. Gets the at the specified index. the Gets the dictionary. The dictionary. Gets the cross table. Gets the element. Represents which page goes to be visible in the current document Create a PdfPageTemplate instance Create a PdfPageTemplate // Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get the first page of the document PdfPageBase page = loadedDocument.Pages[0]; //Create a page template PdfPageTemplate pageTemplate = new PdfPageTemplate(page); //Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate"; //Sets the PdfPageTemplate is visible pageTemplate.IsVisible = true; //Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the first page of the document Dim page As PdfPageBase = loadedDocument.Pages(0) 'Create a page template Dim pageTemplate As PdfPageTemplate = New PdfPageTemplate(page) 'Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate" 'Sets the PdfPageTemplate is visible pageTemplate.IsVisible = True 'Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Create a PdfPageTemplate // Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get the first page of the document PdfPageBase page = loadedDocument.Pages[0]; //Create a page template PdfPageTemplate pageTemplate = new PdfPageTemplate(page); //Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate"; //Sets the PdfPageTemplate is visible pageTemplate.IsVisible = true; //Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the first page of the document Dim page As PdfPageBase = loadedDocument.Pages(0) 'Create a page template Dim pageTemplate As PdfPageTemplate = New PdfPageTemplate(page) 'Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate" 'Sets the PdfPageTemplate is visible pageTemplate.IsVisible = True 'Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Gets or sets the PdfPageTemplate name // Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get the first page of the document PdfPageBase page = loadedDocument.Pages[0]; //Create a page template PdfPageTemplate pageTemplate = new PdfPageTemplate(page); //Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate"; //Sets the PdfPageTemplate is visible pageTemplate.IsVisible = true; //Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the first page of the document Dim page As PdfPageBase = loadedDocument.Pages(0) 'Create a page template Dim pageTemplate As PdfPageTemplate = New PdfPageTemplate(page) 'Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate" 'Sets the PdfPageTemplate is visible pageTemplate.IsVisible = True 'Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Gets or sets the PdfPageTemplate is visible or not Default Value: true // Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get the first page of the document PdfPageBase page = loadedDocument.Pages[0]; //Create a page template PdfPageTemplate pageTemplate = new PdfPageTemplate(page); //Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate"; //Sets the PdfPageTemplate is visible pageTemplate.IsVisible = true; //Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the first page of the document Dim page As PdfPageBase = loadedDocument.Pages(0) 'Create a page template Dim pageTemplate As PdfPageTemplate = New PdfPageTemplate(page) 'Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate" 'Sets the PdfPageTemplate is visible pageTemplate.IsVisible = True 'Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Gets the PdfPageBase Implements a collection of page template in the document. Collection of the PdfPageTemplate. Internal variable to store dictinary. Initializes a new instance Initializes a new instance Initializes instance Creates and adds a PdfPageTemplate // Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get the first page of the document PdfPageBase page = loadedDocument.Pages[0]; //Create a page template PdfPageTemplate pageTemplate = new PdfPageTemplate(page); //Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate"; //Sets the PdfPageTemplate is visible pageTemplate.IsVisible = true; //Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the first page of the document Dim page As PdfPageBase = loadedDocument.Pages(0) 'Create a page template Dim pageTemplate As PdfPageTemplate = New PdfPageTemplate(page) 'Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate" 'Sets the PdfPageTemplate is visible pageTemplate.IsVisible = True 'Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Determines whether the specified PdfPageTemplate presents in the collection. //Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Total number of elements in the collection int count = loadedDocument.PdfPageTemplates.Count; //Gets the PdfPageTemplate at the specified index. PdfPageTemplate pageTemplate = loadedDocument.PdfPageTemplates[0]; //Determines whether the specified PdfPageTemplate presents in the collection bool contains = loadedDocument.PdfPageTemplates.Contains(pageTemplate); //Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate); //Remove the specified PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.RemoveAt(1); //Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear(); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Total number of elements in the collection Dim count As Integer = loadedDocument.PdfPageTemplates.Count 'Gets the PdfPageTemplate at the specified index. Dim pageTemplate As PdfPageTemplate = loadedDocument.PdfPageTemplates(0) 'Determines whether the specified PdfPageTemplate presents in the collection Dim contains As Boolean = loadedDocument.PdfPageTemplates.Contains(pageTemplate) 'Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.RemoveAt(1) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Remove the specified PdfPageTemplate from the document. //Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Total number of elements in the collection int count = loadedDocument.PdfPageTemplates.Count; //Gets the PdfPageTemplate at the specified index. PdfPageTemplate pageTemplate = loadedDocument.PdfPageTemplates[0]; //Determines whether the specified PdfPageTemplate presents in the collection bool contains = loadedDocument.PdfPageTemplates.Contains(pageTemplate); //Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate); //Remove the specified PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.RemoveAt(1); //Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear(); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Total number of elements in the collection Dim count As Integer = loadedDocument.PdfPageTemplates.Count 'Gets the PdfPageTemplate at the specified index. Dim pageTemplate As PdfPageTemplate = loadedDocument.PdfPageTemplates(0) 'Determines whether the specified PdfPageTemplate presents in the collection Dim contains As Boolean = loadedDocument.PdfPageTemplates.Contains(pageTemplate) 'Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.RemoveAt(1) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Remove the PdfPageTemplate from the document. //Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Total number of elements in the collection int count = loadedDocument.PdfPageTemplates.Count; //Gets the PdfPageTemplate at the specified index. PdfPageTemplate pageTemplate = loadedDocument.PdfPageTemplates[0]; //Determines whether the specified PdfPageTemplate presents in the collection bool contains = loadedDocument.PdfPageTemplates.Contains(pageTemplate); //Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate); //Remove the specified PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.RemoveAt(1); //Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear(); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Total number of elements in the collection Dim count As Integer = loadedDocument.PdfPageTemplates.Count 'Gets the PdfPageTemplate at the specified index. Dim pageTemplate As PdfPageTemplate = loadedDocument.PdfPageTemplates(0) 'Determines whether the specified PdfPageTemplate presents in the collection Dim contains As Boolean = loadedDocument.PdfPageTemplates.Contains(pageTemplate) 'Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.RemoveAt(1) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Removes all the PdfPageTemplate from the collection. //Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Total number of elements in the collection int count = loadedDocument.PdfPageTemplates.Count; //Gets the PdfPageTemplate at the specified index. PdfPageTemplate pageTemplate = loadedDocument.PdfPageTemplates[0]; //Determines whether the specified PdfPageTemplate presents in the collection bool contains = loadedDocument.PdfPageTemplates.Contains(pageTemplate); //Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate); //Remove the specified PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.RemoveAt(1); //Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear(); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Total number of elements in the collection Dim count As Integer = loadedDocument.PdfPageTemplates.Count 'Gets the PdfPageTemplate at the specified index. Dim pageTemplate As PdfPageTemplate = loadedDocument.PdfPageTemplates(0) 'Determines whether the specified PdfPageTemplate presents in the collection Dim contains As Boolean = loadedDocument.PdfPageTemplates.Contains(pageTemplate) 'Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.RemoveAt(1) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Parse and create existing page templates Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Gets the dictionary Gets the crosstable Gets number of the elements in the collection. //Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Total number of elements in the collection int count = loadedDocument.PdfPageTemplates.Count; //Gets the PdfPageTemplate at the specified index. PdfPageTemplate pageTemplate = loadedDocument.PdfPageTemplates[0]; //Determines whether the specified PdfPageTemplate presents in the collection bool contains = loadedDocument.PdfPageTemplates.Contains(pageTemplate); //Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate); //Remove the specified PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.RemoveAt(1); //Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear(); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Total number of elements in the collection Dim count As Integer = loadedDocument.PdfPageTemplates.Count 'Gets the PdfPageTemplate at the specified index. Dim pageTemplate As PdfPageTemplate = loadedDocument.PdfPageTemplates(0) 'Determines whether the specified PdfPageTemplate presents in the collection Dim contains As Boolean = loadedDocument.PdfPageTemplates.Contains(pageTemplate) 'Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.RemoveAt(1) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Gets the PdfPageTemplate at the specified index. //Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Total number of elements in the collection int count = loadedDocument.PdfPageTemplates.Count; //Gets the PdfPageTemplate at the specified index. PdfPageTemplate pageTemplate = loadedDocument.PdfPageTemplates[0]; //Determines whether the specified PdfPageTemplate presents in the collection bool contains = loadedDocument.PdfPageTemplates.Contains(pageTemplate); //Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate); //Remove the specified PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.RemoveAt(1); //Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear(); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Total number of elements in the collection Dim count As Integer = loadedDocument.PdfPageTemplates.Count 'Gets the PdfPageTemplate at the specified index. Dim pageTemplate As PdfPageTemplate = loadedDocument.PdfPageTemplates(0) 'Determines whether the specified PdfPageTemplate presents in the collection Dim contains As Boolean = loadedDocument.PdfPageTemplates.Contains(pageTemplate) 'Remove the PdfPageTemplate from the document. loadedDocument.PdfPageTemplates.Remove(pageTemplate) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.RemoveAt(1) 'Removes all the PdfPageTemplate from the collection. loadedDocument.PdfPageTemplates.Clear() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Gets the element. Implements a colored tiling brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new RectangleF(0, 0, 11, 11)); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New RectangleF(0, 0, 11, 11)) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Provides objects used to fill the interiors of graphical shapes such as rectangles, ellipses, pies, polygons, and paths. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(Color.Red); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. True if the brush was different. Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. Indicates the indexed Color Space. True if the brush was different. Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check True if the brush was different. Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. True if the brush was different. Resets the changes, which were made by the brush. In other words resets the state to the initial one. The stream writer. Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. Creates a new copy of a brush. A new instance of the Brush class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(Color.Red); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Clone the existing brush. PdfBrush brush1 = brush.Clone(); (brush1 as PdfSolidBrush).Color = Color.Green; //Draw circle. graphics.DrawEllipse(brush1, new RectangleF(300, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Clone the existing brush. Dim brush1 As PdfBrush = brush.Clone() TryCast(brush1, PdfSolidBrush).Color = Color.Green 'Draw circle. graphics.DrawEllipse(brush1, New RectangleF(300, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Local variable to store rectanble box. Local variable to store graphics. Local variable to store brush Stream. Local variable to store resources . Local variable to store Stroking. Local variable to store the page. Local variable to store the tile start location. Local variable to store the Matrix. Local variable to identify whether the brush is created from XPS to PDF converter. Initializes a new instance of the class. The boundaries of the smallest brush cell. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new RectangleF(0, 0, 11, 11)); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New RectangleF(0, 0, 11, 11)) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The boundaries of the smallest brush cell. The Current Page Object. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Set document color space doc.ColorSpace = PdfColorSpace.GrayScale; //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new RectangleF(0, 0, 11, 11), page); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Set document color space doc.ColorSpace = PdfColorSpace.GrayScale 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New RectangleF(0, 0, 11, 11), page) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The size of the smallest brush cell. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new SizeF(11, 11)); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New SizeF(11, 11)) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The size of the smallest brush cell. The Current Page Object. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Set document color space doc.ColorSpace = PdfColorSpace.GrayScale; //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new SizeF(11, 11), page); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Set document color space doc.ColorSpace = PdfColorSpace.GrayScale 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New SizeF(11, 11), page) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Sets the obligatory fields. Sets the BBox coordinates. The box. Gets the resources. PDF resource dictionary. Creates a new copy of a brush. A new instance of the Brush class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new RectangleF(0, 0, 11, 11)); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Clone the existing tile brush. PdfTilingBrush cBrush = brush.Clone() as PdfTilingBrush; //Draw rectangle. graphics.DrawRectangle(cBrush, new RectangleF(0, 150, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New RectangleF(0, 0, 11, 11)) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Clone the existing tile brush. Dim cBrush As PdfTilingBrush = TryCast(brush.Clone(), PdfTilingBrush) 'Draw rectangle. graphics.DrawRectangle(cBrush, New RectangleF(0, 150, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. True if the brush was different. currentColorSpace parameter doesn't have any impact on the output result. Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. True if the brush was different. Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. Indicates the indexed Color Space. True if the brush was different. Resets the changes, which were made by the brush. In other words resets the state to the initial one. The stream writer. Location representing the start position of the tiles. Transformation matrix to store the brush matrix. Gets the boundary box of the smallest brush cell. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new RectangleF(0, 0, 11, 11)); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Get the smallest cell bounds. RectangleF smallestCellBounds = brush.Rectangle; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New RectangleF(0, 0, 11, 11)) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Get the smallest cell bounds. Dim smallestCellBounds As RectangleF = brush.Rectangle 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the size of the smallest brush cell. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new RectangleF(0, 0, 11, 11)); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Get the smallest cell size. SizeF smallestCellSize = brush.Size; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New RectangleF(0, 0, 11, 11)) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Get the smallest cell size. Dim smallestCellSize As SizeF = brush.Size 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets Graphics context of the brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF tile brush. PdfTilingBrush brush = new PdfTilingBrush(new RectangleF(0, 0, 11, 11)); //Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 10, 10)); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF tile brush. Dim brush As New PdfTilingBrush(New RectangleF(0, 0, 11, 11)) 'Draw rect inside the tile. brush.Graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 10, 10)) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the resources dictionary. Gets or sets a value indicating whether this is used for stroking operations. true if, the brush is for stroking operations; otherwise, false. This property allows to use tiling brush like a pen to draw lines. Gets the element. Draws the cross brush pattern. The graphics. The pen. Size of the brush. Draws the backward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws the forward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws the horizontal brush pattern. The graphics. The pen. Size of the brush. Draws the vertical pattern. The graphics. The pen. Size of the brush. Draws the downward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws Weave style. Pdf Graphics on which style draws. Pdf pen which draws style. The size of the brush. Draws the upward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws the brick tails for the brick pattern. The graphics. The pen. Size of the brush. Draws the horizontal brick pattern. The graphics. The pen. Size of the brush. Draws a checker board dash pattern. The graphics. The pen. Size of the brush. Size of the cell. Move Glyph ThaiToneMark ThaiGlyphRanges ThaiGlyphRange Gets or Set ThaiShape Do Arabic Script Shaping Split Arabic line into word blocks Check the letter is medial block Shaping Ligature character glyphs Represents the open type font table. Represents the open type glyph substitution table. Represents the lookup table type 2. Represents GPOS lookup table type 4. Represents the GPOS lookup table type 5. Represents GPOS lookup table type 6. Represents the GSUB lookup table type 1. Represents the open type class definition table. Left-to-Right (Non-European or non-Arabic digits). Left-to-Right Embedding Left-to-Right Override Right-to-Left (Hebrew alphabet, and related punctuation). Right-to-Left Arabic Right-to-Left Embedding. Right-to-Left Override Pop Directional Format European Number (European digits, Eastern Arabic-Indic digits). European Number Separator (Plus sign, Minus sign). European Number Terminator (Degree sign, currency symbols). Arabic Number (Arabic-Indic digits, Arabic decimal and thousands separators). Common Number Separator (Colon, Comma, Full Stop, No-Break Space. Nonspacing Mark (Characters with the General_Category values). Boundary Neutral (Default ignorables, non-characters, and control characters, other than those explicitly given other types.) Paragraph Separator (Paragraph separator, appropriate Newline Functions, higher-level protocol paragraph determination). Segment Separator (tab). Whitespace (Space, Figure space, Line separator, Form feed, General Punctuation spaces). Other Neutrals (All other characters, including object replacement character). Specifies the character types. Specifies the text order (RTL or LTR). Specifies the text length. Specifies the resultant types. Specifies the resultant levels. Specifies the RTL character types. RTL character types. Start of image marker. JFIF marker. Start of scan marker. End of image marker. Start of file markers. indicates the colorspace for image Get ColorSpace for JPG/JPEG image Indicates the width of the image. Indicates the height of the image. Indicates the Png image type. Possible values : 0,2,3,4 and 6. Indicates the type of compression. 0 - Zlib Compression Indicates the number of bits per sample or per palette index. Valid values are : 1,2,4,8 and 16. |-----------------------------------------| | ColorType | BitDepth | ImageType | |-----------------------------------------| | 0 | 1,2,4,8,16 | GrayScale | | 2 | 8,16 | TrueColor | | 3 | 1,2,4,8 | Indexed PLTE | | 4 | 8,16 | GrayScaleAlpha | | 6 | 8,16 | TrueColorAlpha | |------------------------------------------ Indicates the preprocessing method applied to the image data before compression. Indicates the transmission order of the image data. Possible values : 0 and 1 Class which represents the html internal link used during the html to Pdf conversion to preserve internal links. This class is used internally and should not be used directly. Maximum header level Internal variable to store the page bottom margin Draw hierarchical bookmarks Gets or sets the URI Gets or sets the URI page number /// Gets or sets the URI bounds. Gets or sets the header tag level from H1 to H6 Gets or sets the id of destination Gets or sets the header content Gets or sets the destination page number Gets or sets the destination page Gets or sets the destination x and y position Gets or sets the TOC x-coordinates with header hierarchy Gets or sets the TOC rectangle height Gets or sets the TOC page count Class which provides method and properties to apply styles in automatic creation of a table of contents items for the H1 to H6 HTML elements To know more about HTML to PDF TOC refer this link. //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Rectangle begin position TOC title begin position Rectangle left padding Rectangle right padding Space between two rectangle Maximum header level Indicating whether it is next page Indicating whether it is first page Indicating whether the tab leader char empty Internal variable to store the page layout result Internal variable to store the pageLayout bottom value. Internal variable to store the page template Holds the list of header style Initializes a new instance of the class. //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set the maximum header level. toc.MaximumHeaderLevel = 5; //Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash; //Set table leader character. toc.TabLeaderChar = 'c'; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set the maximum header level. toc.MaximumHeaderLevel = 5 'Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash 'Set table leader character. toc.TabLeaderChar = "c" 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Calculate number of pages required to draw table of content and each rectangle heights Calculate rectangle height Draw table of content Draw rectangle inner text Draw tab leader Add page navigation Sets the style of a table of contents item on a given level. The item level is a number from 1 to 6 //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set the maximum header level. toc.MaximumHeaderLevel = 5; //Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash; //Set header1 style. toc.SetItemStyle(1, style); //Set header2 style. toc.SetItemStyle(2, style); //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set the maximum header level. toc.MaximumHeaderLevel = 5 'Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash 'Set header1 style. toc.SetItemStyle(1, style) 'Set header2 style. toc.SetItemStyle(2, style) 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the TOC title //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the horizontal title text alignment:By default left //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the TOC style of the table of contents title. When this property is set with a value, the default style of the title is replaced with the style given by this property. //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the tab leader:By default Dot //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set the maximum header level. toc.MaximumHeaderLevel = 5; //Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash; //Set table leader character. toc.TabLeaderChar = 'c'; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set the maximum header level. toc.MaximumHeaderLevel = 5 'Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash 'Set table leader character. toc.TabLeaderChar = "c" 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the tab leader character to connect the chapter titles and section headings to their corresponding page numbers //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set the maximum header level. toc.MaximumHeaderLevel = 5; //Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash; //Set table leader character. toc.TabLeaderChar = 'c'; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set the maximum header level. toc.MaximumHeaderLevel = 5 'Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash 'Set table leader character. toc.TabLeaderChar = "c" 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the maximum header level (H1 to H6) :By default 6 //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set the maximum header level. toc.MaximumHeaderLevel = 5; //Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash; //Set table leader character. toc.TabLeaderChar = 'c'; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set the maximum header level. toc.MaximumHeaderLevel = 5 'Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash 'Set table leader character. toc.TabLeaderChar = "c" 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the starting page number for table of contents in HTML to PDF conversion. //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Going to insert two pages before TOC, so added the offset value as 2 settings.Toc.StartingPageNumber = 2; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True //Going to insert two pages before TOC, so added the offset value as 2 settings.Toc.StartingPageNumber = 2; 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the header style Gets or sets TOC page count The type defines the tab leader list to connect the chapter titles and section headings to their corresponding page numbers //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set the maximum header level. toc.MaximumHeaderLevel = 5; //Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash; //Set table leader character. toc.TabLeaderChar = 'c'; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set the maximum header level. toc.MaximumHeaderLevel = 5 'Set tab leader style. toc.TabLeader = HtmlToPdfToc.TabLeaderStyle.Dash 'Set table leader character. toc.TabLeaderChar = "c" 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Don't apply tab leader Connect the chapter titles and section headings to their corresponding page number with dotted line Connect the chapter titles and section headings to their corresponding page number with dashed line Connect the chapter titles and section headings to their corresponding page numbers with solid line This class contains the necessary properties to apply style in the automatic creation of a table of contents in a PDF document. //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the back ground color //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the font //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the fore color //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Gets or sets the padding //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"/QtBinaries/"; //Enable toc. settings.EnableToc = true; //Create a new instance for HTML to PDF toc. HtmlToPdfToc toc = new HtmlToPdfToc(); //Set title. toc.Title = "HTML to PDF"; //Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center; //Create new HTML to PDF Toc Style. HtmlToPdfTocStyle style = new HtmlToPdfTocStyle(); //Set background color. style.BackgroundColor = new PdfSolidBrush(Color.LightCyan); //Set font. style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set fore color. style.ForeColor = new PdfSolidBrush(Color.Red); //Set paddings. style.Padding = new PdfPaddings(5, 5, 5, 5); //Set toc style. toc.TitleStyle = style; //Set toc to webkit settings. settings.Toc = toc; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "/QtBinaries/" 'Enable toc. settings.EnableToc = True 'Create a new instance for HTML to PDF toc. Dim toc As New HtmlToPdfToc() 'Set title. toc.Title = "HTML to PDF" 'Set title alignment. toc.TitleAlignment = PdfTextAlignment.Center 'Create new HTML to PDF Toc Style. Dim style As New HtmlToPdfTocStyle() 'Set background color. style.BackgroundColor = New PdfSolidBrush(Color.LightCyan) 'Set font. style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set fore color. style.ForeColor = New PdfSolidBrush(Color.Red) 'Set paddings. style.Padding = New PdfPaddings(5, 5, 5, 5) 'Set toc style. toc.TitleStyle = style 'Set toc to webkit settings. settings.Toc = toc 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) The class provides methods and properties to handle the loaded annotations from the existing PDF document for Fdf export and import. Initializes a new instance of the class. Fdf stream. Imports the annotation data from FDF stream PDF loaded document Parse annotation data Dispose the objects and collections Gets or sets the PDF reader. Gets or sets the PDF parser. Gets or sets the Fdf object collection. Gets the grouped object references The class provides fields and properties to handle objects in Fdf stream. Initializes a new instance of the class. Object number. Generation number. Fdf object. Initializes a new instance of the class. Fdf object. Gets the object number of the current FDF object. Object number Gets the generation number of the current FDF object. Generation number Gets the current FDF object. Primitive object Gets the trailer object in FDF stream. Primitive object The class provides collection of FDF objects. Initializes a new instance of the class. Add a new object into collection Dispose the collection Gets and sets the FDF object. Collection of object number and FDF objects The class provides methods and properties to handle the collection of for exporting. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Get the second page from the document page = document.Pages[1] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Get the second page from the document page = TryCast(document.Pages(1), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection) 'Close and dispose the document document.Close(true) document.Dispose() Initializes a new instance of the class. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection) 'Close and dispose the document document.Close(true) document.Dispose() Adds annotation to the collection. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Get the second page from the document page = document.Pages[1] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Get the second page from the document page = TryCast(document.Pages(1), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection) 'Close and dispose the document document.Close(true) document.Dispose() Gets the at the specified index. Returns the annotation at the specified index //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Gets the annotation at the specified index PdfLoadedAnnotation annotation = collection[1]; //Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Gets the annotation at the specified index Dim annotation As PdfLoadedAnnotation = collection[1] 'Export selected annotation's data into FDF format document.ExportAnnotations("Annotations.Fdf", AnnotationDataFormat.Fdf, "Annotations.Pdf", collection) 'Close and dispose the document document.Close(true) document.Dispose() Represents the PdfLoadedRedactionAnnotation. // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Represents the PdfLoadedStyledAnnotation class //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Sets the annotation flags attchmentAnnotation.AnnotationFlags=PdfAnnotationFlags.Default; //Sets the file name. fileLinkAnnotation.FileName = @"..\..\Data\Manual.txt"; // Set the file link annotation border. fileLinkAnnotation.Border=new PdfAnnotationBorder(4, 0, 0); //Set the file link annotation color. fileLinkAnnotation.Color=new PdfColor(Color.Blue); //Sets the file link annotation text. fileLinkAnnotation.Text = "File Link Annotation"; //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the annotation flags attchmentAnnotation.AnnotationFlags=PdfAnnotationFlags.Default 'Sets the file name. fileLinkAnnotation.FileName = @"..\..\Data\Manual.txt" ' Set the file link annotation border. fileLinkAnnotation.Border=New PdfAnnotationBorder(4, 0, 0) 'Set the file link annotation color. fileLinkAnnotation.Color=New PdfColor(Color.Blue) 'Sets the file link annotation text. fileLinkAnnotation.Text = "File Link Annotation" 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) The class provides methods and properties to handle the loaded annotations from the existing PDF document. Please refer UG documentation link for from this link //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Get the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Get the page. PdfLoadedPage page =soundAnnotation.Page; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Gets the page. Dim page As PdfLoadedPage=soundAnnotation.Page 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Class Class Class Represents the Form field identifier Cross Table. Indicates was field changed or not. Represents index used to default annotation. Represents the Annotation identifier It represents the loaded Popup annotation Initializes a new instance of the class. The dictionary. The cross table. Sets the name of the annotation New name of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Sets the annotation text. soundAnnotation.SetText("Sound Annotation"); //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Sets the annotation text. soundAnnotation.SetText("Sound Annotation") 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Gets the values associated with the specified key. Set the values associated with the specified key. PdfLoadedDocument ldoc = new PdfLoadedDocument("WF_48044_Annotation.pdf"); PdfLoadedPage lpage = ldoc.Pages[0] as PdfLoadedPage; PdfLoadedAnnotationCollection annots = lpage.Annotations; PdfLoadedCircleAnnotation Icircle = annots[64] as PdfLoadedCircleAnnotation; //Get the author string author = Icircle.Author; PdfLoadedPopupAnnotationCollection collection = Icircle.ReviewHistory; PdfLoadedPopupAnnotationCollection collectionComments = Icircle.Comments; PdfLoadedPopupAnnotation annotation = collection[1] as PdfLoadedPopupAnnotation; //Set Unknown state and model annotation.SetValues("State", "StateModel"); annotation.SetValues("StateModel", "CustomState"); ldoc.Save("result.pdf"); Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("WF_48044_Annotation.pdf") Dim lpage As PdfLoadedPage = CType(ldoc.Pages(0), PdfLoadedPage) Dim annots As PdfLoadedAnnotationCollection = lpage.Annotations Dim Icircle As PdfLoadedCircleAnnotation = CType(annots(64), PdfLoadedCircleAnnotation) Dim author As String = Icircle.Author Dim collection As PdfLoadedPopupAnnotationCollection = Icircle.ReviewHistory Dim collectionComments As PdfLoadedPopupAnnotationCollection = Icircle.Comments Dim annotation As PdfLoadedPopupAnnotation = CType(collection(1), PdfLoadedPopupAnnotation) 'Set Unknown state and model annotation.SetValues("State", "StateModel") annotation.SetValues("StateModel", "CustomState") ldoc.Save("result.pdf") Searches the in parents. The dictionary. The cross table. The value. Searched primitive. Gets the value. The dictionary. The cross table. The value. if it is inheritable, set to true. The founded value. Gets the widget annotation. The dictionary. The cross table. The widget annotation dictionary. Aplies field name specified field name Begins the save. Exports the form fields. Stream. Object identifier. Exports the annotation data. Stream. Current identifier. Annotation identifier. Current page index. Indicates exporting of appearance stream or not. Validates whether annotation is Popup or not and supported Popup Raises when user manualy chages the name of the field. Gets or sets the changed. Gets or sets the cross table. Gets or Sets Loaded Popup Annotation Gets and sets the where the annotation is present. The of the existing PDF document //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Get the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Get the page. PdfLoadedPage page =soundAnnotation.Page; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Gets the page. Dim page As PdfLoadedPage=soundAnnotation.Page 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Gets loadedannotation is Popup or not NameChanged event handler. New name of the field. Gets the Annotation state. The state. Gets the Annotation state model. The state model. Gets the text. The text. Gets the Author. The Author. Gets the Subject. The Subject. Gets the ModifiedDate. The ModifiedDate. Gets the creation date. The creation date. Gets the bounds. The dictionary. The cross table. The bounds. Gets the border. The border. Gets the color. The color. Gets the Opacity. The Opacity. Gets the number value. Name of the key. The value of the number specified by the string key. Get the inner line color Gets the annotation flags. The annotation flags. Draw CloudStye to the Shapes Obtain annotation need flatten Flatten annotation template Obtain layer graphics Validate template matrix have any transformation Get the border dtyle The Line border style get the Line style The line Style Initializes a new instance of the class. The dictionary. The cross table. Flatten the popup window Parse the XML string to get the required styles Convert the HTML string to Color Get the popup bounds returns the popup window bounds Remove both the annotation and popup window current page. annotation to be removed. Gets or sets the color. The color. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Set the file link annotation color. fileLinkAnnotation.Color=new PdfColor(Color.Blue); //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Set the file link annotation color. fileLinkAnnotation.Color=New PdfColor(Color.Blue) 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Gets or sets the Opacity of the annotation, Default value is 1.0f Gets or sets the inner color of the annotation, Default color is transparent Gets or sets the text. The text. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Sets the file link annotation text. fileLinkAnnotation.Text = "File Link Annotation"; //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the file link annotation text. fileLinkAnnotation.Text = "File Link Annotation" 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Gets or Sets the Author of the annotation. Gets or Sets the Subject of the annotation. Gets or Sets the ModifiedDate of the annotation. Gets the creation date of the annotation. Gets or sets the name of the annotation. Gets or sets the annotation's bounds. If this property is not set, bounds are calculated automatically based on Location property and content of annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; 'Sets the file link annotation bounds. fileLinkAnnotation.Bounds = new RectangleF(100,100,50,50); //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the file link annotation bounds. fileLinkAnnotation.Bounds = New RectangleF(100,100,50,50) 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Gets or sets the annotation's border. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Sets the annotation flags attchmentAnnotation.AnnotationFlags=PdfAnnotationFlags.Default; // Set the file link annotation border. fileLinkAnnotation.Border=new PdfAnnotationBorder(4, 0, 0); //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation ' Set the file link annotation border. fileLinkAnnotation.Border=New PdfAnnotationBorder(4, 0, 0) 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Gets or sets the location. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Sets the file link Annotation location. fileLinkAnnotation.Location new PointF(100,100); //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the file link Annotation location fileLinkAnnotation.Location =New PointF(100,100) 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Gets or sets the size. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Sets the size attchmentAnnotation.Size=new SizeF(100,50) //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the size attchmentAnnotation.Size=New SizeF(100,50) 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Gets or sets the annotation flags. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Sets the annotation flags attchmentAnnotation.AnnotationFlags=PdfAnnotationFlags.Default; //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the annotation flags attchmentAnnotation.AnnotationFlags=PdfAnnotationFlags.Default 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Get whether border is present or not. Used to represent the border color of the redaction annotation. Used to represent the border of the redaction annotation. Used to represent overlaytext of the redaction annotation. Used to represent the text color of the redaction annotation. Used to represent the text repeat of the redaction annotation. Used to represent the font of the redaction annotation. Used to represent the textalignment of the redaction annotation. Crosstable Initializes a new instance of the class. The dictionary. The cross table. Saves an annotation. Applyredaction to loadedpage Gets the textcolor of redaction annotation Get the repeat text of redaction annotation Get the bordercolor of redaction annotation Get the textcolor of redaction annotation Get textAlignment of redaction annotation Get font of redaction annotation Obtain the font from appearence stream. Get or set the textcolor of redaction annotation // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Get or set the text alignment of redaction annotation /// // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Get or set the border of redaction annotation /// // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Get or set the overlaytext of redaction annotation /// // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Get or set the font of redaction annotation /// // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Get or set the bordercolor of redaction annotation /// // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Get or set repeat text of redaction annotation /// // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// Get or set the flatten /// // PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLoadedRedactionAnnotation //PdfLoadedRedactionAnnotation annot = document.Pages[0].Annotations[0] as PdfLoadedRedactionAnnotation; //Get the line ending style // annot.Bounds = new Rectangle(100, 120, 100, 100); //set the innercolor //annot.InnerColor = Color.Aqua; //set the bordercolor // annot.BorderColor = Color.Orange; //set the textcolor // annot.TextColor = Color.Yellow; //set the font //annot.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); //set overlaytext //annot.OverlayText = "Redact"; //set textalignment //annot.TextAlignment = PdfTextAlignment.Right; // annot.Repeat = true; //annot.Flatten=true //Saves the document to disk. //document.Save("redact.pdf"); //document.Close(true); // System.Diagnostics.Process.Start("empty.pdf"); //Dim document As PdfLoadedDocument = New PdfLoadedDocument("..\..\Annotations.pdf") //Dim annot As PdfLoadedRedactionAnnotation = TryCast(document.Pages(0).Annotations(0), PdfLoadedRedactionAnnotation) //set the bounds //annot.Bounds = New Rectangle(100, 120, 100, 100) //set the innercolor //annot.InnerColor = Color.Aqua //set the bordercolor //annot.BorderColor = Color.Orange //set the textcolor // annot.TextColor = Color.Yellow //set the font // annot.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 10) //set overlaytext // annot.OverlayText = "Redact" //set the textalignment //annot.TextAlignment = PdfTextAlignment.Right //annot.Repeat = True //annot.Flatten=true; //document.Save("redact.pdf") //document.Close(True) //System.Diagnostics.Process.Start("empty.pdf") /// The class provides methods and properties to handle the loaded annotations from the existing PDF document for Xfdf export and import. Initializes a new instance of the class. Json Stream. The PdfLoadedDocument. Imports the annotation data from Json stream Json stream Represents the PDF annotation states. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = free.ReviewHistory; foreach (PdfLoadedPopupAnnotation popup in reviewCollection){ //Gets the annotation state PdfAnnotationState state = popup.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popup.AnnotationStateModel; } //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = free.ReviewHistory For Each popup As PdfLoadedPopupAnnotation In reviewCollection 'Get the annotation state Dim state As PdfAnnotationState = popup.AnnotationState 'Get the annotation state model Dim model As PdfAnnotationStateModel = popup.AnnotationStateModel Next 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) The user has indicated nothing about the change (the default). The user agrees with the change. The user disagrees with the change. The change has been cancelled. The change has been completed. The annotation has been marked by the user. The annotation has not been marked by the user (the default). The annotation review status is Unknow. Represents the PDF annotation state models. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = free.ReviewHistory; foreach (PdfLoadedPopupAnnotation popup in reviewCollection){ //Gets the annotation state PdfAnnotationState state = popup.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popup.AnnotationStateModel; } //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = free.ReviewHistory For Each popup As PdfLoadedPopupAnnotation In reviewCollection 'Get the annotation state Dim state As PdfAnnotationState = popup.AnnotationState 'Get the annotation state model Dim model As PdfAnnotationStateModel = popup.AnnotationStateModel Next 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) default. The annotation has been marked by the user. The annotation has been reviewed by the user. Represents the loaded Circle annotation class. Cross Table Indicates the line border. Indicates the dasharry for annotation Indicates dash array reset Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets line border of the annotation. The line border. Gets border style of the annotation. border style The border style. Saves an annotation. Saves an annotation. Flatten annotation for appearance Create appearance for annotation Draw appearance for annotation Obtain Style for circle annotation Draw bezier curve for annotation Calculate bezier points Obtain Midpoint for annotation Get or set the border style of the annotation. Gets the annotation review history. The review collection of the circle annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfCircleAnnotation PdfLoadedCircleAnnotation circle = document.Pages[0].Annotations[0] as PdfLoadedCircleAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = circle.ReviewHistory; //save the document document.Save("CircleAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfLoadedCircleAnnotation Dim circle As PdfLoadedCircleAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = circle.ReviewHistory Next 'save the document document.Save("CircleAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation comments history. The Comments collection of the circle annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfCircleAnnotation PdfLoadedCircleAnnotation circle = document.Pages[0].Annotations[0] as PdfLoadedCircleAnnotation; //Get the comments collection PdfLoadedPopupAnnotationCollection commentsCollection = circle.Comments; //save the document document.Save("CircleAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfLoadedCircleAnnotation Dim circle As PdfLoadedCircleAnnotation = document.Pages(0).Annotations(0) 'Get the Comment collection Dim commentsCollection As PdfLoadedPopupAnnotationCollection = circle.Comments Next 'save the document document.Save("CircleAnnotation.pdf") 'Close the document. document.Close(True) Class Class Cross Table Indicates the line border. Indicates the dasharry for annotation Indicates dash array reset Used to represent the border effect style of the square annotation. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets line border of the annotation. The line border. Saves an annotation. Flatten Annotation Create appearance for annotation Draw appearance for annotation Obtain style from annotation Gets the annotation review history. The review collection of square annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfSquareAnnotation PdfLoadedSquareAnnotation square = document.Pages[0].Annotations[0] as PdfLoadedSquareAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = square.ReviewHistory; //save the document document.Save("PdfSquareAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfSquareAnnotation Dim square As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = square.ReviewHistory 'save the document document.Save("PdfSquareAnnotation.pdf") 'Close the document. document.Close(True) Class Class Get or set the border effect of the square annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing pdf square annotation PdfLoadedSquareAnnotation square = document.Pages[0].Annotations[0] as PdfLoadedSquareAnnotation; //Get and Set the border effect of the annotation PdfBoderEffect borderEffect = square.BoderEffect; //save the document document.Save("PdfSquareAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing pdf square annotation Dim square As PdfLoadedSquareAnnotation = document.Pages(0).Annotations(0) 'Get and Set the border effect of the annotation Dim borderEffect As PdfBoderEffect = square.document 'save the document document.Save("PdfSquareAnnotation.pdf") 'Close the document. document.Close(True) Gets the annotation Comments history. The Comments collection of square annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfSquareAnnotation PdfLoadedSquareAnnotation square = document.Pages[0].Annotations[0] as PdfLoadedSquareAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = square.Comments; //save the document document.Save("PdfSquareAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfSquareAnnotation Dim square As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = square.Comments 'save the document document.Save("PdfSquareAnnotation.pdf") 'Close the document. document.Close(True) Class Class Get or set the border of the square annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing pdf square annotation PdfLoadedSquareAnnotation square = document.Pages[0].Annotations[0] as PdfLoadedSquareAnnotation; //Set the border of the annotation LineBorder border = new LineBorder(); border.BorderStyle = PdfBorderStyle.Beveled; //save the document document.Save("PdfSquareAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing pdf square annotation Dim square As PdfLoadedSquareAnnotation = document.Pages(0).Annotations(0) 'Set the border of the annotation Dim border As New LineBorder() border.BorderStyle = PdfBorderStyle.Beveled; 'save the document document.Save("PdfSquareAnnotation.pdf") 'Close the document. document.Close(True) Cross Table Indicates the line border. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets line border of the annotation. The line border. Gets border style of the annotation. border style The border style. Saves an annotation. Flatten annotation appearance Create appearance for annotation Draw appearance for annotation Obtain Style for annotation Create bezier curve calculate bezier points Obtain Midpoints Gets the annotation review history. The review collection of the Ellipse annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfEllipseAnnotation PdfLoadedEllipseAnnotation ellipse = document.Pages[0].Annotations[0] as PdfLoadedEllipseAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = ellipse.ReviewHistory; //save the document document.Save("EllipseAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfEllipseAnnotation Dim ellipse As PdfLoadedEllipseAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = ellipse.ReviewHistory Next 'save the document document.Save("EllipseAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the Ellipse annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfEllipseAnnotation PdfLoadedEllipseAnnotation ellipse = document.Pages[0].Annotations[0] as PdfLoadedEllipseAnnotation; //Get the comments collection PdfLoadedPopupAnnotationCollection reviewCollection = ellipse.Comments; //save the document document.Save("EllipseAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfEllipseAnnotation Dim ellipse As PdfLoadedEllipseAnnotation = document.Pages(0).Annotations(0) 'Get the comments collection Dim commentsCollection As PdfLoadedPopupAnnotationCollection = ellipse.Comments Next 'save the document document.Save("EllipseAnnotation.pdf") 'Close the document. document.Close(True) Class Class Get or set the line border of the annotation. Represents the Polygon annotation Cross Table Indicates the line border. Used to represent the border effect style of the polygon annotation. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets line border of the annotation. The line border. Gets border style of the annotation. border style The border style. Gets line points of the annotation. line points. Saves an annotation. Saves an annotation. Gets the annotation review history. The review collection of the polygon annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfPolygonAnnotation PdfLoadedPolygonAnnotation polygon = document.Pages[0].Annotations[0] as PdfLoadedPolygonAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = polygon.ReviewHistory; //save the document document.Save("PdfPolygonAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfPolygonAnnotation Dim polygon As PdfLoadedPolygonAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = polygon.ReviewHistory 'save the document document.Save("PdfPolygonAnnotation.pdf") 'Close the document. document.Close(True) Class Class Get or set the border effect of the polygon annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing pdf polygon annotation PdfLoadedPolygonAnnotation polygon = document.Pages[0].Annotations[0] as PdfLoadedPolygonAnnotation; //Get and set the border effect of the annotation PdfBoderEffect borderEffect = polygon.BoderEffect; //save the document document.Save("PdfPolygonAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfPolygonAnnotation Dim polygon As PdfLoadedPolygonAnnotation = document.Pages(0).Annotations(0) 'Get and set the border effect of the annotation Dim borderEffect As PdfBoderEffect = polygon.BorderEffect 'save the document document.Save("PdfPolygonAnnotation.pdf") 'Close the document. document.Close(True) Gets the annotation comments history. The comments collection of the polygon annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfPolygonAnnotation PdfLoadedPolygonAnnotation polygon = document.Pages[0].Annotations[0] as PdfLoadedPolygonAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection reviewCollection = polygon.Comments; //save the document document.Save("PdfPolygonAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfPolygonAnnotation Dim polygon As PdfLoadedPolygonAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = polygon.Comments 'save the document document.Save("PdfPolygonAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the line border of the annotation. Gets the polygon points of the annotation. Represents the PolyLine annotation Cross Table Indicates the line border. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets line style of the annotation. choice The line style. Gets line style of the annotation. Type of line style The line style. Gets line style of the annotation. The line style. Gets line points of the annotation. line points. Gets back color of the annotation. The back color. Gets line border of the annotation. The line border. Gets border style of the annotation. border style The border style. Saves an annotation. Gets the annotation review history. The review collection of the polyline annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfPolyLineAnnotation PdfLoadedPolyLineAnnotation polyline = document.Pages[0].Annotations[0] as PdfLoadedPolyLineAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = polyline.ReviewHistory; //save the document document.Save("PdfPolyLineAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfPolyLineAnnotation Dim polyline As PdfLoadedPolyLineAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = polyline.ReviewHistory 'save the document document.Save("PdfPolyLineAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the polyline annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfPolyLineAnnotation PdfLoadedPolyLineAnnotation polyline = document.Pages[0].Annotations[0] as PdfLoadedPolyLineAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = polyline.Comments; //save the document document.Save("PdfPolyLineAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfPolyLineAnnotation Dim polyline As PdfLoadedPolyLineAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = polyline.Comments 'save the document document.Save("PdfPolyLineAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the polyline points of the annotation. Gets the line border of the annotation. Gets or sets the begin line style of the annotation. Gets or sets the end line style of the annotation. Cross Table Indicates the line border. Indicates the dasharry for annotation Indicates dash array reset Used to represent the border Effect style of the Rectangle annotation. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets line border of the annotation. The line border. Gets border style of the annotation. border style The border style. Saves an annotation. Flatten annotation Create appearance for annotation Draw appearance for annotation Obtain style from annotation Gets or sets the changed. Gets the annotation review history. The review collection of the rectangle annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfRectangleAnnotation PdfLoadedRectangleAnnotation rectangle = document.Pages[0].Annotations[0] as PdfLoadedRectangleAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = rectangle.ReviewHistory; //save the document document.Save("PdfRectangleAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfRectangleAnnotation Dim rectangle As PdfLoadedRectangleAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = rectangle.ReviewHistory 'save the document document.Save("PdfRectangleAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the rectangle annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfRectangleAnnotation PdfLoadedRectangleAnnotation rectangle = document.Pages[0].Annotations[0] as PdfLoadedRectangleAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = rectangle.Comments; //save the document document.Save("PdfRectangleAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfRectangleAnnotation Dim rectangle As PdfLoadedRectangleAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = rectangle.Comments 'save the document document.Save("PdfRectangleAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the line border of the annotation. Get or set the border effect of the rectangle annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing pdf rectangle annotation PdfLoadedRectangleAnnotation rectangle = document.Pages[0].Annotations[0] as PdfLoadedRectangleAnnotation; //Get and set the border effect of the annotation PdfBoderEffect borderEffect = rectangle.BoderEffect; //save the document document.Save("PdfRectangleAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing pdf rectangle annotation Dim rectangle As PdfLoadedRectangleAnnotation = document.Pages(0).Annotations(0) 'Get and set the border effect of the annotation Dim borderEffect As PdfBoderEffect = rectangle.BorderEffect 'save the document document.Save("PdfRectangleAnnotation.pdf") 'Close the document. document.Close(True) Represents the text markup annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and PDF font style . Font font = new Font("Calibri", 10, FontStyle.Bold); PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Create a new pdf brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); //Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a pdf text markup annotation . PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, new PointF(175, 40), pdfFont); markupAnnotation.TextMarkupColor = new PdfColor(Color.BlueViolet); markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; //Add this annotation to a new page. page.Annotations.Add(markupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create pdf font and pdf font style . Dim font As New Font("Calibri", 10, FontStyle.Bold) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Create a new PDF brush. Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) 'Create a pdf text markup annotation . Dim markupAnnotation As New PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, New PointF(175, 40), pdfFont) markupAnnotation.TextMarkupColor = New PdfColor(Color.BlueViolet) markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight 'Add this annotation to a new page. page.Annotations.Add(markupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class To specifying the TextMarkupAnnotationType . To specifying the QuadPoints . To store the QuadPoints to the PdfArray To specifying the Text Markup Color . To specifying the Text Markup Annotation Title . To specifying the Text Size . To specifying the Text Location . To specifying the Text Font. To indicate collection of rectagle bounds of annotation Indicate the border Dictionary Indicat the border style Initializes new instance of class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and font style . Font font = new Font("Calibri", 10, FontStyle.Bold); PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Create a new PDF brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a pdf text markup annotation . PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation(); markupAnnotation.Text = "Text Markup annotation"; markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; //Add this annotation to a new page. page.Annotations.Add(markupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create pdf font and font style . Dim font As New Font("Calibri", 10, FontStyle.Bold) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Create a new PDF brush. Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) 'Create a pdf text markup annotation . Dim markupAnnotation As New PdfTextMarkupAnnotation() markupAnnotation.Text = "Text Markup annotation" markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight 'Add this annotation to a new page. page.Annotations.Add(markupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes new instance of class with specified title, markup text, annotation text and font. The markup annotation title. The string specifies the text of the annotation. The string specifies the markup text of the annotation. The location of the markup text annotation. The specifies the text appearance of the markup text annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and font style . Font font = new Font("Calibri", 10, FontStyle.Bold); PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Create a new PDF brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); //Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a pdf text markup annotation. PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, new PointF(175, 40), pdfFont); markupAnnotation.TextMarkupColor = new PdfColor(Color.BlueViolet); markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; //Add this annotation to a new page. page.Annotations.Add(markupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create PDF font and font style . Dim font As New Font("Calibri", 10, FontStyle.Bold) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Create a new PDF brush. Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) 'Create a pdf text markup annotation. Dim markupAnnotation As New PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, New PointF(175, 40), pdfFont) markupAnnotation.TextMarkupColor = New PdfColor(Color.BlueViolet) markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight 'Add this annotation to a new page. page.Annotations.Add(markupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes new instance of class with specified bounds. The bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and font style . PdfFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Create a new PDF brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a pdf text markup annotation . PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation(rectangle); markupAnnotation.TextMarkupColor = new PdfColor(Color.BlueViolet); markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; //Add this annotation to a new page. page.Annotations.Add(markupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create pdffont and pdffont style . Dim pdfFont As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Create a new pdfbrush . Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) 'Create a pdf text markup annotation . Dim markupAnnotation As New PdfTextMarkupAnnotation(rectangle) markupAnnotation.TextMarkupColor = New PdfColor(Color.BlueViolet) markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight 'Add this annotation to a new page. page.Annotations.Add(markupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes Annotation object. Saves an Text Markup Annotation . Save Text markup required dictionary Flatten annotation Darw Squiggly line Create appearance for text markup Set Quadpoints for text markup Gets or sets TextMarkupAnnotationType. The enumeration value which contains the different types of mark up annotation types. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and font style . Font font = new Font("Calibri", 10, FontStyle.Bold); PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Create a new PDF brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); //Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a PDF text markup annotation . PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, new PointF(175, 40), pdfFont); markupAnnotation.TextMarkupColor = new PdfColor(Color.BlueViolet); markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; //Add this annotation to a new page. page.Annotations.Add(markupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create pdf font and pdf font style . Dim font As New Font("Calibri", 10, FontStyle.Bold) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Create a new PdfBrush. Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) 'Create a pdf text markup annotation . Dim markupAnnotation As New PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, New PointF(175, 40), pdfFont) markupAnnotation.TextMarkupColor = New PdfColor(Color.BlueViolet) markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight 'Add this annotation to a new page. page.Annotations.Add(markupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets the annotation reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and PDF font style . Font font = new Font("Calibri", 10, FontStyle.Bold); PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Create a new pdf brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); //Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a pdf text markup annotation . PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, new PointF(175, 40), pdfFont); markupAnnotation.TextMarkupColor = new PdfColor(Color.BlueViolet); markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; // set review state PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; markupAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = markupAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim font As Font = New Font("Calibri", 10, FontStyle.Bold) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, false) Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As RectangleF = New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) Dim markupAnnotation As PdfTextMarkupAnnotation = New PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, New PointF(175, 40), pdfFont) markupAnnotation.TextMarkupColor = New PdfColor(Color.BlueViolet) markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" markupAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = markupAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create PDF font and PDF font style . Font font = new Font("Calibri", 10, FontStyle.Bold); PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Create a new pdf brush. PdfBrush pdfBrush = new PdfSolidBrush(Color.Black); //Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, new PointF(150, 10)); string markupText = "Text Markup"; SizeF size = pdfFont.MeasureString(markupText); RectangleF rectangle = new RectangleF(175, 40, size.Width, size.Height); page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle); //Create a pdf text markup annotation . PdfTextMarkupAnnotation markupAnnotation = new PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, new PointF(175, 40), pdfFont); markupAnnotation.TextMarkupColor = new PdfColor(Color.BlueViolet); markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; markupAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = markupAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim font As Font = New Font("Calibri", 10, FontStyle.Bold) Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, false) Dim pdfBrush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draw text in the new page. page.Graphics.DrawString("Text Markup Annotation Demo", pdfFont, pdfBrush, New PointF(150, 10)) Dim markupText As String = "Text Markup" Dim size As SizeF = pdfFont.MeasureString(markupText) Dim rectangle As RectangleF = New RectangleF(175, 40, size.Width, size.Height) page.Graphics.DrawString(markupText, pdfFont, pdfBrush, rectangle) Dim markupAnnotation As PdfTextMarkupAnnotation = New PdfTextMarkupAnnotation("Markup annotation", "Markup annotation with highlight style", markupText, New PointF(175, 40), pdfFont) markupAnnotation.TextMarkupColor = New PdfColor(Color.BlueViolet) markupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" markupAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = markupAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Represents the class for text web link annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); //Set the font float fontSize = 10f; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Create a text web link annotation PdfTextWebLink webLinkAnnotation = new PdfTextWebLink(); webLinkAnnotation.Url = "http://www.yahoo.com"; webLinkAnnotation.Text = "Yahoo Mail"; webLinkAnnotation.Brush = brush; webLinkAnnotation.Font = font; webLinkAnnotation.Pen = PdfPens.Brown; webLinkAnnotation.DrawTextWebLink(page, new PointF(50, 40)); page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, new PointF(110, 40)); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Set the font Dim fontSize As Single = 10f Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Create a text web link annotation Dim webLinkAnnotation As New PdfTextWebLink() webLinkAnnotation.Url = "http://www.yahoo.com" webLinkAnnotation.Text = "Yahoo Mail" webLinkAnnotation.Brush = brush webLinkAnnotation.Font = font webLinkAnnotation.Pen = PdfPens.Brown webLinkAnnotation.DrawTextWebLink(page, New PointF(50, 40)) page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, New PointF(110, 40)) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Represents the text area with the ability to span several pages and inherited from the class //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfBrushes.Black); //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfBrushes.Black) 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Represents the base class for all elements that can be layout on the pages. [System.Security.Permissions.PermissionSet(System.Security.Permissions.SecurityAction.Assert, Name = "FullTrust")] //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Represents a base class for all the page graphics elements. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. Draws an element on the Graphics. Graphics context where the element should be printed. Draws the element on the page with the specified page and structure Current page where the element should be drawn. Start location on the page. PdfLayoutResult that represents the layout result of the drawn element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Draws the element on the page with the specified page and pair of coordinates Current page where the element should be drawn. X co-ordinate of the element on the page. Y co-ordinate of the element on the page. PdfLayoutResult that represents the layout result of the drawn element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, 10, 10); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, 10, 10) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Draws the element on the page with the specified page and structure Current page where the element should be drawn. RectangleF structure that specifies the bounds of the element. PdfLayoutResult that represents the layout result of the drawn element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 1000); //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, new RectangleF(10, 10, 300, 500)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 1000) 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, New RectangleF(10, 10, 300, 500)) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Draws the element on the page. Current page where the element should be drawn. RectangleF structure that specifies the bounds of the element. PdfLayoutResult that represents the layout result of the drawn element. Draws the element on the page with the specified page, structure and layout format Current page where the element should be drawn. Start location on the page. PdfLayoutFormat that represents the layout settings PdfLayoutResult that represents the layout result of the drawn element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Create new PDF layout format. PdfLayoutFormat format = new PdfLayoutFormat(); //Set layout. format.Layout = PdfLayoutType.Paginate; //Set break type. format.Break = PdfLayoutBreakType.FitPage; //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, PointF.Empty, format); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Create new PDF layout format. Dim format As New PdfLayoutFormat() 'Set layout. format.Layout = PdfLayoutType.Paginate 'Set break type. format.Break = PdfLayoutBreakType.FitPage 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, PointF.Empty, format) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Draws the element on the page with the specified page, pair of coordinates and layout format Current page where the element should be drawn. X co-ordinate of the element on the page. Y co-ordinate of the element on the page. PdfLayoutFormat that represents the layout settings PdfLayoutResult that represents the layout result of the drawn element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Create new PDF layout format. PdfLayoutFormat format = new PdfLayoutFormat(); //Set layout. format.Layout = PdfLayoutType.Paginate; //Set break type. format.Break = PdfLayoutBreakType.FitPage; //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, 10, 20, format); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Create new PDF layout format. Dim format As New PdfLayoutFormat() 'Set layout. format.Layout = PdfLayoutType.Paginate 'Set break type. format.Break = PdfLayoutBreakType.FitPage 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, 10, 20, format) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Draws the element on the page with the specified page, structure and layout format Current page where the element should be drawn. RectangleF structure that specifies the bounds of the element. PdfLayoutFormat that represents the layout settings PdfLayoutResult that represents the layout result of the drawn element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Create new PDF layout format. PdfLayoutFormat format = new PdfLayoutFormat(); //Set layout. format.Layout = PdfLayoutType.Paginate; //Set break type. format.Break = PdfLayoutBreakType.FitPage; //Create layout rectangle. RectangleF layoutRect = new RectangleF(10, 10, 300, 500); //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, layoutRect, format); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Create new PDF layout format. Dim format As New PdfLayoutFormat() 'Set layout. format.Layout = PdfLayoutType.Paginate 'Set break type. format.Break = PdfLayoutBreakType.FitPage 'Create layout rectangle. Dim layoutRect As New RectangleF(10, 10, 300, 500) 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, layoutRect, format) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Layouts the element. Layout parameters. Returns the results of layout. Draws the element on the page. Current page where the element should be drawn. RectangleF structure that specifies the bounds of the element. Layout format. Layout result. Draws the specified page. The page. The top. The format. Layouts the element. Layout parameters. Returns the results of layout. Layouts the specified param. The param. null Raises EndPageLayout event. Event arguments. Raises BeginPageLayout event. Event arguments. Raises after the element was printed on the page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Create new PDF layout format. PdfLayoutFormat format = new PdfLayoutFormat(); //Set layout. format.Layout = PdfLayoutType.Paginate; //Set break type. format.Break = PdfLayoutBreakType.FitPage; //Create layout rectangle. RectangleF layoutRect = new RectangleF(10, 10, 300, 500); //Raise end page layout event. rect.EndPageLayout += Rect_EndPageLayout; //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, layoutRect, format); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Create new PDF layout format. Dim format As New PdfLayoutFormat() 'Set layout. format.Layout = PdfLayoutType.Paginate 'Set break type. format.Break = PdfLayoutBreakType.FitPage 'Create layout rectangle. Dim layoutRect As New RectangleF(10, 10, 300, 500) 'Raise the end page layout event AddHandler rect.EndPageLayout, AddressOf Rect_EndPageLayout 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, layoutRect, format) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Raises before the element should be printed on the page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Create new PDF layout format. PdfLayoutFormat format = new PdfLayoutFormat(); //Set layout. format.Layout = PdfLayoutType.Paginate; //Set break type. format.Break = PdfLayoutBreakType.FitPage; //Create layout rectangle. RectangleF layoutRect = new RectangleF(10, 10, 300, 500); //Raise begin page layout event. rect.BeginPageLayout += Rect_BeginPageLayout; //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, layoutRect, format); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Create new PDF layout format. Dim format As New PdfLayoutFormat() 'Set layout. format.Layout = PdfLayoutType.Paginate 'Set break type. format.Break = PdfLayoutBreakType.FitPage 'Create layout rectangle. Dim layoutRect As New RectangleF(10, 10, 300, 500) 'Raise the begin page layout event. AddHandler rect.BeginPageLayout, AddressOf Rect_BeginPageLayout 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, layoutRect, format) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Gets a value indicating whether EndPageLayout is not null. Gets a value indicating whether BeginPageLayout is not null. Gets a value indicating whether [embed fonts]. true if [embed fonts]; otherwise, false. Gets or sets the tag for the element //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 800); //Set PDF tag element. rect.PdfTag = new PdfStructureElement(PdfTagType.Figure); //Draw the rectangle to PDF page. PdfLayoutResult result = rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 800) 'Draw the rectangle to PDF page. Dim result As PdfLayoutResult = rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Text data. Text data. Pen for text drawing. Brush for text drawing. Font for text drawing. Text format. indicate whether the PdfGridCell value is PdfTextElement Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement(); //Set text. element.Text = "Hello World!!!"; //Set font. element.Font = font; //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement() 'Set text. element.Text = "Hello World!!!" 'Set font. element.Font = font 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with text to draw into the PDF. The text to draw into the PDF. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!"); //Set font. element.Font = font; //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!") 'Set font. element.Font = font 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with the text and . The text to draw into the PDF. The that defines the text format. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font); //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font) 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with text, and . The text to draw into the PDF. The that defines the text format. The that determines the color, width, and style of the text //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfPens.Black); //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfPens.Black) 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with text, and . The text to draw into the PDF. The that defines the text format. The that determines the color and texture of the drawn text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfBrushes.Black); //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfBrushes.Black) 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with text,,, and . The text to draw into the PDF. The that defines the text format. The that determines the color, width, and style of the text The that determines the color and texture of the drawn text. The that determines string format. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set alignments. format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfPens.Red, PdfBrushes.Black, format); //Draw the text element. element.Draw(page, new RectangleF(0, 0, 200, 20)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set alignments. format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfPens.Red, PdfBrushes.Black, format) 'Draw the text element. element.Draw(page, New RectangleF(0, 0, 200, 20)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Draws the text on the page in the specified location with . It returns the which contains last page and bounds where the text element drawn. Current page where the text should be drawn. PointF structure that specifies the start location on the page. The that represents the layout settings The that represents the layout result of the drawn text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfBrushes.Black); //Create layout format PdfLayoutFormat format=new PdfLayoutFormat(); format.Layout=PdfLayoutType.Paginate; //Draw the text with layout format element.Draw(page, new PointF(0, 0), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfBrushes.Black) 'Create layout format Dim format As New PdfLayoutFormat() format.Layout = PdfLayoutType.Paginate 'Draw the text with layout format element.Draw(page, New PointF(0, 0), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Draws the text on the page in the specified location,width and . It returns the which contains last page and bounds where the text element drawn Current page where the text should be drawn. PointF structure that specifies the start location on the page. Width of the text bounds. The that represents the layout settings The that represents the layout result of the drawn text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfBrushes.Black); //Create layout format PdfLayoutFormat format=new PdfLayoutFormat(); format.Layout=PdfLayoutType.Paginate; //Draw the text with layout format element.Draw(page, new PointF(0, 0), 200, format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfBrushes.Black) 'Create layout format Dim format As New PdfLayoutFormat() format.Layout = PdfLayoutType.Paginate 'Draw the text with layout format element.Draw(page, New PointF(0, 0), 200, format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Draws the text on the page with specified layout rectangle and . It returns the which contains last page and bounds where the text element drawn. Current page where the text should be drawn. RectangleF structure that specifies the bounds of the text. The that represents the layout settings The that represents the layout result of the drawn text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfBrushes.Black); //Create layout format PdfLayoutFormat format=new PdfLayoutFormat(); format.Layout=PdfLayoutType.Paginate; //Draw the text with layout format element.Draw(page, new RectangleF(0, 0, 200, 400), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfBrushes.Black) 'Create layout format Dim format As New PdfLayoutFormat() format.Layout = PdfLayoutType.Paginate 'Draw the text with layout format element.Draw(page, New RectangleF(0, 0, 200, 400), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets a brush for drawing. Gets a brush for drawing. Draws an element on the Graphics. Graphics context where the element should be printed. Layouts the element. Lay outing parameters. Returns lay outing results. Gets or sets a value indicating the text that should be printed. The to draw to the PDF //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement(); //Set text. element.Text = "Hello World!!!"; //Set font. element.Font = font; //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement() 'Set text. element.Text = "Hello World!!!" 'Set font. element.Font = font 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets a value indicating the text that should be printed. Gets or sets a that determines the color, width, and style of the text The that determines the color, width, and style of the text //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement(); //Set text. element.Text = "Hello World!!!"; //Set font. element.Font = font; //Set PDF pen. element.Pen = PdfPens.Red; //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement() 'Set text. element.Text = "Hello World!!!" 'Set font. element.Font = font 'Set PDF pen. element.Pen = PdfPens.Red 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the that will be used to draw the text with color and texture. The that determines the color and texture of the drawn text //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement(); //Set text. element.Text = "Hello World!!!"; //Set font. element.Font = font; //Set PDF brush. element.Brush = PdfBrushes.RoyalBlue; //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement() 'Set text. element.Text = "Hello World!!!" 'Set font. element.Font = font 'Set PDF brush. element.Brush = PdfBrushes.RoyalBlue 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets a that defines the text format. The that defines the text format //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF text element PdfTextElement element = new PdfTextElement(); //Set text. element.Text = "Hello World!!!"; //Set font. element.Font = font; //Set PDF brush. element.Brush = PdfBrushes.RoyalBlue; //Draw the text element. element.Draw(graphics); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF text element Dim element As New PdfTextElement() 'Set text. element.Text = "Hello World!!!" 'Set font. element.Font = font 'Set PDF brush. element.Brush = PdfBrushes.RoyalBlue 'Draw the text element. element.Draw(graphics) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the that will be used to set the string format The used to set the string format //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Use the font installed in the machine PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14)); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set alignments. format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; //Create PDF text element PdfTextElement element = new PdfTextElement("Hello World!!!", font, PdfPens.Red); //Set PDF string format. element.StringFormat = format; //Draw the text element. element.Draw(page, new RectangleF(0, 0, 200, 20)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Use the font installed in the machine Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14)) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set alignments. format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle 'Create PDF text element Dim element As New PdfTextElement("Hello World!!!", font, PdfPens.Red) 'Draw the text element. element.Draw(page, New RectangleF(0, 0, 200, 20)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Internal variable to store Url. Internal variable to store Uri Annotation object. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); //Set the font float fontSize = 10f; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Create a text web link annotation PdfTextWebLink webLinkAnnotation = new PdfTextWebLink(); webLinkAnnotation.Url = "http://www.yahoo.com"; webLinkAnnotation.Text = "Yahoo Mail"; webLinkAnnotation.Brush = brush; webLinkAnnotation.Font = font; webLinkAnnotation.Pen = PdfPens.Brown; webLinkAnnotation.DrawTextWebLink(page, new PointF(50, 40)); page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, new PointF(110, 40)); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Set the font Dim fontSize As Single = 10f Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Create a text web link annotation Dim webLinkAnnotation As New PdfTextWebLink() webLinkAnnotation.Url = "http://www.yahoo.com" webLinkAnnotation.Text = "Yahoo Mail" webLinkAnnotation.Brush = brush webLinkAnnotation.Font = font webLinkAnnotation.Pen = PdfPens.Brown webLinkAnnotation.DrawTextWebLink(page, New PointF(50, 40)) page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, New PointF(110, 40)) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Draws a Text Web Link on the Page The page where the annotation should be placed. The location of the annotation. Pdf Layout result //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); //Set the font float fontSize = 10f; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Create a text weblink annotation PdfTextWebLink webLinkAnnotation = new PdfTextWebLink(); webLinkAnnotation.Url = "http://www.yahoo.com"; webLinkAnnotation.Text = "Yagoo Mail"; webLinkAnnotation.Brush = brush; webLinkAnnotation.Font = font; webLinkAnnotation.Pen = PdfPens.Brown; webLinkAnnotation.DrawTextWebLink(page, new PointF(50, 40)); page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, new PointF(110, 40)); //Add this annotation to a new page. page.Annotations.Add(webLinkAnnotation); //Save the document to disk. document.Save("TextWebLink(.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Set the font Dim fontSize As Single = 10f Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Create a text weblink annotation Dim webLinkAnnotation As PdfTextWebLink = New PdfTextWebLink() webLinkAnnotation.Url = "http://www.yahoo.com" webLinkAnnotation.Text = "Yagoo Mail" webLinkAnnotation.Brush = brush webLinkAnnotation.Font = font webLinkAnnotation.Pen = PdfPens.Brown webLinkAnnotation.DrawTextWebLink(page, new PointF(50, 40)) page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, new PointF(110, 40)) 'Add this annotation to a new page. page.Annotations.Add(webLinkAnnotation) 'Save the document to disk. document.Save("TextWebLink(.pdf") Class Class Class Draw a Text Web Link on the Graphics The object specifies where annotation should be placed.. The location of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); //Set the font float fontSize = 10f; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Create a text weblink annotation PdfTextWebLink webLinkAnnotation = new PdfTextWebLink(); webLinkAnnotation.Url = "http://www.yahoo.com"; webLinkAnnotation.Text = "Yagoo Mail"; webLinkAnnotation.Brush = brush; webLinkAnnotation.Font = font; webLinkAnnotation.Pen = PdfPens.Brown; webLinkAnnotation.DrawTextWebLink(page.Graphics, new PointF(50, 40)); page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, new PointF(110, 40)); //Add this annotation to a new page. page.Annotations.Add(webLinkAnnotation); //Save the document to disk. document.Save("TextWebLink(.pdf"); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Set the font Dim fontSize As Single = 10f Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Create a text weblink annotation Dim webLinkAnnotation As PdfTextWebLink = New PdfTextWebLink() webLinkAnnotation.Url = "http://www.yahoo.com" webLinkAnnotation.Text = "Yagoo Mail" webLinkAnnotation.Brush = brush webLinkAnnotation.Font = font webLinkAnnotation.Pen = PdfPens.Brown webLinkAnnotation.DrawTextWebLink(page.Graphics, new PointF(50, 40)) page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, new PointF(110, 40)) 'Add this annotation to a new page. page.Annotations.Add(webLinkAnnotation) 'Save the document to disk. document.Save("TextWebLink(.pdf") Class Class Class Re-evaluates URI bounds based on string format. Rotate and transform the text web link and text markup annotaiton while loading page The base graphics. Gets or sets the Uri address. The string value which contains the Uri address. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); //Set the font float fontSize = 10f; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Create a text web link annotation PdfTextWebLink webLinkAnnotation = new PdfTextWebLink(); webLinkAnnotation.Url = "http://www.yahoo.com"; webLinkAnnotation.Text = "Yahoo Mail"; webLinkAnnotation.Brush = brush; webLinkAnnotation.Font = font; webLinkAnnotation.Pen = PdfPens.Brown; webLinkAnnotation.DrawTextWebLink(page, new PointF(50, 40)); page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, new PointF(110, 40)); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Set the font Dim fontSize As Single = 10f Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Create a text weblink annotation Dim webLinkAnnotation As New PdfTextWebLink() webLinkAnnotation.Url = "http://www.yahoo.com" webLinkAnnotation.Text = "Yagoo Mail" webLinkAnnotation.Brush = brush webLinkAnnotation.Font = font webLinkAnnotation.Pen = PdfPens.Brown webLinkAnnotation.DrawTextWebLink(page, New PointF(50, 40)) page.Graphics.DrawString("Go to Yahoo Web Site", font, brush, New PointF(110, 40)) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Represents a base class for popup annotation which can be either in open or closed state. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(rectangle, "Test popup annotation"); popupAnnotation.Border.Width = 4; popupAnnotation.Border.HorizontalRadius = 20; popupAnnotation.Border.VerticalRadius = 30; //Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph; //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(rectangle, "Test popup annotation") popupAnnotation.Border.Width = 4 popupAnnotation.Border.HorizontalRadius = 20 popupAnnotation.Border.VerticalRadius = 30 'Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Indicates whether annotation is open or not. Type of the icon of the annotation. Annotation's appearance. Annotation Review State Annotation Review StateModel Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(); popupAnnotation.Text = "Test popup annotation"; popupAnnotation.Bounds = rectangle; popupAnnotation.Border.Width = 4; popupAnnotation.Border.HorizontalRadius = 20; popupAnnotation.Border.VerticalRadius = 30; //Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph; //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation() popupAnnotation.Text = "Test popup annotation" popupAnnotation.Bounds = rectangle popupAnnotation.Border.Width = 4 popupAnnotation.Border.HorizontalRadius = 20 popupAnnotation.Border.VerticalRadius = 30 'Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Initializes a new instance of the class with specified bounds. RectangleF structure that specifies the bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(rectangle); popupAnnotation.Text = "Test popup annotation"; popupAnnotation.Border.Width = 4; popupAnnotation.Border.HorizontalRadius = 20; popupAnnotation.Border.VerticalRadius = 30; //Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph; //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(rectangle) popupAnnotation.Text = "Test popup annotation" popupAnnotation.Border.Width = 4 popupAnnotation.Border.HorizontalRadius = 20 popupAnnotation.Border.VerticalRadius = 30 'Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Initializes a new instance of the class with specified bounds and annotation text. RectangleF structure that specifies the bounds of the annotation. The string specifies the annotation text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(rectangle, "Test popup annotation"); popupAnnotation.Border.Width = 4; popupAnnotation.Border.HorizontalRadius = 20; popupAnnotation.Border.VerticalRadius = 30; //Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph; //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(rectangle, "Test popup annotation") popupAnnotation.Border.Width = 4 popupAnnotation.Border.HorizontalRadius = 20 popupAnnotation.Border.VerticalRadius = 30 'Set the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Initializes a new instance of the class with specified popup comment window bounds and bool for represents popup. RectangleF structure that specifies the bounds of the popup annotation comment window. Boolean indivate popup comment window Initializes annotation object. Saves an annotation. Flatten annotation Icon the annotation's subject text Gets or sets value whether annotation is initially open or closed. True if the annotation is intially open, otherwise false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(rectangle, "Test popup annotation"); //Set the Open to popupAnnotation. popupAnnotation.Open = true; //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(rectangle, "Test popup annotation") 'Set the Open to popupAnnotation. popupAnnotation.Open = True 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Gets or sets the annotation review State. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation and set properties. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points); lineAnnotation.Text = "Line Annotation"; //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Add Review state //set Review and comments PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Author = "Hello"; popup.Text = "Hello PDF Comments"; lineAnnotation.ReviewHistory.Add(popup); //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); lineAnnotation.ReviewHistory.Add(testreview); //Save the document to disk. document.Save("OutputLinePopup.pdf"); //close the document document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim lineAnnotation As PdfLineAnnotation = New PdfLineAnnotation(points) lineAnnotation.Text = "Line Annotation" Dim lineBorder As LineBorder = New LineBorder lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Author = "Hello" popup.Text = "Hello PDF Comments" lineAnnotation.ReviewHistory.Add(popup) 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) lineAnnotation.ReviewHistory.Add(testreview) 'Save the document to disk. document.Save("OutputLinePopup.pdf") 'close the document document.Close(true) Gets or sets the annotation review State Model. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation and set properties. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points); lineAnnotation.Text = "Line Annotation"; //Create pdf line border LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.BorderWidth = 1; lineAnnotation.lineBorder = lineBorder; lineAnnotation.LineIntent = PdfLineIntent.LineDimension; //Add Review state //set Review and comments PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Author = "Hello"; popup.Text = "Hello PDF Comments"; lineAnnotation.ReviewHistory.Add(popup); //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); lineAnnotation.ReviewHistory.Add(testreview); //Save the document to disk. document.Save("OutputLinePopup.pdf"); //close the document document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim points() As Integer = New Integer() { 80, 420, 150, 420} Dim lineAnnotation As PdfLineAnnotation = New PdfLineAnnotation(points) lineAnnotation.Text = "Line Annotation" Dim lineBorder As LineBorder = New LineBorder lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.BorderWidth = 1 lineAnnotation.lineBorder = lineBorder lineAnnotation.LineIntent = PdfLineIntent.LineDimension Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Author = "Hello" popup.Text = "Hello PDF Comments" lineAnnotation.ReviewHistory.Add(popup) 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) lineAnnotation.ReviewHistory.Add(testreview) 'Save the document to disk. document.Save("OutputLinePopup.pdf") 'close the document document.Close(true) Gets the annotation reviews PdfDocument doc = new PdfDocument(); PdfPage page = doc.Pages.Add(); //Creates a rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Creates a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(rectangle, "Test popup annotation"); popupAnnotation.Border.Width = 4; popupAnnotation.Border.HorizontalRadius = 20; popupAnnotation.Border.VerticalRadius = 30; //Sets the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph; //set Reviews PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; popupAnnotation.ReviewHistory.Add(popup); //Get annotation comments PdfPopupAnnotationCollection reviewCollection = popupAnnotation.ReviewHistory; //Saves the document to disk. doc.Save("Output.pdf"); doc.Close(true); Dim doc As PdfDocument = New PdfDocument Dim page As PdfPage = doc.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim popupAnnotation As PdfPopupAnnotation = New PdfPopupAnnotation(rectangle, "Test popup annotation") popupAnnotation.Border.Width = 4 popupAnnotation.Border.HorizontalRadius = 20 popupAnnotation.Border.VerticalRadius = 30 'Sets the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" popupAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = popupAnnotation.ReviewHistory 'Saves the document to disk. doc.Save("Output.pdf") doc.Close(true) Gets the annotation comments PdfDocument doc = new PdfDocument(); PdfPage page = doc.Pages.Add(); //Creates a rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Creates a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(rectangle, "Test popup annotation"); popupAnnotation.Border.Width = 4; popupAnnotation.Border.HorizontalRadius = 20; popupAnnotation.Border.VerticalRadius = 30; //Sets the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph; //set comments PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; popupAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = popupAnnotation.Comments; //Saves the document to disk. doc.Save("Output.pdf"); doc.Close(true); Dim doc As PdfDocument = New PdfDocument Dim page As PdfPage = doc.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim popupAnnotation As PdfPopupAnnotation = New PdfPopupAnnotation(rectangle, "Test popup annotation") popupAnnotation.Border.Width = 4 popupAnnotation.Border.HorizontalRadius = 20 popupAnnotation.Border.VerticalRadius = 30 'Sets the pdf popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" popupAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = popupAnnotation.Comments 'Saves the document to disk. doc.Save("Output.pdf") doc.Close(true) Represents the rubber stamp annotation for a PDF document. This class is used to displays text or graphics stamped on the page. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf rubber stamp annotation. RectangleF rectangle = new RectangleF(40, 60, 80, 20); PdfRubberStampAnnotation rubberstampAnnotation = new PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation"); rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft; rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation"; page.Annotations.Add(rubberstampAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf rubber stamp annotation. Dim rectangle As New RectangleF(40, 60, 80, 20) Dim rubberstampAnnotation As New PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation") rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation" page.Annotations.Add(rubberstampAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class internal variable for the rubberstamp annotation icon Annotation's appearance. internal variable for Icon name to draw graphically internal variable to width size for rubber stamp internal variable to set rotation angle. Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new pdf rubber stamp annotation. PdfRubberStampAnnotation rubberstampAnnotation = new PdfRubberStampAnnotation(); rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft; rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation"; page.Annotations.Add(rubberstampAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new pdf rubber stamp annotation. Dim rubberstampAnnotation As New PdfRubberStampAnnotation() rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation" page.Annotations.Add(rubberstampAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Initializes a new instance of the class with specified bounds. RectangleF structure that specifies the bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf rubber stamp annotation. RectangleF rubberStampAnnotationBounds = new RectangleF(40, 60, 80, 20); PdfRubberStampAnnotation rubberstampAnnotation = new PdfRubberStampAnnotation(rubberStampAnnotationBounds); rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft; rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation"; page.Annotations.Add(rubberstampAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf rubber stamp annotation. Dim rubberStampAnnotationBounds As New RectangleF(40, 60, 80, 20) Dim rubberStampAnnotation As New PdfRubberStampAnnotation(rubberStampAnnotationBounds) rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft rubberStampAnnotation.Text = "Text Properties Rubber Stamp Annotation" page.Annotations.Add(rubberStampAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Initializes a new instance of the class with specified bounds and text. The rectangleF structure that specifies the bounds of the annotation. The text of the rubber stamp annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf rubber stamp annotation. RectangleF rubberStampAnnotationBounds = new RectangleF(40, 60, 80, 20); PdfRubberStampAnnotation rubberStampAnnotation = new PdfRubberStampAnnotation(rubberStampAnnotationBounds, " Text Rubber Stamp Annotation"); //Sets the PDF appearance. rubberStampAnnotation.Appearance = new PdfAppearance(rubberstampAnnotation); rubberStampAnnotation.Appearance.Normal.Draw(page, new PointF(rubberStampAnnotation.Location.X, rubberStampAnnotation.Location.Y)); page.Annotations.Add(rubberStampAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf rubber stamp annotation. Dim rubberStampAnnotationBounds As New RectangleF(40, 60, 80, 20) Dim rubberStampAnnotation As New PdfRubberStampAnnotation(rubberStampAnnotationBounds, " Text Rubber Stamp Annotation") 'Sets the PDF appearance. rubberStampAnnotation.Appearance = New PdfAppearance(rubberstampAnnotation) rubberStampAnnotation.Appearance.Normal.Draw(page, New PointF(rubberStampAnnotation.Location.X, rubberStampAnnotation.Location.Y)) page.Annotations.Add(rubberStampAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Initializes annotation object. Obtain the Icon name for the current stamp Obtain the background color for stamp Pdfcolor Type Obtain the border color for stamp Pdfcolor type Obtain Font to draw stamp Font type Saves an annotation. Flatten annotation Create appearance for annotation Create stamp appearance Set default icon in annotation Draw custom appearance Draw Rubber stamp in graphics Draw Rubber stamp in graphics Set matrix for appearance Set CustomStamp icon in annotation Gets or sets the annotation's icon. A enumeration member specifying the icon for the annotation when it is displayed in closed state. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf rubber stamp annotation. RectangleF rectangle = new RectangleF(40, 60, 80, 20); PdfRubberStampAnnotation rubberStampAnnotation = new PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation"); rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft; rubberStampAnnotation.Text = "Text Properties Rubber Stamp Annotation"; page.Annotations.Add(rubberStampAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new pdf rubber stamp annotation. Dim rectangle As New RectangleF(40, 60, 80, 20) Dim rubberStampAnnotation As New PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation") rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft rubberStampAnnotation.Text = "Text Properties Rubber Stamp Annotation" page.Annotations.Add(rubberStampAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets the annotation reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf rubber stamp annotation. RectangleF rectangle = new RectangleF(40, 60, 80, 20); PdfRubberStampAnnotation rubberstampAnnotation = new PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation"); rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft; rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation"; PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; rubberstampAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = rubberstampAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(40, 60, 80, 20) Dim rubberstampAnnotation As PdfRubberStampAnnotation = New PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation") rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation" Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" rubberstampAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = rubberstampAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new pdf rubber stamp annotation. RectangleF rectangle = new RectangleF(40, 60, 80, 20); PdfRubberStampAnnotation rubberstampAnnotation = new PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation"); rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft; rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation"; PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; rubberstampAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = rubberstampAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(40, 60, 80, 20) Dim rubberstampAnnotation As PdfRubberStampAnnotation = New PdfRubberStampAnnotation(rectangle, " Text Rubber Stamp Annotation") rubberstampAnnotation.Icon = PdfRubberStampAnnotationIcon.Draft rubberstampAnnotation.Text = "Text Properties Rubber Stamp Annotation" Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" rubberstampAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = rubberstampAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the ICON Name Gets the background color for stamp Gets the border color for stamp Gets the Font Represents the sound annotation. This class is used to play a sound clip in PDF document. Please refer the UG docuemntation link for more details. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed; soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo; soundAnnotation.Sound.Bits = 16; soundAnnotation.Color = new PdfColor(Color.Red); //Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo soundAnnotation.Sound.Bits = 16 soundAnnotation.Color = New PdfColor(Color.Red) 'Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Type of icon of the sound link. Internal variable to store sound. RectangleF structure that specifies the bounds of the annotation. The string specifies the file name of the sound annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed; soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo; soundAnnotation.Sound.Bits = 16; soundAnnotation.Color = new PdfColor(Color.Red); //Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Set the pdf sound soundAnnotation.Sound = New PdfSound("Input.wav") 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Initializes instance. Saves instance. Gets or sets the icon to be used in displaying the annotation. The enumeration member specifying the icon for the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed; soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo; soundAnnotation.Sound.Bits = 16; soundAnnotation.Color = new PdfColor(Color.Red); //Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo soundAnnotation.Sound.Bits = 16 soundAnnotation.Color = New PdfColor(Color.Red) 'Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets or sets the sound. The object specified a sound for the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed; soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo; soundAnnotation.Sound.Bits = 16; soundAnnotation.Color = new PdfColor(Color.Red); //Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Set the pdf sound soundAnnotation.Sound = New PdfSound("Input.wav") 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Gets the annotation Reviews //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"decoded.wav"); soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed; soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo; soundAnnotation.Sound.Bits = 16; soundAnnotation.Color = new PdfColor(Color.Red); //Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Add review State PdfPopupAnnotation popup = new PdfPopupAnnotation(); popup.State = PdfAnnotationState.Accepted; popup.StateModel = PdfAnnotationStateModel.Review; popup.Text = "Hello PDF Comments"; soundAnnotation.ReviewHistory.Add(popup); //Get Review history PdfPopupAnnotationCollection reviewCollection = soundAnnotation.ReviewHistory; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "decoded.wav") soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo soundAnnotation.Sound.Bits = 16 soundAnnotation.Color = New PdfColor(Color.Red) 'Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker Dim popup As PdfPopupAnnotation = New PdfPopupAnnotation popup.State = PdfAnnotationState.Accepted popup.StateModel = PdfAnnotationStateModel.Review popup.Text = "Hello PDF Comments" soundAnnotation.ReviewHistory.Add(popup) Dim reviewCollection As PdfPopupAnnotationCollection = soundAnnotation.ReviewHistory 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) Gets the annotation comments //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"decoded.wav"); soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed; soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo; soundAnnotation.Sound.Bits = 16; soundAnnotation.Color = new PdfColor(Color.Red); //Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; PdfPopupAnnotation popupComments = new PdfPopupAnnotation(); popupComments.Author = "TestAuthor"; popupComments.Text = "Test Text"; soundAnnotation.Comments.Add(popupComments); //Get annotation comments PdfPopupAnnotationCollection commentsCollection = soundAnnotation.Comments; //Saves the document to disk. document.Save("Output.pdf"); document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) Dim soundAnnotation As PdfSoundAnnotation = New PdfSoundAnnotation(rectangle, "decoded.wav") soundAnnotation.Sound.Encoding = PdfSoundEncoding.Signed soundAnnotation.Sound.Channels = PdfSoundChannels.Stereo soundAnnotation.Sound.Bits = 16 soundAnnotation.Color = New PdfColor(Color.Red) 'Sets the pdf sound icon. soundAnnotation.Icon = PdfSoundIcon.Speaker Dim popupComments As PdfPopupAnnotation = New PdfPopupAnnotation popupComments.Author = "TestAuthor" popupComments.Text = "Test Text" soundAnnotation.Comments.Add(popupComments) Dim commentsCollection As PdfPopupAnnotationCollection = soundAnnotation.Comments 'Saves the document to disk. document.Save("Output.pdf") document.Close(true) The string specifies the file name of the sound annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Gets the file name. string fileName = soundAnnotation.FileName; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Gets the file name. Dim fileName As String = soundAnnotation.FileName 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Represents the Uri annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Uri Annotation. PdfUriAnnotation uriAnnotation = new PdfUriAnnotation(rectangle, "http://www.google.com"); //Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation"; //Add this annotation to a new page. page.Annotations.Add(uriAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Uri Annotation. Dim uriAnnotation As New PdfUriAnnotation(rectangle, "http://www.google.com") 'Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation" 'Add this annotation to a new page. page.Annotations.Add(uriAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Internal variable to store acton for the annotation. Initializes a new instance of the class with specified bounds. RectangleF structure that specifies the bounds of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Uri Annotation. PdfUriAnnotation uriAnnotation = new PdfUriAnnotation(rectangle); //Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation"; // Set Uri to uriAnnotation uriAnnotation.Uri = "http://www.google.com"; //Add this annotation to a new page. page.Annotations.Add(uriAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Uri Annotation. Dim uriAnnotation As New PdfUriAnnotation(rectangle) 'Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation" ' Set Uri to uriAnnotation uriAnnotation.Uri = "http://www.google.com" 'Add this annotation to a new page. page.Annotations.Add(uriAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Initializes a new instance of the class with specified bounds and Uri. RectangleF structure that specifies the bounds of the annotation. unique resource identifier path. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Uri Annotation. PdfUriAnnotation uriAnnotation = new PdfUriAnnotation(rectangle, "http://www.google.com"); //Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation"; //Add this annotation to a new page. page.Annotations.Add(uriAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Creates a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Uri Annotation. Dim uriAnnotation As New PdfUriAnnotation(rectangle, "http://www.google.com") 'Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation" 'Add this annotation to a new page. page.Annotations.Add(uriAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Initializes annotation object. Gets or sets the Uri address. The string value which contains Uri address. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Uri Annotation. PdfUriAnnotation uriAnnotation = new PdfUriAnnotation(rectangle); // Set Uri to uriAnnotation uriAnnotation.Uri = "http://www.google.com"; //Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation"; //Add this annotation to a new page. page.Annotations.Add(uriAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Uri Annotation. Dim uriAnnotation As New PdfUriAnnotation(rectangle) 'Set Uri to uriAnnotation uriAnnotation.Uri = "http://www.google.com" 'Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation" 'Add this annotation to a new page. page.Annotations.Add(uriAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the action. The object specifies the action of the annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Uri Annotation. PdfUriAnnotation uriAnnotation = new PdfUriAnnotation(rectangle); //Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation"; // Set Uri to uriAnnotation uriAnnotation.Uri = "http://www.google.com"; //Creates a new Sound action PdfSoundAction soundAction = new PdfSoundAction(@"Input.wav"); soundAction.Sound.Bits = 16; soundAction.Sound.Channels = PdfSoundChannels.Stereo; soundAction.Sound.Encoding = PdfSoundEncoding.Signed; soundAction.Volume = 0.9f; uriAnnotation.Action = soundAction; //Add this annotation to a new page. page.Annotations.Add(uriAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new Uri Annotation. Dim uriAnnotation As New PdfUriAnnotation(rectangle) 'Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation" ' Set Uri to uriAnnotation uriAnnotation.Uri = "http://www.google.com" 'Creates a new Sound action Dim soundAction As New PdfSoundAction("Input.wav") soundAction.Sound.Bits = 16 soundAction.Sound.Channels = PdfSoundChannels.Stereo soundAction.Sound.Encoding = PdfSoundEncoding.Signed soundAction.Volume = 0.9f uriAnnotation.Action = soundAction 'Add this annotation to a new page. page.Annotations.Add(uriAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Represents the widget annotation. Internal variable to store parent field. Internal variable to store extended appearance. Internal variable to store border parameters. Internal variable to store appearance of the widget. Internal variable to store highlighting mode. Internal variable to store default appearance. Internal variable to store alignment. Internal variable to store annotation's actions. Annotation's appearance. Internal variable to store default appearance state value. Internal variable to store value whether AutoResizeText is enabled or not. Internal variable to store value of signature field. Initializes annotation object. Raises the event. The instance containing the event data. Saves an annotation. Highlightings the mode to string. The m_highlighting mode. String representation of the highlighting mode in Pdf suiatable format. Gets the appearance. Gets or sets the parent. The parent. Gets or sets the extended appearance. The extended appearance. Gets the default appearance. The default appearance. Gets or sets annotation's border. The widget border. Gets the widget appearance. The widget appearance. Gets or sets the highlighting mode. The highlighting mode. Gets or sets the text alignment. The text alignment. Gets the actions of the annotation. The actions. Gets or sets appearance of the annotation. Gets or sets default appearance name. The state of the appearance. Raise before object saves. Represents collection of widget annotations. Internal variable to store array of anootation's primitives. Initializes a new instance of the class. Adds the specified annotation. The annotation. Inserts the specified index. The index. The annotation. Removes the specified annotation. The annotation. Removes the annotation at the specified position. The index. Gets the index of the specified annotation. The annotation. Determines whether the annotation is present in collection. The annotation. true if collection contains the specified annotation; otherwise, false. Clears the collection. Adds the annotation. The annotation. Insters.the annotation at the specified position. The index. The annotation. Removes the annotation. The annotation. Removes the annotation at the specified position. The index. Clears the collection. Gets the at the specified index. Annotation at the specified position. Gets the element. Represents appearance of the widget annotation. Internal variable to store border's color. Internal variable to store color of the background. Internal variable to store normal cation text. Internal variable to store dictionary. Initializes a new instance of the class. Gets or sets the color of the border. The color of the border. Gets or sets the color of the background. The color of the background. Gets or sets the normal caption. The normal caption. Gets the element. Represents the border style of the widget annotation. Internal variable to store border width. Internal variable to store border style; Internal variable to store dictionary. Initializes a new instance of the class. Converts border style to string. The style. Gets or sets the width. The width. Gets or sets the style. The style. Gets the element. Specifies the name of an icon to be used in displaying the sound annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new sound annotation. PdfSoundAnnotation soundAnnotation = new PdfSoundAnnotation(rectangle, @"Input.wav"); //Sets the sound icon soundAnnotation.Icon = PdfSoundIcon.Speaker; //Add this annotation to a new page. page.Annotations.Add(soundAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim rectangle As New RectangleF(10, 40, 30, 30) 'Create a new sound annotation. Dim soundAnnotation As New PdfSoundAnnotation(rectangle, "Input.wav") 'Sets the sound icon soundAnnotation.Icon = PdfSoundIcon.Speaker 'Add this annotation to a new page. page.Annotations.Add(soundAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Speaker icon of sound link. Microphone icon of sound link. Specifies the type of icon to be used in displaying file attachment annotations. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30); //Create a new attachment annotation. PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"Input.jpg"); //Set the Attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin; //Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim attachmentRectangle As New RectangleF(10, 40, 30, 30) 'Create a new attachment annotation. Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentRectangle, "Input.jpg") 'Set the Attachment icon to attachment annotation. attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin 'Add this annotation to a new page. page.Annotations.Add(attachmentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Type of icon used in file attachment annotation. Type of icon used in file attachment annotation. Type of icon used in file attachment annotation. Type of icon used in file attachment annotation. Specifies the enumeration of the annotation flags. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF docLinkAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new document link annotation. PdfDocumentLinkAnnotation documentAnnotation = new PdfDocumentLinkAnnotation(docLinkAnnotationRectangle); //Set the annotation flags to document annotation. documentAnnotation.AnnotationFlags = PdfAnnotationFlags.NoRotate; //Add this annotation to a new page. page.Annotations.Add(documentAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim docLinkAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new document link annotation. Dim documentAnnotation As New PdfDocumentLinkAnnotation(docLinkAnnotationRectangle) 'Set the annotation flags to document annotation. documentAnnotation.AnnotationFlags = PdfAnnotationFlags.NoRotate 'Add this annotation to a new page. page.Annotations.Add(documentAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Default value. Represents invisible annotation flag's key. Represents hidden annotation flag's key. Represents print annotation flag's key. Represents annotation flag's key with no zooming. Represents annotation flag's key with no rotation. Represents annotation flag's key with no view. Represents read only annotation flag's key. Represents locked annotation flag's key. Annotation flag's key with no toggle view. Specifies the enumeration of popup annotation icons. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF popupAnnotationRectangle = new RectangleF(10, 40, 30, 30); //Create a new popup annotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation"); //Set the popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph; //Add this annotation to a new page. page.Annotations.Add(popupAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim popupAnnotationRectangle As New RectangleF(10, 40, 30, 30) 'Create a new popup annotation. Dim popupAnnotation As New PdfPopupAnnotation(popupAnnotationRectangle, "Test popup annotation") 'Set the popup icon. popupAnnotation.Icon = PdfPopupIcon.NewParagraph 'Add this annotation to a new page. page.Annotations.Add(popupAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Indicates note popup annotation. Indicates comment popup annotation. Indicates help popup annotation. Indicates insert popup annotation. Indicates key popup annotation. Indicates new paragraph popup annotation. Indicates paragraph popup annotation. Specifies the available styles for a border. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page . PdfPage page = document.Pages.Add(); //To specify the line end points. int[] points = new int[] { 80, 420, 150, 420 ,40 ,800 }; //Create a polygon annotation. PdfPolygonAnnotation polygonannotation = new PdfPolygonAnnotation(points, "Polygon Annotation"); //Create pdf border Effect. PdfBorderEffect borderEffect = new PdfBorderEffect(); borderEffect.Style = PdfBorderEffectStyle.Cloudy; borderEffect.Intensity = 1; polygonannotation.BorderEffect = borderEffect; //Add this annotation to a new page. page.Annotations.Add(polygonannotation); //Save the document to disk. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page . Dim page As PdfPage = document.Pages.Add() 'To specify the line end points. Dim points() As Integer = { 80, 420, 150, 420, 40, 800 } 'Create a new Polygon annotation. Dim polygonannotation As New PdfPolygonAnnotation(points, "Polygon Annotation") 'Create pdf border Effect. Dim borderEffect As New PdfBorderEffect() borderEffect.Style = PdfBorderEffectStyle.Cloudy borderEffect.Intensity=1; polygonannotation.BorderEffect = borderEffect 'Add this annotation to a new page. page.Annotations.Add(polygonannotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document. document.Close(True) Default value is Solid. Class Class Class A solid rectangle surrounding the annotation. A cloudy rectangle surrounding the annotation. Specifies the enumeration of rubber stamp annotation icons. //Load an existing document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.Pdf"); //Gets the annotation from loaded document. PdfLoadedRubberStampAnnotation rubberStampAnnotation = loadedDocument.Pages[1].Annotations[5] as PdfLoadedRubberStampAnnotation; //Set the icon rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Approved; //Save the document. loadedDocument.Save("Output.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document. Dim loadedDocument As New PdfLoadedDocument("Input.Pdf") 'Gets the annotation from loaded document. Dim rubberStampAnnotation As PdfLoadedRubberStampAnnotation = TryCast(loadedDocument.Pages(1).Annotations(5), PdfLoadedRubberStampAnnotation) 'Set the icon rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Approved 'Save the document. loadedDocument.Save("Output.pdf") 'close the document loadedDocument.Close(True) Indicates approved rubber stamp annotation Indicates AsIs rubber stamp annotation Indicates confidential rubber stamp annotation Indicates departmental rubber stamp annotation Indicates draft rubber stamp annotation Indicates experimental rubber stamp annotation Indicates expired rubber stamp annotation Indicates final rubber stamp annotation Indicates for comment rubber stamp annotation Indicates for public release rubber stamp annotation Indicates not approved rubber stamp annotation Indicates not for public release rubber stamp annotation Indicates sold rubber stamp annotation Indicates top secret rubber stamp annotation Indicates Completed rubber stamp annotation Indicates void rubber stamp annotation Indicates information only rubber stamp annotation Indicates preliminary results rubber stamp annotation Specifies the line ending style to be used in the Line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation linkAnnotation = new PdfLineAnnotation(points, "Line Annotation"); linkannotation.EndLineStyle = PdfLineEndingStyle.Diamond; //Add this annotation to a new page. page.Annotations.Add(linkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim linkAnnotation As New PdfLineAnnotation(points, "Line Annotation") linkannotation.EndLineStyle = PdfLineEndingStyle.Diamond 'Add this annotation to a new page. page.Annotations.Add(linkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Indicates None Indicates OpenArrow Indicates ClosedArrow Indicates ROpenArrow Indicates RClosedArrow Indicates Butt Indicates Diamond Indicates Circle Indicates Square Indicates Slash Specifies the line border Style of the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF inkAnnotationBounds = new RectangleF(10, 40, 30, 30); //To specify the line points List(float) points = new List(float) { 50, 50, 30, 30, 40, 40 }; //Create a new line annotation. PdfInkAnnotation inkAnnotation = new PdfInkAnnotation(inkAnnotationBounds, points); inkAnnotation.Color = new PdfColor(Color.Red); //Set the line border style. inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed; //Add this annotation to a new page. page.Annotations.Add(inkAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim inkAnnotationBounds As New RectangleF(10, 40, 30, 30) 'To specify the line points Dim points As New List(Of Single) (New Single() {50, 50, 30, 30, 40, 40}) 'Create a new line annotation. Dim inkAnnotation As New PdfInkAnnotation(inkAnnotationBounds, points) inkAnnotation.Color = New PdfColor(Color.Red) 'Set the line border style. inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed 'Add this annotation to a new page. page.Annotations.Add(inkAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Indicates Solid Indicates Dashed Indicates Beveled Indicates Inset Indicates Underline Specifies the Line Intent Style is to be used in the line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the pdf line indent. lineAnnotation.LineIntent = PdfLineIntent.LineArrow; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the pdf line indent. lineAnnotation.LineIntent = PdfLineIntent.LineArrow 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Indicates Line Arrow as intent of the line annotation Indicates LineDimension as intent of the line annotation Specifies the Line Caption Type is to be used in the Line annotation. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //To specify the line end points int[] points = new int[] { 80, 420, 150, 420 }; //Create a new line annotation. PdfLineAnnotation lineAnnotation = new PdfLineAnnotation(points, "Line Annoation"); //Set the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Inline; //Add this annotation to a new page. page.Annotations.Add(lineAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'To specify the line end points Dim points() As Integer = { 80, 420, 150, 420 } 'Create a new line annotation. Dim lineAnnotation As New PdfLineAnnotation(points, "Line Annoation") 'Set the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Inline 'Add this annotation to a new page. page.Annotations.Add(lineAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Indicates Inline as annotation caption positioning Indicates Top as annotation caption positioning Specifies the Style of the Text Markup Annotation //Load an existing document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Gets the annotation from loaded document. PdfLoadedTextMarkupAnnotation textMarkupAnnotation = loadedDocument.Pages[1].Annotations[5] as PdfLoadedTextMarkupAnnotation; //Sets the pdf text markup annotation type textMarkupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight; //Save the document. loadedDocument.Save("Output.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document. Dim loadedDocument As New PdfLoadedDocument("input.pdf") 'Gets the annotation from loaded document. Dim textMarkupAnnotation As PdfLoadedTextMarkupAnnotation = TryCast(loadedDocument.Pages(1).Annotations(5), PdfLoadedTextMarkupAnnotation) 'Sets the pdf text markup annotation type textMarkupAnnotation.TextMarkupAnnotationType = PdfTextMarkupAnnotationType.Highlight 'Save the document. loadedDocument.Save("Output.pdf") 'close the document loadedDocument.Close(True) The Text Markup Annotation Type is Highlight. The Text Markup Annotation Type is Underline. The Text Markup Annotation Type is Squiggly. The Text Markup Annotation Type is StrikeOut. Specifies the annotation types. Highlight type annotation. Underline type annotation. Redaction type annotation. StrikeOut type annotation. Squiggly type annotation. AnnotationStates type. TextAnnotation type. LinkAnnotation type. DocumentLinkAnnotation type. FileLinkAnnotation type. FreeTextAnnotation type. LineAnnotation type. CircleAnnotation type. Ellipse type. SquareAnnotation type. RectangleAnnotation type. PolygonAnnotation type. PolyLineAnnotation type. SquareandCircleAnnotation type. PolygonandPolylineAnnotation type. TextMarkupAnnotation type. CaretAnnotation type. RubberStampAnnotation type. LnkAnnotation type. PopupAnnotation type. FileAttachmentAnnotation type. SoundAnnotation type. MovieAnnotation type. ScreenAnnotation type. WidgetAnnotation type. PrinterMarkAnnotation type. TrapNetworkAnnotation type. WatermarkAnnotation type. TextWebLinkAnnotation type. InkAnnotation type No annotation. Specifies the annotation text intent. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Create a new rectangle RectangleF textAnnotationBounds = new RectangleF(10, 40, 100, 30); //Create a new line annotation. PdfFreeTextAnnotation actionAnnotation = new PdfFreeTextAnnotation(textAnnotationBounds); //Set the text and font actionAnnotation.MarkupText = "Text Annotation"; actionAnnotation.Font = new PdfStandardFont(PdfFontFamily.Courier, 10); //Set the line caption type. actionAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //Add this annotation to a new page. page.Annotations.Add(actionAnnotation); //Save the document to disk. document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create a new page. Dim page As PdfPage = document.Pages.Add() 'Create a new rectangle Dim textAnnotationBounds As New RectangleF(10, 40, 100, 30) 'Create a new line annotation. Dim actionAnnotation As New PdfFreeTextAnnotation(textAnnotationBounds) 'Set the text and font actionAnnotation.MarkupText = "Text Annotation" actionAnnotation.Font = New PdfStandardFont(PdfFontFamily.Courier, 10) 'Set the line caption type. actionAnnotation.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'Add this annotation to a new page. page.Annotations.Add(actionAnnotation) 'Save the document to disk. document.Save("Output.pdf") 'close the document document.Close(True) Class Class Class Represents annotation intent. Represents annotation intent. Specifies the Measurement unit of the annotation. Specifies the inch as the unit of measure. Specifies a printer's point (1/72 inch) as the unit of measure. Specifies the Measurement is in centimeters. Specifies the Circle Measurement unit of the annotation. Specifies the Measurement is in diameter. Specifies the Measurement is in radius. The number of degrees by which the annotation should be rotate The annotation is rotated as 0 angle. The annotation is rotated as 90 angle. The annotation is rotated as 180 angle. The annotation is rotated as 270 angle. The Syncfusion.Pdf.ColorSpace namespace contains classes for enhanced printing support with various Color channels. Represents a calibrated gray color, based on a CalGray colorspace. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Create Gray ColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Creates GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Class Represents the extended color, based on a complex colorspace. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Create Gray ColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Create GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") To store the Colorspace. Initializes a new instance of the class. The colorspace. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Create Gray ColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Creates GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Gets the Colorspace // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Create Gray ColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; //Get the Color space. PdfColorSpaces colorSpace = gray.ColorSpace; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Creates GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 'Get the Color space Dim colorSpace As PdfColorSpaces = gray.ColorSpace Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Local Variable to store the Gray value. Initializes a new instance of the class. The color space. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); RectangleF rect = new RectangleF(20, 70, 100, 50); // Create Gray ColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page. Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Create Gray ColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Class Gets or sets the gray level for this color. The gray level of this color. The acceptable range for this value is [0.0 1.0]. 0.0 means the darkest color that can be achieved, and 1.0 means the lightest color. To know more about color spaces refer this link . // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Gets the graphics object. PdfGraphics g = page.Graphics; // Created font object PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); RectangleF rect = new RectangleF(20, 70, 100, 50); // Creates GrayColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor red = new PdfCalGrayColor(calGrayCS); red.Gray = 0.2; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle g.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics ' Created font object Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Creates GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim red As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) red.Gray = 0.2 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle g.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Class Represents a CalGray colorspace. // Create a new PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Creates GrayColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Creates GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Represents the base class for all colorspaces. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Set the document`s color spaces as GrayScale doc.ColorSpace = PdfColorSpace.GrayScale; PdfPen pen = new PdfPen(PdfBrushes.Red); // Draws the rectangle page.Graphics.DrawRectangle(pen, new RectangleF(0,0,100,200)); doc.Save("ColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Set the document`s color spaces as GrayScale doc.ColorSpace = PdfColorSpace.GrayScale Dim pen As PdfPen = New PdfPen(PdfBrushes.Red) ' Draws the rectangle page.Graphics.DrawRectangle(pen, New RectangleF(0,0,100,200)) doc.Save("ColorSpace.pdf") Class Interface Interface of the objects that support caching of their internals. Checks whether the object is similar to another object. The object to compare with the current object. True - if the objects have equal internals and can share them, False otherwise. Returns internals of the object. Returns internals of the object. Sets internals to the object. Internals of the object. Internal variable to store the resources. Internal variable to store the internal object. Internal variable to store the color Internals. Internal variable to store the dictionary. Internal variable to store the colorspace. Checks whether the object is similar to another object. The object to compare witht ehcurrent object. True - if the objects have equal internals and can share them, False otherwise. Returns internals of the object. Returns internals of the object. Sets internals to the object. Internals of the object. Gets Pdf primitive representing the font. Local variable to store the White point of this colorspace. Local variable to store the Game value of this colorspace. Local variable to store the black point of this colorspace. Initializes a new instance of the class. // Create a new PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Creates GrayColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Creates GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Initializes the PdfLab Colorspace. Creates PdfCalGray ColorSpace Array PdfCalGray's ColorSpace Array. Gets or sets the black point. An array of three numbers [XB YB ZB] specifying the tristimulus value, in the CIE 1931 XYZ space, of the diffuse black point. Default value: [ 0.0 0.0 0.0 ]. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Create CalGraycolor space PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); calGrayCS.BlackPoint = new double[] { 0.2, 0.3, 0.8 }; // Create new instance for PdfCalGrayColor PdfCalGrayColor red = new PdfCalGrayColor(calGrayCS); red.Gray = 0.2; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Create CalGraycolor space Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() calGrayCS.BlackPoint = New Double() { 0.2, 0.3, 0.8 } ' Create new instance for PdfCalGrayColor Dim red As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) red.Gray = 0.2 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Gets or sets the gamma. The gamma value for the gray component. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Creates gray color space PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Update color values calGrayCS.Gamma = 0.7; // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Creates gray color space Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() ' Update color values calGrayCS.Gamma = 0.7 ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Gets or sets the white point. An array of three numbers [XW YW ZW] specifying the tristimulus value, in the CIE 1931 XYZ space, of the diffuse white point. The numbers XW and ZW must be positive, and YW must be equal to 1.0. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 100, 50); // Create CalGraycolor space PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; PdfPen pen = new PdfPen(gray); PdfBrush brush = new PdfSolidBrush(gray); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalGrayColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 100, 50) ' Create CalGraycolor space Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 Dim pen As PdfPen = New PdfPen(gray) Dim brush As PdfBrush = New PdfSolidBrush(gray) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalGrayColorSpace.pdf") Class Class Class Represents a calibrated RGB color, based on a CalRGB colorspace. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates RedColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; red.Green = 1; red.Blue = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates RedColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 red.Green = 1 red.Blue = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Class Local variable to store the Red Color. Local variable to store the Green Color. Local variable to store the Blue Color. Initializes a new instance of the class. The colorspace // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates RedColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; red.Green = 1; red.Blue = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates RedColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 red.Green = 1 red.Blue = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Class Gets or sets the Blue value. The blue level of this color. The acceptable range for this value is [0.0 1.0]. 0.0 means the darkest color that can be achieved, and 1.0 means the lightest. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates RedColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Blue = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates RedColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Green = 1 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Class Gets or sets the green level for this color. The green level of this color. The acceptable range for this value is [0.0 1.0]. 0.0 means the darkest color that can be achieved, and 1.0 means the lightest color. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates RedColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Green = 1; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates RedColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Green = 1 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Class Gets or sets the red level for this color. The red level of this color. The acceptable range for this value is [0.0 1.0]. 0.0 means the darkest color that can be achieved, and 1.0 means the lightest color. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates RedColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates RedColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Class Representing a CalRGB colorspace. // Create a new PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates RedColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; red.Green = 1; red.Blue = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates RedColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 red.Green = 1 red.Blue = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Local variable to store the Whitepoint of this colorspace. Local variable to store the BlackPoint of this colorspace. Local variable to store the Gama of this colorspace. Local variable to store the Matrix value of this colorspace. Initializes a new instance of the class. // Create a new PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates RedColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; red.Green = 1; red.Blue = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates RedColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 red.Green = 1 red.Blue = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Initializes the PdfCalRGB ColorSpace Creates PdfCalRGB ColorSpace Array PdfCalRGB's ColorSpace Array. Gets or sets the black point. An array of three numbers [XB YB ZB] specifying the tristimulus value, in the CIE 1931 XYZ space, of the diffuse black point. // Create a new PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates redColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.BlackPoint = new double[] { 0.5, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; red.Green = 1; red.Blue = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates redColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.BlackPoint = New Double() { 0.5, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 red.Green = 1 red.Blue = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Gets or sets the gamma. An array of three numbers [GR GG GB] specifying the gamma for the red, green, and blue components of the color space. // Create a new PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates redColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 1.6, 1.1, 2.5 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; red.Green = 1; red.Blue = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draw the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Gets the graphics object. Dim g As PdfGraphics = page.Graphics Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates redColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 1.6, 1.1, 2.5 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 red.Green = 1 red.Blue = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draw the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Gets or sets the colorspace transformation matrix. An array of nine numbers [XA YA ZA XB YB ZB XC YC ZC] specifying the linear interpretation of the decoded A, B, and C components of the color space with respect to the final XYZ representation. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates redColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Matrix = new double[] { 1, 0, 0, 0, 1, 0, 0, 0, 1 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates redColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Matrix = New Double() { 1, 0, 0, 0, 1, 0, 0, 0, 1 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Gets or sets the white point. An array of three numbers [XW YW ZW] specifying the tristimulus value, in the CIE 1931 XYZ space, of the diffuse white point. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); // Creates redColorSpace PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; PdfCalRGBColor red = new PdfCalRGBColor(calRgbCS); red.Red = 0; PdfPen pen = new PdfPen(red); PdfBrush brush = new PdfSolidBrush(red); // Draws the rectangle page.Graphics.DrawRectangle(pen, rect); doc.Save("CalRedColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) ' Creates redColorSpace Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.WhitePoint = New Double() { 0.2, 1, 0.8 } Dim red As PdfCalRGBColor = New PdfCalRGBColor(calRgbCS) red.Red = 0 Dim pen As PdfPen = New PdfPen(red) Dim brush As PdfBrush = New PdfSolidBrush(red) ' Draws the rectangle page.Graphics.DrawRectangle(pen, rect) doc.Save("CalRedColorSpace.pdf") Class Class Class Represents a device colorspace. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[3]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.AlternateColorSpaces = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; PdfBrush brush = new PdfSolidBrush(color); page.Graphics.DrawRectangle(brush, rect); doc.Save("DeviceColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page. Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(2){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.AlternateColorSpaces = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim brush As PdfBrush = New PdfSolidBrush(color) page.Graphics.DrawRectangle(brush, rect) doc.Save("DeviceColorSpace.pdf") Class Class Class Local variable to store the Device Colospace Type. Initializes a new instance of the class. The colorspace. // Create a new PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(20, 70, 200, 100); PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[3]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.AlternateColorSpaces = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; PdfBrush brush = new PdfSolidBrush(color); page.Graphics.DrawRectangle(brush, rect); doc.Save("DeviceColorSpace.pdf"); ' Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() ' Create a page. Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(2){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.AlternateColorSpaces = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim brush As PdfBrush = New PdfSolidBrush(color) page.Graphics.DrawRectangle(brush, rect) doc.Save("DeviceColorSpace.pdf") Class Class Class Gets or sets the DeviceColorSpaceType // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[1]; numArray[0] = 0.38f; function.C1 = numArray; PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); // Creates device color space PdfDeviceColorSpace deviceColorspace1 = new PdfDeviceColorSpace(PdfColorSpace.CMYK); deviceColorspace1.DeviceColorSpaceType = PdfColorSpace.GrayScale; // Set the device color space colorspace.AlternateColorSpaces = deviceColorspace1; colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; PdfBrush brush = new PdfSolidBrush(color); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(brush, rect); doc.Save("DeviceColorSpace.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(0){} numArray(0) = 0.38f [function].C1 = numArray Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() ' Creates device color space Dim deviceColorspace1 As PdfDeviceColorSpace = New PdfDeviceColorSpace(PdfColorSpace.CMYK) deviceColorspace1.DeviceColorSpaceType = PdfColorSpace.GrayScale ' Set the device color space colorspace.AlternateColorSpaces = deviceColorspace1 colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim brush As PdfBrush = New PdfSolidBrush(color) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(brush, rect) doc.Save("DeviceColorSpace.pdf") Class Class Class Represents an ICC color, based on an ICC colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Class Local variable to store the color components. Local variable to store the Alternatic Colorspace of this Color. Initializes a new instance of the class. The colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Class Gets or sets the color components. An array of values that describe the color in the ICC colorspace. The length of this array must match the value of ColorComponents property on the underlying ICC colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Class Gets the Colorspace. Class represents the ICC Colorspace. Used during creation of documents with PDF/A1B compliance. Internal variable to store the stream.. Initializes a new instance of the class. Saves an instance. Handles the BeginSave event of the Stream control. The source of the event. The instance containing the event data. Gets the profile data. bytes Gets the element. Represents an ICC based colorspace.. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Local variable to store the Alternative Colorspaces. Loacal variable to store the Color Components. Local variable to store the Color Profile Data. Local variable to store the Color Range. Local variable to store the internal stream. Initializes a new instance of the class. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Get the default Color Profile. ICC profile data. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create RGB color space. PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); //Set the default ICC profile data. IccBasedCS.ProfileData = IccBasedCS.GetProfileData(); IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); doc.Close(true); 'Creates a new document Dim doc As PdfDocument = New PdfDocument 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add 'Create RGB color space. Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5} 'Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace 'Set the default ICC profile data. IccBasedCS.ProfileData = IccBasedCS.GetProfileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0, 1, 0, 1, 0, 1} Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1} Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") doc.Close(True) Saves an instance. Initializes the PdfICCBased Colorspace. Creates PdfCalGray ColorSpace Array PdfCalGray's ColorSpace Array. Handles the BeginSave event of the Stream control. The source of the event. The instance containing the event data. Gets or sets the alternate color space. The alternate color space to be used in case the one specified in the stream data is not supported. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Gets or sets the color components. The number of color components in the color space described by the ICC profile data. This number must match the number of components actually in the ICC profile. As of PDF 1.4, this value must be 1, 3 or 4. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Gets or sets the profile data. The ICC profile data. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Gets or sets the range for color components. An array of 2 � ColorComponents numbers [ min0 max0 min1 max1 ... ] specifying the minimum and maximum valid values of the corresponding color components. These values must match the information in the ICC profile. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Read the ICC profile from disk. FileStream fs = new FileStream("rgb.icc", FileMode.Open, FileAccess.Read); byte[] profileData = new byte[fs.Length]; fs.Read(profileData, 0, profileData.Length); fs.Close(); PdfCalRGBColorSpace calRgbCS = new PdfCalRGBColorSpace(); calRgbCS.Gamma = new double[] { 7.6, 5.1, 8.5 }; // Creating instance for ICCColorSpace PdfICCColorSpace IccBasedCS = new PdfICCColorSpace(); IccBasedCS.ProfileData = profileData; IccBasedCS.AlternateColorSpace = calRgbCS; IccBasedCS.ColorComponents = 3; IccBasedCS.Range = new double[] { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 }; PdfICCColor iccColorSpace = new PdfICCColor(IccBasedCS); iccColorSpace.ColorComponents = new double[] { 1, 0, 1 }; PdfPen pen = new PdfPen(iccColorSpace); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("ICCColorCS.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Read the ICC profile from disk. Dim fs As FileStream = New FileStream("rgb.icc", FileMode.Open, FileAccess.Read) Dim profileData() As Byte = New Byte(fs.Length - 1){} fs.Read(profileData, 0, profileData.Length) fs.Close() Dim calRgbCS As PdfCalRGBColorSpace = New PdfCalRGBColorSpace() calRgbCS.Gamma = New Double() { 7.6, 5.1, 8.5 } ' Creating instance for ICCColorSpace Dim IccBasedCS As PdfICCColorSpace = New PdfICCColorSpace() IccBasedCS.ProfileData = profileData IccBasedCS.AlternateColorSpace = calRgbCS IccBasedCS.ColorComponents = 3 IccBasedCS.Range = New Double() { 0.0, 1.0, 0.0, 1.0, 0.0, 1.0 } Dim iccColorSpace As PdfICCColor = New PdfICCColor(IccBasedCS) iccColorSpace.ColorComponents = New Double() { 1, 0, 1 } Dim pen As PdfPen = New PdfPen(iccColorSpace) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("ICCColorCS.pdf") Class Class Class Class Represents an indexed color, based on an indexed colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Class Local variable to store the color index. Initializes a new instance of the class. The colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Class Gets or sets the color index The index of the select color. The acceptable range for this value is 0 - MaxColorIndex. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Class Represents an indexed colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Local variable to store the base colorspace. Local variable to store the maximum Color Index. Local variable to store the indexed Color Table. Local variable to store the stream. Initializes a new instance of the class. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Gets the profile data. The profile data. Saves an instance. Initializes the PdfICCBased Colorspace. Creates PdfCalGray ColorSpace Array PdfCalGray's ColorSpace Array. Handles the BeginSave event of the Stream control. The source of the event. The instance containing the event data. Gets or sets the base colorspace. The color space in which the values in the color table are to be interpreted. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Gets or sets the index of the max color. The maximum index that can be used to access the values in the color table. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Gets or sets the color table. The table of color components. The color table data must be m * (maxIndex + 1) bytes long, where m is the number of color components in the base color space. Each byte is an unsigned integer in the range 0 to 255 that is scaled to the range of the corresponding color component in the base color space; that is, 0 corresponds to the minimum value in the range for that component, and 255 corresponds to the maximum. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates indexed color space PdfIndexedColorSpace colorspace = new PdfIndexedColorSpace(); colorspace.BaseColorSpace = new PdfDeviceColorSpace(PdfColorSpace.RGB); colorspace.MaxColorIndex = 3; colorspace.IndexedColorTable = new byte[] { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 }; // Creates index color PdfIndexedColor color = new PdfIndexedColor(colorspace); color.SelectColorIndex = 3; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("IndexedColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates indexed color space Dim colorspace As PdfIndexedColorSpace = New PdfIndexedColorSpace() colorspace.BaseColorSpace = New PdfDeviceColorSpace(PdfColorSpace.RGB) colorspace.MaxColorIndex = 3 colorspace.IndexedColorTable = New Byte() { 150, 0, 222, 255, 0, 0, 0, 255, 0, 0, 0, 255 } ' Creates index color Dim color As PdfIndexedColor = New PdfIndexedColor(colorspace) color.SelectColorIndex = 3 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("IndexedColor.pdf") Class Class Class Class Represents a calibrated Lab color, based on a Lab colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Local variable to store the A value. Local variable to store the B value. Local variable to store the L value. Initializes a new instance of the class. The ColorSpace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Gets or sets the a* component for this color. The a* component of this color. The range for this value is defined by the Range property of the underlying Lab colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Gets or sets the b* component for this color. The b* component of this color. The range for this value is defined by the Range property of the underlying Lab colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Gets or sets the l component for this color. The l component of this color. The acceptable range for this value is [0.0 100.0]. 0.0 means the darkest color that can be achieved, and 100.0 means the lightest color. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Represents a Lab colorspace // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Local variable to store the WhitePoint. Local variable to store the BlackPoint Local variable to store the Range Initializes a new instance of the class. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Initializes the PdfLab Colorspace. Creates PdfLab colorspace Array PdfLab's colorspace Array. Gets or sets BlackPoint An array of three numbers [XB YB ZB] specifying the tristimulus value, in the CIE 1931 XYZ space, of the diffuse black point. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.BlackPoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.BlackPoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Gets or sets the Range An array of three numbers [XB YB ZB] specifying the tristimulus value, in the CIE 1931 XYZ space, of the diffuse black point. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Gets or sets the white point An array of three numbers [XW YW ZW] specifying the tristimulus value, in the CIE 1931 XYZ space, of the diffuse white point. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Create lab color space PdfLabColorSpace calGrayCS = new PdfLabColorSpace(); calGrayCS.Range = new double[] { 0.2, 1, 0.8, 23.5 }; calGrayCS.WhitePoint = new double[] { 0.2, 1, 0.8 }; // Create lab color PdfLabColor labColor = new PdfLabColor(calGrayCS); labColor.L = 90; labColor.A = 0.5; labColor.B = 20; PdfPen pen = new PdfPen(labColor); RectangleF rect = new RectangleF(20, 70, 200, 100); page.Graphics.DrawRectangle(pen, rect); doc.Save("LabColor.pdf"); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates lab color space Dim calGrayCS As PdfLabColorSpace = New PdfLabColorSpace() calGrayCS.Range = New Double() { 0.2, 1, 0.8, 23.5 } calGrayCS.WhitePoint = New Double() { 0.2, 1, 0.8 } ' Create lab color Dim labColor As PdfLabColor = New PdfLabColor(calGrayCS) labColor.L = 90 labColor.A = 0.5 labColor.B = 20 Dim pen As PdfPen = New PdfPen(labColor) Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) page.Graphics.DrawRectangle(pen, rect) doc.Save("LabColor.pdf") Class Class Class Represents a separation color, based on a separation colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Class Local variable to store the tint value. Initializes a new instance of the class. The colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Class Gets or sets the Tint Value. A float value specifying the tint of this color. The acceptable range for this value is [0.0 1.0]. 0.0 means the lightest color that can be achieved, and 1.0 means the darkest color. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Class Represents a separation colorspace // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Local variable to store the Coloring. Local variable to store teh Pdffuncion. Local variable to store the internal stream. Local variable to store the Alternative Colorspaces. Initializes a new instance of the class. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Get the profile data. The profile data Saves an instance. Initializes the PdfICCBased Colorspace. Creates PdfCalGray ColorSpace Array PdfCalGray's ColorSpace Array. Handles the BeginSave event of the Stream control. The source of the event. The instance containing the event data. Gets or sets the alternate color spaces. The alternate color space to be used when the destination device does not support separation colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.AlternateColorSpaces = new PdfDeviceColorSpace(PdfColorSpace.GrayScale); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.AlternateColorSpaces = New PdfDeviceColorSpace(PdfColorSpace.GrayScale) colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Gets or sets the colorant represented by this separation colorspace. The name of the colorant. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.AlternateColorSpaces = new PdfDeviceColorSpace(PdfColorSpace.GrayScale); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.AlternateColorSpaces = New PdfDeviceColorSpace(PdfColorSpace.GrayScale) colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Gets or sets the tint transform function for the this colorspace. Tint transform function for the colorspace. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Creates ExponentialInterpolationFunction function PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true); float[] numArray = new float[4]; numArray[0] = 0.38f; numArray[1] = 0.88f; function.C1 = numArray; // Creates SeparationColorSpace PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace(); colorspace.AlternateColorSpaces = new PdfDeviceColorSpace(PdfColorSpace.GrayScale); colorspace.TintTransform = function; colorspace.Colorant = "PANTONE Orange 021 C"; PdfSeparationColor color = new PdfSeparationColor(colorspace); color.Tint = 0.7; RectangleF rect = new RectangleF(20, 70, 200, 100); PdfPen pen = new PdfPen(color); page.Graphics.DrawRectangle(pen, rect); doc.Save("SeparationColor.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() ' Creates ExponentialInterpolationFunction function Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True) Dim numArray() As Single = New Single(3){} numArray(0) = 0.38f numArray(1) = 0.88f [function].C1 = numArray ' Creates SeparationColorSpace Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace() colorspace.AlternateColorSpaces = New PdfDeviceColorSpace(PdfColorSpace.GrayScale) colorspace.TintTransform = [function] colorspace.Colorant = "PANTONE Orange 021 C" Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace) color.Tint = 0.7 Dim rect As RectangleF = New RectangleF(20, 70, 200, 100) Dim pen As PdfPen = New PdfPen(color) page.Graphics.DrawRectangle(pen, rect) doc.Save("SeparationColor.pdf") Class Class Class Class for default compressor. Default compressor does not compress data. Summary description of IPDFCompressor. Compresses bytes data. Bytes data. Compressed bytes data. Compresses string data. String data. Compressed string data. Compresses stream data. Stream data. Compressed streams data. Decompresses string data. String data. Decompressed bytes data. Decompresses bytes data. Bytes data. Decompressed bytes data. Decompresses stream data. Stream data. Decompressed stream data. Gets the compressor type. Gets the compressor name in PDF format. Initializes a new instance of the class. Compresses bytes data. Bytes data that should be compressed. Compressed bytes data. Compresses stream data. Stream data that should be compressed. Compressed streams data. Compresses string data. String data that should be compressed. Compressed string data. Decompresses string data. String data that should be decompressed. Decompressed bytes data. Decompresses bytes data. Bytes data that should be decompressed. Decompressed bytes data. Decompresses stream data. Stream data that should be decompressed. Decompressed stream data. Gets the name of the compressor in PDF format. Gets the type of the compressor. Compresses the TIFF using JBIG2 encoder. Read Pix information for the image. Read pix information from Tiff. Create Pix from the tiff. Swap bytes for Little Endian byte order. Swap bytes for Little Endian byte order. Read Tiff compression format. Read file format. Initialize encoder. Initialize encoder context. Produces symbol. Classify and record information about a page. Adds page. Finds image components. Filter. Gets the value from the array. Adds number and extends the array. Returns Box rectangle. Returns Pixa Return pix with dilated word mask. Sequence of binary rasterop morphological operations. Replicated integer expansion. Replicated expansion integer scaling. Power of 2 expansion. Binary morphological (raster) ops with brick Sels. Removes border of the pix. Pix with pixels removed around border. Adds border to the pix. Adds border to the pix. Binary morphological (raster) ops with brick Sels. Binary morphological (raster) ops with brick Sels. Image display for debugging. Image display for debugging. Top level scaling dispatcher. Top level scaling dispatcher without sharpening. Linearly interpreted (up) scaling. Color interpolated scaling. Linearly interpreted (up) scaling. Linearly interpreted (up) scaling. Color interpolated scaling: 2x upscaling. Color interpolated scaling: 2x upscaling. Linearly interpreted (up) scaling. Grayscale interpolated scaling 4x upscaling. Grayscale interpolated scaling. Linearly interpreted (up) scaling. Grayscale interpolated scaling: 2x upscaling. Unsharp masking. Full image set to arbitrary value Grayscale block convolution Grayscale Block Convolution Accumulator for 1, 8 and 32 bpp convolution Grayscale block convolution. Unsharp masking. Unsharp masking. Unsharp masking. Assign border pixels. Downscaling with (antialias) area mapping. Color and grayscale downsampling with (antialias) area mapping. Color and grayscale downsampling with (antialias) area mapping. Downscaling with (antialias) area mapping. 2x area mapped downscaling. Top-level conversion to 8 or 32 bpp, without colormap. Top level conversion to 8 bpp. Conversion from RGB color to grayscale. Conversion from RGB color to grayscale. Convert colored image to grayscale. Add colormap losslessly (8 to 8). Colormap creation. Unpacking conversion from 1, 2 and 4 bpp to 8 bpp. Unpacking conversion from 1, 2 and 4 bpp to 8 bpp. Colormap creation. Colormap creation and addition. Conversion from 1, 2 and 4 bpp to 8 bpp. Binary scaling by closest pixel sampling. Binary scaling by closest pixel sampling. Scale-to-gray (1 bpp --> 8 bpp; integer downscaling). Scale to gray 2x. Returns an 8 bit value for the sum of ON pixels in a 2x2 square. Table of 256 uint. Scale-to-gray (1 bpp --> 8 bpp; integer downscaling). Scale to gray 3x. Returns an 8 bit value for the sum of ON pixels in a 3x3 square. Table of 64 uint. Pix scaled down by 4x in each direction. Scale to gray 4x. 8 bit value for the sum of ON pixels in a 4x4 square. Table of 256 uint. Scale-to-gray (1 bpp --> 8 bpp; integer downscaling). Scale to gray 8x. Scale to gray 8x. Table of integers. Conversion from 16 bpp to 8 bpp. Binary morphological (raster) ops with brick Sels. Erodes source Pix using hits in Sel. Max translations for erosion and hmt. Sets all data to 1. Helpers for arg processing. Reallocate image data if sizes are different. Binary morphological (raster) ops with brick Sels. Creates rectangular sel of all hits, misses or don't cares. Generic binary morphological ops implemented with rasterop. Full image clear to arbitrary value. Parser verifier for binary morphological operations. Rank filtered binary reductions. Pix is downscaled by 2x from source Low level subsampled reduction This table permutes the bits in a byte. Returns pix at the index. Gets bounding boxes or Pixa of the components. Adds Pix Doubles the size of the pixa and boxa ptr arrays. Doubles the size of the pixa and boxa ptr arrays. Copies Boxa. Returns Box at the specified index. Extract retangular region. Clip box to the rectangle Finds bounding boxes of 4 or 8 connected components in a binary image. Adds Box. Doubles the size of the boxa ptr array. Stack based Seed fill algorithm. Stack based 4 connected components seedfill algorithm. Stack based 8 connected component seedfill algorithm. Removes line segment. Stack helper functions. Identify the connection component to be erased. Identify the connected component to be erased. Pixel counting. For a binary image, if there are no black pixels, returns 1. For a grayscale image, if all pixels are black, returns 1. For an RGB image, if all 4 components in every pixel is 0, returns 1. Low level power of 2 binary expansion Expansion tables for 8x expansion. Expansion tables for 2x expansion. Expansion tables for 4x expansion. Pixelwise binarization with fixed threshold. Binarization with fixed threshold. Simple pixelwise binarization. 4x upscale Pix, using linear interpolation, followed by thresholding to binary. 2x upscale Pix, using linear interpolation, followed by thresholding to binary. Grayscale interpolated scaling: 2x upscaling. Scales resolution of the Pix Removes colormap for the Pix. General raster operation. Scales width, performs clipping, checks alignment, and dispatches for the rasterop. Rasterop without vertical word alignment. Rasterop with vertical word alignment. Rasterop with vertical word alignment. Scales width, performs clipping, checks alignment, and dispatches for the rasterop. Low level uni rasterop. Dest rect is left aligned on (32-bit) word boundaries. Color sample setting and extraction. Creates Pix. Reads color for colormap. Copy Pix. Creates Pix of the same size as the input Pix. Creates Pix of the same size as the input Pix. Copies colormap from source Pix. Copies resolution from source Pix. Creates Pix. Create Pix. Checks if Colormap has color. Read colormap array. Regenerated line info. No errors detected. Receiver regenerated lines. Uncorrected errors exist. Compression scheme. Dump mode. CCITT modified Huffman RLE. CCITT Group 3 fax encoding. CCITT T.4 (TIFF 6 name for CCITT Group 3 fax encoding). CCITT Group 4 fax encoding. CCITT T.6 (TIFF 6 name for CCITT Group 4 fax encoding). Lempel-Ziv & Welch. Original JPEG / Old-style JPEG (6.0). JPEG DCT compression. NeXT 2-bit RLE. CCITT RLE. Macintosh RLE. ThunderScan RLE. IT8 CT w/padding. Reserved for ANSI IT8 TIFF/IT. IT8 Linework RLE. Reserved for ANSI IT8 TIFF/IT. IT8 Monochrome picture. Reserved for ANSI IT8 TIFF/IT. IT8 Binary line art. Reserved for ANSI IT8 TIFF/IT. Pixar companded 10bit LZW. Reserved for Pixar. Pixar companded 11bit ZIP. Reserved for Pixar. Deflate compression. Deflate compression, as recognized by Adobe. Kodak DCS encoding. ISO JBIG. SGI Log Luminance RLE. SGI Log 24-bit packed. Leadtools JPEG2000. Information about extra samples. Unspecified data. Associated alpha data. Unassociated alpha data. Group 3/4 format control. Default, include RTC. No RTC at end of data. No EOL code at end of row. Byte align row. Word align row. TIFF Class F. Subfile data descriptor. Reduced resolution version. One page of many. Transparency mask. Data order within a byte. Most significant -> least. Least significant -> most. Options for CCITT Group 3/4 fax encoding. Unknown (uninitialized). 2-dimensional coding. Data not compressed. Fill to byte boundary. Inks in separated image. Cyan-magenta-yellow-black color. Multi-ink or hi-fi color. Auto RGB<=>YCbCr convert. No conversion (default). Do auto conversion. Jpeg Tables Mode. None. Include quantization tables. Include Huffman tables. Kind of data in subfile. Full resolution image data. Reduced size image data. One page of many. Image orientation. Row 0 top, Column 0 lhs. Row 0 top, Column 0 rhs. Row 0 bottom, Column 0 rhs. Row 0 bottom, Column 0 lhs. Row 0 lhs, Column 0 top. Row 0 rhs, Column 0 top. Row 0 rhs, Column 0 bottom. Row 0 lhs, Column 0 bottom. Photometric interpretation. Min value is white. Min value is black. RGB color model. Color map indexed. [obsoleted by TIFF rev. 6.0] Holdout mask. Color separations. CCIR 601. 1976 CIE L*a*b*. ICC L*a*b*. Introduced post TIFF rev 6.0 by Adobe TIFF Technote 4. ITU L*a*b*. CIE Log2(L). CIE Log2(L) (u',v'). Storage organization. Unknown (uninitialized). Single image plane. Separate planes of data. Prediction scheme w/ LZW. No prediction scheme used. Horizontal differencing. Floating point predictor. Units of resolutions. No meaningful units. English. Metric. Data sample format. Unsigned integer data Signed integer data IEEE floating point data Untyped data Complex signed int Complex ieee floating Thresholding used on data. B&W art scan. Dithered scan. Usually Floyd-Steinberg. Tag data type. Placeholder. For field descriptor searching. 8-bit unsigned integer. 8-bit bytes with last byte null. 16-bit unsigned integer. 32-bit unsigned integer. 64-bit unsigned fraction. 8-bit signed integer. 8-bit untyped data. 16-bit signed integer. 32-bit signed integer. 64-bit signed fraction. 32-bit IEEE floating point. 64-bit IEEE floating point. 32-bit unsigned integer (offset) Subsample positioning. As in PostScript Level 2 As in CCIR 601-1 TIFF tag definitions. Tag placeholder Subfile data descriptor. For the list of possible values, see . Kind of data in subfile. For the list of possible values, see . Image width in pixels. Image height in pixels. Bits per channel (sample). Data compression technique. For the list of possible values, see . Photometric interpretation. For the list of possible values, see . Thresholding used on data. For the list of possible values, see . Dithering matrix width. Dithering matrix height. Data order within a byte. Name of document which holds for image. Information about image. Scanner manufacturer name. Scanner model name/number. Offsets to data strips. Image orientation. For the list of possible values, see . Samples per pixel. Rows per strip of data. Bytes counts for strips. Minimum sample value. Maximum sample value. Pixels/resolution in x. Pixels/resolution in y. Storage organization. For the list of possible values, see . Page name image is from. X page offset of image lhs. Y page offset of image lhs. Byte offset to free block. Sizes of free blocks. Gray scale curve accuracy. Gray scale response curve. Options for CCITT Group 3 fax encoding. 32 flag bits. Options for CCITT Group 4 fax encoding. 32 flag bits. Units of resolutions. Page numbers of multi-page. Color curve accuracy. Colorimetry info. Name & release. Creation date and time. Creator of image. Machine where created. Prediction scheme w/ LZW. Image white point. Primary chromaticities. RGB map for pallette image. Highlight + shadow info. Tile width in pixels. Tile height in pixels. Offsets to data tiles. Byte counts for tiles. Lines with wrong pixel count. Regenerated line info. Max consecutive bad lines. Subimage descriptors. Inks in separated image. ASCII names of inks. Number of inks. 0% and 100% dot codes. Separation target. Information about extra samples. Data sample format. Variable MinSampleValue. Variable MaxSampleValue. ClipPath. XClipPathUnits. YClipPathUnits. Indexed. JPEG table stream. OPI Proxy. JPEG processing algorithm. Pointer to SOI marker. JFIF stream length Restart interval length. Lossless proc predictor. Lossless point transform. Q matrice offsets. DCT table offsets. AC coefficient offsets. RGB -> YCbCr transform. YCbCr subsampling factors. Subsample positioning. Colorimetry info. XML packet. OPI ImageID. Image reference points. Region-xform tack point. Warp quadrilateral. Affine transformation matrix. Use EXTRASAMPLE tag. Use SAMPLEFORMAT tag. Z depth of image. Z depth/data tile. Full image size in X. Full image size in Y. Texture map format. S&T wrap modes. Cotan(fov) for env. maps. Used to identify special image modes and data used by Pixar's texture formats. Used to identify special image modes and data used by Pixar's texture formats. Device serial number. Copyright string. IPTC TAG from RichTIFF specifications. Site name. Color seq. [RGB, CMYK, etc]. DDES Header. Raster scanline padding. The number of bits in short run. The number of bits in long run. LW colortable. BP/BL image color switch. BP/BL bg color switch. BP/BL image color value. BP/BL bg color value. MP pixel intensity value. HC transparency switch. Color characterization table. HC usage indicator. Trapping indicator (untrapped = 0, trapped = 1). CMYK color equivalents. Sequence Frame Count. Pointer to EXIF private directory. ICC profile data. JBIG options. Pointer to GPS private directory. Encoded Class 2 ses. params. Received SubAddr string. Receive time (secs). Encoded fax ses. params, Table 2/T.30. Sample value to Nits. Pointer to Interoperability private directory. DNG version number. DNG compatibility version. Name for the camera model. Localized camera model name. CFAPattern->LinearRaw space mapping. Spatial layout of the CFA. Lookup table description. Repeat pattern size for the BlackLevel tag. Zero light encoding level. Zero light encoding level differences (columns). Zero light encoding level differences (rows). Fully saturated encoding level. Default scale factors. Origin of the final image area. Size of the final image area. XYZ->reference color space transformation matrix 1. XYZ->reference color space transformation matrix 2. Calibration matrix 1. Calibration matrix 2. Dimensionality reduction matrix 1. Dimensionality reduction matrix 2. Gain applied the stored raw values. Selected white balance in linear reference space. Selected white balance in x-y chromaticity coordinates. How much to move the zero point. Relative noise level. Relative amount of sharpening. How closely the values of the green pixels in the blue/green rows track the values of the green pixels in the red/green rows. Non-linear encoding range. Camera's serial number. Information about the lens. Chroma blur radius. Relative strength of the camera's anti-alias filter. Used by Adobe Camera Raw. Manufacturer's private data. Whether the EXIF MakerNote tag is safe to preserve along with the rest of the EXIF data. Illuminant 1. Illuminant 2. Best quality multiplier. Unique identifier for the raw image data. File name of the original raw file. Contents of the original raw file. Active (non-masked) pixels of the sensor. List of coordinates of fully masked pixels. Used to map cameras's color space into ICC profile space. Used to map cameras's color space into ICC profile space. Undefined tag used by Eastman Kodak, hue shift correction data. Group 3/4 format control. Compression quality level. Quality level is on the IJG 0-100 scale. Default value is 75. Auto RGB<=>YCbCr convert. Default is | . G3/G4 fill function. PixarLogCodec I/O data sz. Imager mode & filter. Interpolation mode. Color balance values. Color correction values. Gamma value. Toe & shoulder points. Calibration file description. Compression quality level. Quality level is on the ZLIB 1-9 scale. Default value is -1. PixarLog uses same scale. Area of image to acquire. SGILog user data format. SGILog data encoding control. Exposure time. F number. Exposure program. Spectral sensitivity. ISO speed rating. Optoelectric conversion factor. Exif version. Date and time of original data generation. Date and time of digital data generation. Meaning of each component. Image compression mode. Shutter speed. Aperture. Brightness. Exposure bias. Maximum lens aperture. Subject distance. Metering mode. Light source. Flash. Lens focal length. Subject area. Manufacturer notes. User comments. DateTime subseconds. DateTimeOriginal subseconds. DateTimeDigitized subseconds. Supported Flashpix version. Color space information. Valid image width. Valid image height. Related audio file. Flash energy. Spatial frequency response. Focal plane X resolution. Focal plane Y resolution. Focal plane resolution unit. Subject location. Exposure index. Sensing method. File source. Scene type. CFA pattern. Custom image processing. Exposure mode. White balance. Digital zoom ratio. Focal length in 35 mm film. Scene capture type. Gain control. Contrast. Saturation. Sharpness. Device settings description. Subject distance range. Unique image ID. The unit of density. Unknown density Dots/inch Dots/cm Known color spaces. Unspecified color space. Grayscale RGB YCbCr (also known as YUV) CMYK YCbCrK Algorithm used for the DCT step. Slow but accurate integer algorithm. Faster, less accurate integer method. Floating-point method. Dithering options for decompression. No dithering: fast, very low quality Ordered dither: moderate speed and quality Floyd-Steinberg dither: slow, high quality Message codes used in code to signal errors, warning and trace messages. Must be first entry! Describes a result of read operation. Suspended due to lack of input data. Can occur only if a suspending data source is used. Found valid image datastream. Found valid table-specs-only datastream. Reached a SOS marker (the start of a new scan) Reached the EOI marker (end of image) Completed reading one MCU row of compressed data. Completed reading last MCU row of current scan. JPEG marker codes. Operating modes for buffer controllers Use MSB2LSB (most significant -> least) fill order Use LSB2MSB (least significant -> most) fill order natural bit fill order for machine current directory must be written data buffers setup encoder/decoder setup done written 1+ scanlines to file byte swap file information inhibit bit reversal logic my raw data buffer; free on close file is tile, not strip- based need call to postencode routine currently writing a subifd library is doing data up-sampling enable strip chopping support read header only, do not process the first directory skip reading of raw uncompressed image data Field bits (flags) for tags. This value is used to signify custom tags. This value is used as a base (starting) value for codec-private tags. Last usable value for field bit. All tags values should be less than this value. Holds a value of a Tiff tag. Retrieves value converted to byte. Retrieves value converted to short. Retrieves value converted to ushort. Retrieves value converted to int. Retrieves value converted to uint. Retrieves value converted to float. Retrieves value converted to double. Retrieves value converted to string. Retrieves value converted to byte array. Retrieves value converted to array of bytes. Retrieves value converted to array of short values. Retrieves value converted to array of ushort values. Retrieves value converted to array of int values. Retrieves value converted to array of uint values. Retrieves value converted to array of float values. Retrieves value converted to array of double values. Gets the value. The value. Base class for all codecs within the library. An instance of . Compression scheme this codec impelements. Codec name. Initializes a new instance of the class. Initializes this instance. Setups the decoder part of the codec. Prepares the decoder part of the codec for a decoding. Decodes one row of image data. Decodes one strip of image data. Decodes one tile of image data. Flushes any internal data buffers and terminates current operation. Seeks the specified row in the strip being processed. Cleanups the state of the codec. Calculates and/or constrains a strip size. Calculate and/or constrains a tile size Gets a value indicating whether this codec can decode data. Prepares the decoder part of the codec for a decoding. Decodes one row of image data. Decodes one strip of image data. Decodes one tile of image data. Flushes any internal data buffers and terminates current operation. Cleanups the state of the codec. Decode the requested amount of G3 1D-encoded data. Decode the requested amount of G3 2D-encoded data. Decode the requested amount of RLE-encoded data. Decode the requested amount of G4-encoded data. Gets a value indicating whether this codec can decode data. Tiff tag methods. untyped data signed integer data unsigned integer data IEEE floating point data Sets the value(s) of a tag in a TIFF file/stream open for writing. Gets the value(s) of a tag in an open TIFF file. Install extra samples information. predictor tag value sample stride over data tile/strip row size horizontal differencer/accumulator Setups the decoder part of the codec. Decodes one row of image data. Decodes one tile of image data. Floating point predictor accumulation routine. Floating point predictor differencing routine. Decode a scanline and apply the predictor routine. Decode a tile/strip and apply the predictor routine. Note that horizontal differencing must be done on a row-by-row basis. The width of a "row" has already been calculated at pre-decode time according to the strip/tile dimensions. Prepares the decoder part of the codec for a decoding. Cleanups the state of the codec. Gets a value indicating whether this codec can decode data. Decodes one row of image data. Decodes one strip of image data. Decodes one tile of image data. Seeks the specified row in the strip being processed. Decode a hunk of pixels. Gets a value indicating whether this codec can decode data. Tag Image File Format (TIFF) undefined state undefined state name of open file open mode (O_*) file offset of current directory internal rep of current directory current scanline current strip for read/write current tile for read/write # of bytes in a tile # of bytes in a scanline raw data buffer # of bytes in raw data buffer current spot in raw buffer bytes unread from raw buffer callback parameter post decoding method type tag get/set/print routines file offset of following directory list of offsets to already seen directories to prevent IFD looping number of entires in offset list number of already seen directories file's header block data type shift counts data type masks current directory (index) current offset for read/write current offset for writing dir remaining subifds to write offset for patching SubIFD link current column (offset by row too) sorted table of registered tags # entries in registered tag table cached pointer to already found tag extra client information. stream used for read|write|etc. post decoding routine Compression schemes statically built into the library. Checks the directory offset against the list of already seen directory offsets. Reads IFD structure from the specified offset. Fetches a contiguous directory item. Fetches an ASCII item from the file. Fetch a single floating point value from the offset field and return it as a native float. Fetches an array of BYTE or SBYTE values. Fetch an array of SHORT or SSHORT values. Fetches an array of LONG or SLONG values. Fetch an array of RATIONAL or SRATIONAL values. Fetches an array of FLOAT values. Fetches an array of DOUBLE values. Fetches an array of ANY values. Fetches a tag that is not handled by special case code. Fetches samples/pixel short values for the specified tag and verify that all values are the same. Fetches samples/pixel long values for the specified tag and verify that all values are the same. Fetches samples/pixel ANY values for the specified tag and verify that all values are the same. Fetches a set of offsets or lengths. Fetches and sets the RefBlackWhite tag. Replace a single strip (tile) of uncompressed data with multiple strips (tiles), each approximately 8Kbytes. Set state to appear as if a strip has just been read in. Read the specified strip and setup for decoding. The data buffer is expanded, as necessary, to hold the strip's data. Read the specified tile and setup for decoding. The data buffer is expanded, as necessary, to hold the tile's data. Retrieves the codec registered for the specified compression scheme. Checks whether library has working codec for the specific compression scheme. Initializes new instance of class and opens a TIFF file for reading or writing. Initializes new instance of class and opens a stream with TIFF data for reading or writing. Closes a previously opened TIFF file. Frees and releases all resources allocated by this . Merges given field information to existing one. Retrieves field information for the specified tag. Retrieves field information for the tag with specified name. Retrieves field information for the specified tag. Gets the value(s) of a tag in an open TIFF file. Gets the value(s) of a tag in an open TIFF file or default value(s) of a tag if a tag is not defined in the current directory and it has a default value(s). Reads the contents of the next TIFF directory in an open TIFF file/stream and makes it the current directory. Reads a custom directory from the arbitrary offset within file/stream. Calculates the size in bytes of a row of data as it would be returned in a call to , or as it would be expected in a call to . Computes the number of bytes in a row-aligned strip. Computes the number of bytes in a row-aligned strip with specified number of rows. Computes the number of bytes in a raw (i.e. not decoded) strip. Retrives the number of strips in the image. Compute the number of bytes in a row-aligned tile. Computes the number of bytes in a row-aligned tile with specified number of rows. Compute the number of bytes in each row of a tile. Computes which tile contains the specified coordinates (x, y, z, plane). Checks whether the specified (x, y, z, plane) coordinates are within the bounds of the image. Retrives the number of tiles in the image. Gets the value indicating whether the image data of this has a tiled organization. Gets the value indicating whether the image data returned through the read interface methods is being up-sampled. Gets the tiff stream. Sets up the data buffer used to read raw (encoded) data from a file. Setups the strips. Releases storage associated with current directory. Sets the value(s) of a tag in a TIFF file/stream open for writing. Reads and decodes a scanline of data from an open TIFF file/stream. Reads and decodes a scanline of data from an open TIFF file/stream. Gets the number of bytes occupied by the item of given type. Swaps the bytes in a single 16-bit item. Swaps the bytes in a single 32-bit item. Swaps the bytes in specified number of values in the array of 16-bit items. Swaps the bytes in specified number of values in the array of 16-bit items starting at specified offset. Swaps the bytes in specified number of values in the array of triples (24-bit items) starting at specified offset. Swaps the bytes in specified number of values in the array of 32-bit items. Swaps the bytes in specified number of values in the array of 32-bit items starting at specified offset. Swaps the bytes in specified number of values in the array of double-precision floating-point numbers. Swaps the bytes in specified number of values in the array of double-precision floating-point numbers starting at specified offset. Replaces specified number of bytes in with the equivalent bit-reversed bytes. Replaces specified number of bytes in with the equivalent bit-reversed bytes starting at specified offset. Retrieves a bit reversal table. Converts a byte buffer into array of 32-bit values. Converts array of 32-bit values into array of bytes. Converts a byte buffer into array of 16-bit values. Converts array of 16-bit values into array of bytes. Delegate for LibTiff.Net extender method Delegate for a method used to image decoded spans. Setups the decoder part of the codec. Prepares the decoder part of the codec for a decoding. Decodes one row of image data. Decodes one strip of image data. Decodes one tile of image data. Cleanups the state of the codec. Calculates and/or constrains a strip size. Calculate and/or constrains a tile size Decode a chunk of pixels. "Standard" case: returned data is not downsampled. Decode a chunk of pixels. Gets a value indicating whether this codec can decode data. JPEG library source data manager. Data source object for decompression. Initializes this instance. Fills input buffer Initializes the internal buffer. Skip data - used to skip over a potentially large amount of uninteresting data (such as an APPn marker). This is the default resync_to_restart method for data source managers to use if they don't have any better approach. Terminate source - called by jpeg_finish_decompress after all data has been read. Often a no-op. Reads two bytes interpreted as an unsigned 16-bit integer. Read a byte into variable V. If must suspend, take the specified action (typically "return false"). Gets the bytes. Functions for fetching data from the data source module. Alternate source manager for reading from JPEGTables. Prepares the decoder part of the codec for a decoding. Cleanups the state of the codec. Gets a value indicating whether this codec can decode data. Setups the decoder part of the codec. Prepares the decoder part of the codec for a decoding. Decodes one row of image data. Decodes one strip of image data. Decodes one tile of image data. Cleanups the state of the codec. Gets a value indicating whether this codec can decode data. Initializes this instance. Fills input buffer Skip data - used to skip over a potentially large amount of uninteresting data (such as an APPn marker). This is the default resync_to_restart method for data source managers to use if they don't have any better approach. Terminate source - called by jpeg_finish_decompress after all data has been read. Often a no-op. Decodes one row of image data. Decodes one strip of image data. Decodes one tile of image data. Gets a value indicating whether this codec can decode data. Internal format of a TIFF directory entry. bit vector of fields that are set size of offset and bytecount arrays is the bytecount array sorted ascending? number of items; length in spec byte offset to field data magic number (defines byte order) TIFF version number byte offset to first directory Base class for both JPEG compressor and decompresor. Base constructor. Creates the array of samples. Creates the array of blocks. Creates 2-D sample array. Gets a value indicating whether this instance is Jpeg decompressor. Progress monitor. JPEG decompression routine. Initializes a new instance of the class. Sets input stream. Decompression startup: this will read the source datastream header markers, up to the beginning of the compressed data proper. Decompression initialization. Read some scanlines of data from the JPEG decompressor. Finish JPEG decompression. Alternate entry point to read raw data. Is there more than one scan? Initialize for an output pass in buffered-image mode Finish up after an output pass in buffered-image mode. Indicates if we have finished reading the input file. Consume data in advance of what the decompressor requires. Pre-calculate output image dimensions and related values for current decompression parameters. Read or write the raw DCT coefficient arrays from a JPEG file (useful for lossless transcoding). Aborts processing of a JPEG decompression operation. Sets processor for special marker. Control saving of COM and APPn markers into Marker_list. Determine whether merged upsample/color conversion should be used. Initialization of JPEG compression objects. Master selection of decompression modules for transcoding (that is, reading raw DCT coefficient arrays from an input JPEG file.) Set up for an output pass, and perform any dummy pass(es) needed. Set default decompression parameters. Retrieves true because this is a decompressor. Gets or sets the source for decompression. Gets the width of image, set by Gets the height of image, set by Gets the number of color components in JPEG image. Gets or sets the colorspace of JPEG image. Gets the list of loaded special markers. Gets or sets the output color space. Gets or sets the numerator of the fraction of image scaling. Gets or sets the denominator of the fraction of image scaling. Gets or sets a value indicating whether to use buffered-image mode. Enable or disable raw data output. Gets or sets the algorithm used for the DCT step. Enable or disable upsampling of chroma components. Apply interblock smoothing in early stages of decoding progressive JPEG files. Colors quantization. Selects color dithering method. Gets or sets a value indicating whether to use two-pass color quantization. Maximum number of colors to use in generating a library-supplied color map. Enable future use of 1-pass quantizer. Enable future use of external colormap. Enable future use of 2-pass quantizer. Gets the actual width of output image. Gets the actual height of output image. Gets the number of color components in . Gets the number of color components returned. Gets the recommended height of scanline buffer. The number of colors in the color map. The color map, represented as a 2-D pixel array of rows and columns. Gets the number of scanlines returned so far. Gets the number of SOS markers seen so far. Gets the number of iMCU rows completed. Gets the nominal scan number being displayed. Gets the number of iMCU rows read. Gets the current progression status.. Gets the resolution information from JFIF marker. Gets the horizontal component of pixel ratio. Gets the vertical component of pixel ratio. Gets the data precision. Gets the largest vertical sample factor. Gets the last read and unprocessed JPEG marker. Comp_info[i] describes component that appears i'th in SOF The delegate for application-supplied marker processing methods. Basic info about one component (color channel). Identifier for this component (0..255) Its index in SOF or . Horizontal sampling factor (1..4) Vertical sampling factor (1..4) Quantization table selector (0..3) DC entropy table selector (0..3) AC entropy table selector (0..3) Gets or sets the width in blocks. Gets the downsampled width. Representation of special JPEG marker. Gets the special marker. Gets the full length of original data associated with the marker. Gets the data associated with the marker. Bitreading state saved across MCUs Bitreading working state within an MCU Encapsulates buffer of image samples for one color component Derived data constructed for each Huffman table Color quantization or color precision reduction Module initialization routine for 1-pass color quantization. Initialize for one-pass color quantization. Finish up at the end of the pass. Switch to a new external colormap between output passes. Map some rows of pixels to the output colormapped representation. Map some rows of pixels to the output colormapped representation. Map some rows of pixels to the output colormapped representation. Map some rows of pixels to the output colormapped representation. Map some rows of pixels to the output colormapped representation. Create the colormap. Create the color index table. Create the ordered-dither tables. Allocate workspace for Floyd-Steinberg errors. Return largest input value that should map to j'th output value Return j'th output value, where j will range from 0 to maxj Determine allocation of desired colors to components, and fill in Ncolors[] array to indicate choice. Return value is total number of colors (product of Ncolors[] values). Create an ordered-dither array for a component having ncolors distinct output values. Module initialization routine for 2-pass color quantization. Initialize for each processing pass. Switch to a new external colormap between output passes. Prescan some rows of pixels. Map some rows of pixels to the output colormapped representation. Map some rows of pixels to the output colormapped representation. Finish up at the end of each pass. Compute representative color for a box, put it in colormap[icolor] Master routine for color selection Repeatedly select and split the largest box until we have enough boxes Find the splittable box with the largest color population Find the splittable box with the largest (scaled) volume Shrink the min/max bounds of a box to enclose only nonzero elements, and recompute its volume and population Initialize the error-limiting transfer function (lookup table). Find the closest colormap entry for each cell in the update box, Fill the inverse-colormap entries in the update box that contains histogram cell c0/c1/c2. Upsampling (note that upsampler must also call color converter) Initialize for an upsampling pass. Control routine to do upsampling (and color conversion). Control routine to do upsampling (and color conversion). Upsample and color convert for the case of 2:1 horizontal and 1:1 vertical. Upsample and color convert for the case of 2:1 horizontal and 2:1 vertical. Initialize tables for YCC->RGB colorspace conversion. Expanded data source object for stdio input Initialize source - called by jpeg_read_header before any data is actually read. Fill the input buffer - called whenever buffer is emptied. Initialize for an upsampling pass. Control routine to do upsampling (and color conversion). This is a no-op version used for "uninteresting" components. For full-size components, we just make color_buf[ci] point at the input buffer, and thus avoid copying any data. Fancy processing for the common case of 2:1 horizontal and 1:1 vertical. Fast processing for the common case of 2:1 horizontal and 1:1 vertical. Fancy processing for the common case of 2:1 horizontal and 2:1 vertical. Fast processing for the common case of 2:1 horizontal and 2:1 vertical. This version handles any integral sampling ratios. Compute a/b rounded up to next integer, ie, ceil(a/b) Compute a rounded up to next multiple of b, ie, ceil(a/b)*b Copy some rows of samples from one place to another. Expanded entropy decoder object for Huffman decoding. Entropy decoding Expand a Huffman table definition into the derived format Initialize for a Huffman-compressed scan. Decode and return one MCU's worth of Huffman-compressed coefficients. Check for a restart marker and resynchronize decoder. Returns false if must suspend. Colorspace conversion Module initialization routine for output colorspace conversion. Convert some rows of samples to the output colorspace. Initialize tables for YCC->RGB colorspace conversion. Adobe-style YCCK->CMYK conversion. Convert grayscale to RGB: just duplicate the graylevel three times. Color conversion for grayscale: just copy the data. Color conversion for no colorspace change: just copy the data, converting from separate-planes to interleaved representation. Coefficient buffer control Initialize for an input processing pass. Consume input data and store it in the full-image coefficient buffer. Initialize for an output processing pass. Decompress and return some data in the single-pass case. Decompress and return some data in the multi-pass case. Variant of decompress_data for use when doing block smoothing. Determine whether block smoothing is applicable and safe. Reset within-iMCU-row counters for a new row (input side) Main buffer control (downsampled-data buffer) Initialize for a processing pass. Process some data. This handles the simple case where no context is required. Process some data. This handles the case where context rows must be provided. Process some data. Allocate space for the funny pointer lists. Create the funny pointer lists discussed in the comments above. Set up the "wraparound" pointers at top and bottom of the pointer lists. Change the pointer lists to duplicate the last sample row at the bottom of the image. Decompression postprocessing (color quantization buffer control) Initialize postprocessing controller. Initialize for a processing pass. Process some data in the one-pass (strip buffer) case. This is used for color precision reduction as well as one-pass quantization. Process some data in the first pass of 2-pass quantization. Process some data in the second pass of 2-pass quantization. Master control module Per-pass setup. Finish up at end of an output pass. Master selection of decompression modules. Allocate and fill in the sample_range_limit table. Input control module Initialize the input controller module. Reset state to begin a fresh datastream. Initialize the input modules to read a scan of compressed data. Finish up after inputting a compressed-data scan. Read JPEG markers before, between, or after compressed-data scans. Routines to calculate various quantities related to the size of the image. Save away a copy of the Q-table referenced by each component present in the current scan, unless already saved during a prior scan. Do computations that are needed before processing a JPEG scan cinfo.comps_in_scan and cinfo.cur_comp_info[] were set from SOS marker Prepare for an output pass. Perform dequantization and inverse DCT on one block of coefficients. Dequantize a coefficient by multiplying it by the multiplier-table entry; produce an int result. In this module, both inputs and result are 16 bits or less, so either int or short multiply will work. Perform dequantization and inverse DCT on one block of coefficients. Multiply a DCTELEM variable by an int constant, and immediately descale to yield a DCTELEM result. Dequantize a coefficient by multiplying it by the multiplier-table entry; produce a DCTELEM result. Like DESCALE, but applies to a DCTELEM and produces an int. Perform dequantization and inverse DCT on one block of coefficients. Dequantize a coefficient by multiplying it by the multiplier-table entry; produce a float result. Inverse-DCT routines that produce reduced-size output: either 4x4, 2x2, or 1x1 pixels from an 8x8 DCT block. Perform dequantization and inverse DCT on one block of coefficients, producing a reduced-size 2x2 output block. Perform dequantization and inverse DCT on one block of coefficients, producing a reduced-size 1x1 output block. Dequantize a coefficient by multiplying it by the multiplier-table entry; produce an int result. Marker reading and parsing Initialize the marker reader module. Reset marker processing state to begin a fresh datastream. Read markers until SOS or EOI. Read a restart marker, which is expected to appear next in the datastream; Find the next JPEG marker, save it in cinfo.unread_marker. Install a special processing method for COM or APPn markers. Save an APPn or COM marker into the marker list Skip over an unknown or uninteresting variable-length marker Process an APP0 or APP14 marker without saving it Examine first few bytes from an APP0. Examine first few bytes from an APP14. Process an SOI marker Process a SOFn marker Process a SOS marker Process a DHT marker Process a DQT marker Process a DRI marker Like next_marker, but used to obtain the initial SOI marker. Expanded entropy decoder object for progressive Huffman decoding. Initialize for a Huffman-compressed scan. MCU decoding for DC initial scan (either spectral selection, or first pass of successive approximation). MCU decoding for AC initial scan (either spectral selection, or first pass of successive approximation). MCU decoding for DC successive approximation refinement scan. Check for a restart marker and resynchronize decoder. MCU decoding for AC successive approximation refinement scan. Defines some JPEG constants. The basic DCT block is 8x8 samples DCTSIZE squared; the number of elements in a block. Quantization tables are numbered 0..3 Huffman tables are numbered 0..3 JPEG limit on the number of components in one scan. Compressor's limit on blocks per MCU. Decompressor's limit on blocks per MCU. JPEG limit on sampling factors. Maximum number of color channels allowed in JPEG image. The size of sample. DCT method used by default. Fastest DCT method. A tad under 64K to prevent overflows. The maximum sample value. The medium sample value. Offset of Red in an RGB scanline element. Offset of Green in an RGB scanline element. Offset of Blue in an RGB scanline element. Bytes per RGB scanline element. The number of bits of lookahead. DCT coefficient quantization tables. Gets or sets a value indicating whether the table has been output to file. JPEG virtual array. Request a virtual 2-D array Access the part of a virtual array. Gets or sets the error processor. One block of coefficients. Gets or sets the element at the specified index. Huffman coding table. Gets or sets a value indicating whether the table has been output to file. The progress monitor object. Indicates that progress was changed. Occurs when progress is changed. Gets or sets the number of work units completed in this pass. Gets or sets the total number of work units in this pass. Gets or sets the number of passes completed so far. Gets or sets the total number of passes expected. Represents a TIFF field information. marker for variable length tags marker for SamplesPerPixel-bound tags marker for integer variable length tags Initializes a new instance of the class. Returns a that represents this instance. The tag described by this instance. Number of values to read when reading field information or one of , and . Number of values to write when writing field information or one of , and . Type of the field values. Index of the bit to use in "Set Fields Vector" when this instance is merged into field info collection. Take a look at class. If true, then it is permissible to set the tag's value even after writing has commenced. If true, then number of value elements should be passed to method as second parameter (right after tag type AND before values itself). The name (or description) of the tag this instance describes. A stream used by the library for TIFF reading and writing. Reads a sequence of bytes from the stream and advances the position within the stream by the number of bytes read. Sets the position within the current stream. Closes the current stream. Gets the length in bytes of the stream. Compresses data using the ASCII85 compression method, reproducing the original text or binary data. Internal variable contains the ascii offset. Internal variable contains the encoded block. Internal variable contains the decoded block. Internal variable. The code Table. Initializes a new instance of the class. Decompresses the specified input data. The input data. The output data. Compresses bytes data. Bytes data to be compressed. Compressed bytes data. Compresses string data. String data to be compressed. Compressed string data. Compresses stream data. Stream data to be compressed. Compressed streams data. Decompresses string data. String data to be decompressed. Decompressed bytes data. Decompresses bytes data. Bytes data to be decompressed. decompressed bytes data Decompresses stream data. Stream data to be decompressed. Decompressed stream data. Decodes the block. Decodes the block. The bytes. Gets the Type of the compressor. Gets name of compressor in PDF format. Encodes data to CCITT format. End of line. Invalide data. End of input data. Incomplete run code. Bit length of g3 code. G3 code. Run length in bits. EOL code value - 0000 0000 0000 1. Holds table zero span. Holds table one span. Holds terminating white codes. Holds terminating black codes. 001 0001 holds mask table. Holds vertical table. Holds row bytes. Holds row pixels. Holds bit count. Holds data. Holds reference line. Holds out buffer array list. Holds image data. Holds offset data. Initializes a new instance of the class. Initializes the class. Encodes the image. The image data. The image width. The image height. Creates ccitt vertical table. Creates ccitt zero span. Creates citt one span. Creates terminating white codes. Creates terminating black codes. Putcodes the specified table. The table. Putspans the specified span. The span. The tab. Puts the bits. The bits. The length. Implements Fax3Encode. Implements Fax4Encode. Pixels the specified data. The data. The offset. The bit. Finds the first span. The bp. The offset. The bs. The be. Finds the zero span. The bp. The offset. The bs. The be. Finddiffs the specified bp. The bp. The offset. The bs. The be. The color. Finddiff2s the specified bp. The bp. The offset. The bs. The be. The color. Compresses data using the LZW compression method, reproducing the original text or binary data. EndOfData marker. Clear-table marker. Start code marker. The marker to set the dictionary to 10 bits code length. The marker to set the dictionary to 11 bits code length The marker to set the dictionary to 12 bits code length Table for codes (dictionary). Input data. Output data. Table index. The number of bits per code. Byte read. Next data. Nex bits. The size of the table. IsEarlyChanged of the LzwCompressor, which is set to true by default Initializes a new instance of the class. Decompresses the specified input data. The input data. The output data. Compresses bytes data. Bytes data to be compressed. Compressed bytes data. Compresses string data. String data to be compressed. Compressed string data. Compresses stream data. Stream data to be compressed. Compressed streams data. Decompresses string data. String data to be decompressed. Decompressed bytes data. Decompresses bytes data. Bytes data to be decompressed. decompressed bytes data Decompresses stream data. Stream data to be decompressed. Decompressed stream data. Initializes the data table. Writes the code to output stream. The code. Adds the code to table. The old bytes. The new byte. Adds the code to table. The data. Add new data to the olddata array. The old data. The new data. Result data array. News the code. code Gets the Type of the compressor. Gets name of compressor in PDF format. PdfPngFilter provides methods that allows to restore original data being modified by similar filter or modify data to better compression ratio. Required for type cast. Delegate for the sub filter. Delegate for the up filter. Delegate for the average filter. Delegate for the Paeth filter. Delegate for the restore filter. Modifies the data by the filter of type 'type'. The data to modify. Bytes per row. The type of the filter. The modified data. Retrieves the original data from the modified. The modified data. Bytes per row. The original data. Performs actual compression or decompression. The original data buffer. The BPR. The filter. if it is pack, set to true Modifies a row by the Sub algorithm. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Modifies a row by the Up algorithm. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Modifies a row by the Average algorithm. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Modifies a row by the Paeth algorithm. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Retrieves original data for a single row. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Decompresses a row using none filter. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Decompresses a row using the Sub filter. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Decompresses a row compressed by the Up filter. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Decompress a row compressed by the Average algorithm. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Unpacks a row packed by the Paeth algorithm. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Returns the Paeth predictor. Left pixel. Above pixel. Upper left pixel. The value of the Paeth predictor. Defines Png Filtern Type. None compression. Sub compression Up compression Average compression Paeth compression Used to call a row filter. The original data buffer. The current row index within the original buffer. The byte-per-row value of the original buffer. The result data buffer. The current row index within the result buffer. The byte-per-row value of the result buffer. Compresses data using the zlib / deflate compression method, reproducing the original text or binary data. Default buffer size for decompression. Name of the compressor. Level of compression. Initializes a new instance of the class. Initializes a new instance of the class. The level. Compresses bytes data. Bytes data to be compressed. Compressed bytes data. Compresses stream data. Stream data. Compressed streams data. Compresses string data. String data to be compressed. Compressed string data. Decompresses string data. String data to be decompressed. Decompressed bytes data. Decompresses bytes data. Bytes data to be decompressed. Decompressed bytes data. Decompresses stream data. Stream data to be decompressed. Decompressed stream data. Gets name of compressor in PDF format. Gets type of compressor. Gets encoding value for this compressor. Gets or sets level of compression. Defines data compression level. Default value is Normal. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Set document compression level doc.Compression = PdfCompressionLevel.BestSpeed; //Obtain PdfGraphics object. PdfGraphics g = page.Graphics; //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create pen with green color. PdfPen pen = new PdfPen(System.Drawing.Color.Green); //Create brush with black color. PdfBrush brush = new PdfSolidBrush(System.Drawing.Color.Black); RectangleF rect = new RectangleF(100, 100, 200, 100); //Draw text in the new page. g.DrawString("Simple Rectangle", font, PdfBrushes.DarkBlue, new PointF(310, 255)); //Draw rectangle in the new page. g.DrawRectangle(pen, brush, rect); //Save the document. doc.Save("CompressionLevel.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = doc.Pages.Add() 'Set document compression level. doc.Compression = PdfCompressionLevel.BestSpeed 'Obtain PdfGraphics object. Dim g As PdfGraphics = page.Graphics 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create pen with green color. Dim pen As PdfPen = New PdfPen(System.Drawing.Color.Green) 'Create brush with black color. Dim brush As PdfBrush = New PdfSolidBrush(System.Drawing.Color.Black) Dim rect As RectangleF = New RectangleF(100, 100, 200, 100) 'Draw text in the new page. g.DrawString("Simple Rectangle", font, PdfBrushes.DarkBlue, New PointF(310, 255)) 'Draw rectangle in the new page. g.DrawRectangle(pen, brush, rect) 'Save document to disk. doc.Save("CompressionLevel.pdf") 'Close the document. doc.Close(True) Class Class Class Class Pack without compression. Use high speed compression, reduce of data size is low. Something middle between normal and BestSpeed compressions. Use normal compression, middle between speed and size. Pack better but require a little more time. Use best compression, slow enough. Enumerator that implements compression level. No compression. Compresses data using the zlib or deflate compression method, reproducing the original text or binary data. Compresses data using the LZW compression method, reproducing the original text or binary data. Compresses data using the ASCII85 compression method, reproducing the original text or binary data. Represents supported stream filters. Decompresses data encoded using a DCT (discrete cosine transform) technique based on the JPEG standard, reproducing image sample data that approximates the original data. Decompresses data encoded using the zlib / deflate compression method, reproducing the original text or binary data. Represents the attachments of the PDF document. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create an attachment. PdfAttachment attachment = new PdfAttachment("Input.txt"); attachment.Description = "Input.txt"; attachment.MimeType = "application/txt"; //Add the attachment to the document. document.Attachments.Add(attachment); //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create an attachment. Dim attachment As New PdfAttachment("Input.txt") attachment.Description = "Input.txt" attachment.MimeType = "application/txt" 'Add the attachment to the document. document.Attachments.Add(attachment) 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class Represents specification of embedded file. Represents base class for file specification objects. Internal variable to store dictionary. Name of the file. Initializes instance. Saves an instance. Formats file name to Unix format. File name to format. bool value which represents the file path type. Formatted file name. Handles the BeginSave event of the m_dictionary control. The source of the event. The instance containing the event data. Gets or sets the name of the file. The name of the file. Gets the dictionary. The dictionary. Gets the element. Internal variable to store description. Embedded file instance. Dictionary to store file specification properties. PortfolioAttributes instance. Represent file relationship. file name Name of the file. The data. Name of the file. The stream. Initializes instance. Saves object state. Gets or sets the data. The data. Gets or sets the description. The description. Gets or sets the MIME type of the embedded file. The MIME type of the embedded file. Gets or sets creation date. Creation date. Gets or sets modification date. Modification date. Gets or sets the Portfolio attributes. Gets the embedded file. The Embedded file. Get or set the file relationship //Creates a new PDF document. PdfDocument doc = new PdfDocument(PdfConformanceLevel.Pdf_A3B); //Add a page. PdfPage page = doc.Pages.Add(); //Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic; //Create the PdfTrueTypeFont PdfFont font = new PdfTrueTypeFont(new Font("arial", 12f, FontStyle.Regular), true); page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty); //Creates an attachment PdfAttachment attachment = new PdfAttachment("ZUGFeRD-invoice.xml"); //Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative; attachment.ModificationDate = DateTime.Now; attachment.Description = "About Syncfusion"; attachment.MimeType = "application/xml"; //add attachment to the doucment doc.Attachments.Add(attachment); doc.Save("output.pdf"); 'Creates a new PDF document. Dim doc As New PdfDocument(PdfConformanceLevel.Pdf_A3B) 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic 'Create the PdfTrueTypeFont Dim font As PdfFont = New PdfTrueTypeFont(New Font("arial", 12F, FontStyle.Regular), True) page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty) 'Creates an attachment Dim attachment As New PdfAttachment("ZUGFeRD-invoice.xml") 'Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative attachment.ModificationDate = DateTime.Now attachment.Description = "About Syncfusion" attachment.MimeType = "application/xml" 'add attachment to the doucment doc.Attachments.Add(attachment) doc.Save("output.pdf") Name of the file. The name of the file to be attached. The data to be attached as a file. The name of the file to be attached. The stream to be attached. Represents a collection of the attachment objects. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create an attachment. PdfAttachment attachment = new PdfAttachment("Input.txt"); attachment.Description = "Input.txt"; attachment.MimeType = "application/txt"; //Add the attachment to the document. document.Attachments.Add(attachment); //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create an attachment. Dim attachment As New PdfAttachment("Input.txt") attachment.Description = "Input.txt" attachment.MimeType = "application/txt" 'Add the attachment to the document. document.Attachments.Add(attachment) 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Internal variable to store internal array of attachments. Internal variable to store dictionary wrapper. internal Variable to store filename and attachment. internal variable to store ordered filename. internal variable to store file count value. store the cross table variable to store main object collection varible to maintain attachment dictionary Initializes a new instance of the class. Initializes a new instance of the class. The attachment dictionary. The table. Internal method to get attachement information. The Pdfarray. Inserts the attachment at specified index. The index at which attachment to be inserted. The attachment to be inserted. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Create an attachment. PdfAttachment attachment = new PdfAttachment("Input.txt"); attachment.Description = "Input.txt"; attachment.MimeType = "application/txt"; //insert the attachment at specified index. document.Attachments.Insert(0, attachment); //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Create an attachment. Dim attachment As New PdfAttachment("Input.txt") attachment.Description = "Input.txt" attachment.MimeType = "application/txt" 'insert the attachment at specified index. document.Attachments.Insert(0, attachment) 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Removes the specified attachment from the collection. The attachment to be removed. /// //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Load an attachment collection. PdfAttachmentCollection attachments = loadedDocument.Attachments; //Get the attachment at the specified index. PdfAttachment attachment = loadedDocument.Attachments[0]; //Remove attachment by attachment name. attachments.Remove(attachment); //Save and close the document. loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Load an attachment collection. Dim attachments As PdfAttachmentCollection = loadedDocument.Attachments 'Get the attachment at the specified index. attachment As PdfAttachment = loadedDocument.Attachments(0) 'Remove attachment by attachment name. attachments.Remove(attachment) 'Save and close the document. loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. Removes attachment at the specified index. The index at which the attachment to be removed. /// //Load the PDF document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Load an attachment collection PdfAttachmentCollection attachments = loadedDocument.Attachments; //Remove attachment by index attachments.RemoveAt(0); //Save and close the document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Load an attachment collection Dim attachments As PdfAttachmentCollection = loadedDocument.Attachments 'Remove attachment by index attachments.RemoveAt(0) 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. search and find the index of the attachment. The attachment to find the position. The index of the specified attachment. /// //Create a new PDF document PdfDocument document = new PdfDocument(); //Create an attachment PdfAttachment attachment = new PdfAttachment("Input.txt"); attachment.Description = "Input.txt"; attachment.MimeType = "application/txt"; //Add the attachment to the document document.Attachments.Add(attachment); //Get the index of attachment int index = document.Attachments.IndexOf(attachment); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create an attachment Dim attachment As New PdfAttachment("Input.txt") attachment.Description = "Input.txt" attachment.MimeType = "application/txt" 'Add the attachment to the document document.Attachments.Add(attachment) 'Get the index of attachment Dim index As Integer = document.Attachments.IndexOf(attachment) 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class. Determines whether the attachment collection contains the specified attachment. The attachment to be searched. if it contains the specified attachment, set to true. otherwise false //Create a new PDF document PdfDocument document = new PdfDocument(); //Create an attachment PdfAttachment attachment = new PdfAttachment("Input.txt"); attachment.Description = "Input.txt"; attachment.MimeType = "application/txt"; //Add the attachment to the document document.Attachments.Add(attachment); //check the collection contains the specified attachment. bool isAttachmentContained = document.Attachments.Contains(attachment); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a new PDF document Dim document As New PdfDocument() 'Create an attachment Dim attachment As New PdfAttachment("Input.txt") attachment.Description = "Input.txt" attachment.MimeType = "application/txt" 'Add the attachment to the document document.Attachments.Add(attachment) 'check the collection contains the specified attachment. Dim isAttachmentContained As Boolean = document.Attachments.Contains(attachment) 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class. Remove all the attachments from the collection. //Load the PDF document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get the attachments PdfAttachmentCollection attachments = loadedDocument.Attachments; //Remove all the bookmarks form the collection attachments.Clear(); //Save and close the PDF document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get the attachments Dim attachments As PdfAttachmentCollection = loadedDocument.Attachments 'Remove all the bookmarks form the collection attachments.Clear() 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. Adds the attachment. The attachment. The index of the attachment. Does the insert. The index. The attachment. Removes the attachment. The attachment. Removes the attachment. The index. Clears the collection. Removing attachment dictionary and stream from main object collection Obtain Attachement relation ship Gets the element. Internal variable to store field's bounds. Internal variable to store font. Internal variable to store brush. Internal variable to store pen. Internal variable to store string format. Internal variable to store template size. Initializes a new instance of the class. Initializes a new instance of the class with The represents the format of the text. Initializes a new instance of the class with and . The represents the format of the text. The provides color and texture to the text. Initializes a new instance of the class with and bounds. The represents the format of the text. The bounds. Draws an element on the Graphics. Graphics context where the element should be printed. X co-ordinate of the element. Y co-ordinate of the element. Gets the value of the field at the specified graphics. The graphics. Performs draw. The graphics. The location. The scaling X. The scaling Y. Gets the template size. The template size. Draws an element on the Graphics. Graphics context where the element should be printed. Gets the brush. If brush is undefined default black brush will be used. The brush Gets the font. If font is undefined default font will be used. Gets or sets the of the field. The determines text layout information on PDF Represents information about the automatic field. Internal variable to store location of the field. Internal variable to store field. Internal variable to store x scaling factor. Internal variable to store y scaling factor. Initializes a new instance of the class. The field. The location. Initializes a new instance of the class. The field. The location. The scaling X. The scaling Y. Initializes a new instance of the class. The field info. Gets or sets the location. The location. Gets or sets the field. The field. Gets or sets the scaling X factor. The scaling X factor. Gets or sets the scaling Y factor. The scaling Y factor. Represent a collection of automatic fields information. Class Initializes a new instance of the class. Adds the specified field info. The field info. field Info Represents automatic field which has the same value within the Class Represents automatic field which value is dynamically evaluated. Class Initializes a new instance of the class. Initializes a new instance of the class with . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. Initializes a new instance of the class and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. . Initializes a new instance of the class with and bounds A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The Rectangle bounds. Gets the page from a graphics. The graphics. The proper PdfPage instance. Gets the Loaded page from a graphics. The graphics The graphics Internal variable to store templates associated with the graphics. Initializes a new instance of the class. Initializes a new instance of the class with . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The specifies the color and texture to the text. Initializes a new instance of the class with and rectangle bounds. A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The rectangle bounds. Performs draw. The graphics. The location. The scaling X. The scaling Y. Gets or sets the tag for the element Internal variable to store list of automatic fields. Internal variable to store value. Initializes a new instance of the class with text and list of automatic fields The wide-character string to be drawn. The list of objects. //Create a new document PdfDocument document = new PdfDocument(); //Create a new page. PdfPage mainPage = document.Pages.Add(); //Create the PDF font instance. PdfTrueTypeFont font = new PdfTrueTypeFont(new Font("Times New Roman", 12f)); //Create the PDF brsh instance. PdfSolidBrush brush = new PdfSolidBrush(Color.Green); //Create page count field. PdfPageCountField pageCount = new PdfPageCountField(); pageCount.Bounds = new RectangleF(0, 0, 150, 150); pageCount.Font = font; pageCount.Brush = brush; pageCount.NumberStyle = PdfNumberStyle.Numeric; //Create date time field. PdfDateTimeField dateField = new PdfDateTimeField(); dateField.Font = font; dateField.DateFormatString = "MM'/'ddd'/'yyyy"; dateField.Brush = brush; //Set value for automatic field. PdfAutomaticField[] auto = { pageCount, dateField }; //Create composite field. PdfCompositeField comp = new PdfCompositeField("page {0}, date {1} ", auto); comp.Brush = brush; comp.Location = new PointF(100, 100); comp.Draw(mainPage.Graphics); comp.Size = new SizeF(300, 300); comp.Font = font; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document Dim document As PdfDocument = New PdfDocument() 'Create a new page. Dim mainPage As PdfPage = document.Pages.Add() 'Create the PDF font instance. Dim font As PdfTrueTypeFont = New PdfTrueTypeFont(New Font("Times New Roman", 12.0F)) 'Create the PDF font instance. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Green) 'Create page count field. Dim pageCount As PdfPageCountField = New PdfPageCountField() pageCount.Bounds = New RectangleF(0, 0, 150, 150) pageCount.Font = font pageCount.Brush = brush pageCount.NumberStyle = PdfNumberStyle.Numeric 'Create date time field. Dim dateField As PdfDateTimeField = New PdfDateTimeField() dateField.Font = font dateField.DateFormatString = "MM'/'ddd'/'yyyy" dateField.Brush = brush 'Set value for automatic field. Dim auto As PdfAutomaticField() = {pageCount, dateField } 'Create composite field. Dim comp As PdfCompositeField = New PdfCompositeField("page {0}, date {1} ", auto) comp.Brush = brush comp.Location = New PointF(100, 100) comp.Draw(mainPage.Graphics) comp.Size = New SizeF(300, 300) comp.Font = font 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Initializes a new instance of the class with ,text and list of automatic fields A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The wide-character string to be drawn. The list of objects. //Create a new document PdfDocument document = new PdfDocument(); //Create a new page. PdfPage mainPage = document.Pages.Add(); //Create the PDF font instance. PdfTrueTypeFont font = new PdfTrueTypeFont(new Font("Times New Roman", 12f)); //Create the PDF brsh instance. PdfSolidBrush brush = new PdfSolidBrush(Color.Green); //Create page count field. PdfPageCountField pageCount = new PdfPageCountField(); pageCount.Bounds = new RectangleF(0, 0, 150, 150); pageCount.NumberStyle = PdfNumberStyle.Numeric; //Create date time field. PdfDateTimeField dateField = new PdfDateTimeField(); dateField.DateFormatString = "MM'/'ddd'/'yyyy"; //Set value for automatic field. PdfAutomaticField[] auto = { pageCount, dateField }; //Create composite field. PdfCompositeField comp = new PdfCompositeField(font, "page {0}, date {1} ", auto); comp.Brush = brush; comp.Location = new PointF(100, 100); comp.Draw(mainPage.Graphics); comp.Size = new SizeF(300, 300); comp.Font = font; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document Dim document As PdfDocument = New PdfDocument() 'Create a new page. Dim mainPage As PdfPage = document.Pages.Add() 'Create the PDF font instance. Dim font As PdfTrueTypeFont = New PdfTrueTypeFont(New Font("Times New Roman", 12.0F)) 'Create the PDF font instance. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Green) 'Create page count field. Dim pageCount As PdfPageCountField = New PdfPageCountField() pageCount.Bounds = New RectangleF(0, 0, 150, 150) pageCount.NumberStyle = PdfNumberStyle.Numeric 'Create date time field. Dim dateField As PdfDateTimeField = New PdfDateTimeField() dateField.DateFormatString = "MM'/'ddd'/'yyyy" 'Set value for automatic field. Dim auto As PdfAutomaticField() = {pageCount, dateField } 'Create composite field. Dim comp As PdfCompositeField = New PdfCompositeField(font, "page {0}, date {1} ", auto) comp.Brush = brush comp.Location = New PointF(100, 100) comp.Draw(mainPage.Graphics) comp.Size = New SizeF(300, 300) comp.Font = font 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Initializes a new instance of the class with ,,text and list of automatic fields. A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. The wide-character string to be drawn. The list of objects. //Create a new document PdfDocument document = new PdfDocument(); //Create a new page. PdfPage mainPage = document.Pages.Add(); //Create the PDF font instance. PdfTrueTypeFont font = new PdfTrueTypeFont(new Font("Times New Roman", 12f)); //Create the PDF brsh instance. PdfSolidBrush brush = new PdfSolidBrush(Color.Green); //Create page count field. PdfPageCountField pageCount = new PdfPageCountField(); pageCount.Bounds = new RectangleF(0, 0, 150, 150); pageCount.NumberStyle = PdfNumberStyle.Numeric; //Create date time field. PdfDateTimeField dateField = new PdfDateTimeField(); dateField.DateFormatString = "MM'/'ddd'/'yyyy"; //Set value for automatic field. PdfAutomaticField[] auto = { pageCount, dateField }; //Create composite field. PdfCompositeField comp = new PdfCompositeField(font, brush, "page {0}, date {1} ", auto); comp.Location = new PointF(100, 100); comp.Draw(mainPage.Graphics); comp.Size = new SizeF(300, 300); comp.Font = font; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document Dim document As PdfDocument = New PdfDocument() 'Create a new page. Dim mainPage As PdfPage = document.Pages.Add() 'Create the PDF font instance. Dim font As PdfTrueTypeFont = New PdfTrueTypeFont(New Font("Times New Roman", 12.0F)) 'Create the PDF font instance. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Green) 'Create page count field. Dim pageCount As PdfPageCountField = New PdfPageCountField() pageCount.Bounds = New RectangleF(0, 0, 150, 150) pageCount.NumberStyle = PdfNumberStyle.Numeric 'Create date time field. Dim dateField As PdfDateTimeField = New PdfDateTimeField() dateField.DateFormatString = "MM'/'ddd'/'yyyy" 'Set value for automatic field. Dim auto As PdfAutomaticField() = {pageCount, dateField } 'Create composite field. Dim comp As PdfCompositeField = New PdfCompositeField(font, brush, "page {0}, date {1} ", auto) comp.Location = New PointF(100, 100) comp.Draw(mainPage.Graphics) comp.Size = New SizeF(300, 300) comp.Font = font 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Gets the value of the field at the specified graphics. The graphics. Gets or sets the automatic fields. The array of automatic fields . //Create a new document PdfDocument document = new PdfDocument(); //Create a new page. PdfPage mainPage = document.Pages.Add(); //Create the PDF font instance. PdfTrueTypeFont font = new PdfTrueTypeFont(new Font("Times New Roman", 12f)); //Create the PDF brsh instance. PdfSolidBrush brush = new PdfSolidBrush(Color.Green); //Create page count field. PdfPageCountField pageCount = new PdfPageCountField(); pageCount.Bounds = new RectangleF(0, 0, 150, 150); pageCount.Font = font; pageCount.Brush = brush; pageCount.NumberStyle = PdfNumberStyle.Numeric; //Create date time field. PdfDateTimeField dateField = new PdfDateTimeField(); dateField.Font = font; dateField.DateFormatString = "MM'/'ddd'/'yyyy"; dateField.Brush = brush; //Set value for automatic field. PdfAutomaticField[] auto = { pageCount, dateField }; //Create composite field. PdfCompositeField comp = new PdfCompositeField(); comp.Text = "page {0}, date {1}"; comp.AutomaticFields = auto; comp.Brush = brush; comp.Location = new PointF(100, 100); comp.Draw(mainPage.Graphics); comp.Size = new SizeF(300, 300); comp.Font = font; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document Dim document As PdfDocument = New PdfDocument() 'Create a new page. Dim mainPage As PdfPage = document.Pages.Add() 'Create the PDF font instance. Dim font As PdfTrueTypeFont = New PdfTrueTypeFont(New Font("Times New Roman", 12.0F)) 'Create the PDF font instance. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Green) 'Create page count field. Dim pageCount As PdfPageCountField = New PdfPageCountField() pageCount.Bounds = New RectangleF(0, 0, 150, 150) pageCount.Font = font pageCount.Brush = brush pageCount.NumberStyle = PdfNumberStyle.Numeric 'Create date time field. Dim dateField As PdfDateTimeField = New PdfDateTimeField() dateField.Font = font dateField.DateFormatString = "MM'/'ddd'/'yyyy" dateField.Brush = brush 'Set value for automatic field. Dim auto As PdfAutomaticField() = {pageCount, dateField } 'Create composite field. Dim comp As PdfCompositeField = New PdfCompositeField() comp.Text = "page {0}, date {1}" comp.AutomaticFields = auto comp.Brush = brush comp.Location = New PointF(100, 100) comp.Draw(mainPage.Graphics) comp.Size = New SizeF(300, 300) comp.Font = font 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Represents class to display creation date of the document. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; //Creates Date time field. PdfCreationDateField dateTimeField = new PdfCreationDateField(font); for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F) Dim brush As PdfBrush = PdfBrushes.Black 'Creates Date time field. Dim dateTimeField As New PdfCreationDateField(font) For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Class Represents automatic field which has the same value in the whole document. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create new PDF brush. PdfBrush brush = PdfBrushes.Black; //Creates page count field. PdfPageCountField pageCount = new PdfPageCountField(font); pageCount.NumberStyle = PdfNumberStyle.Numeric; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageCount.Draw(page.Graphics); } //Save and close the document. doc.Save("PageCountField.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black 'Creates page count field. Dim pageCount As PdfPageCountField = New PdfPageCountField(font) pageCount.NumberStyle = PdfNumberStyle.Numeric For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageCount.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("PageCountField.pdf") doc.Close(True); Class Internal variable to store templates associated with the document. Internal variable to array of graphics. Initializes a new instance of the class. Initializes a new instance of the class with . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. Initializes a new instance of the class with and rectangle bounds of the field A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The bounds. Performs draw. The graphics. The location. The scaling X. The scaling Y. Internal variable to store format of the date. Initializes a new instance of the class. // Create a new document PdfDocument doc = new PdfDocument(); //Create a new page PdfPage page = doc.Pages.Add(); // Creates Date time field PdfCreationDateField dateTimeField = new PdfCreationDateField(); for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document doc.Save("DateTimeField.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Creates Date time field. Dim dateTimeField As New PdfCreationDateField() For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Initializes a new instance of the class with A object that specifies the font attributes (the family name, the size, and the style of the font) to use. // Create a new document PdfDocument doc = new PdfDocument(); //Create a new page PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; // Creates Date time field PdfCreationDateField dateTimeField = new PdfCreationDateField(font); for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document doc.Save("DateTimeField.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F) Dim brush As PdfBrush = PdfBrushes.Black 'Creates Date time field. Dim dateTimeField As New PdfCreationDateField(font) For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; //Creates Date time field. PdfCreationDateField dateTimeField = new PdfCreationDateField(font,brush); for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F) Dim brush As PdfBrush = PdfBrushes.Black 'Creates Date time field. Dim dateTimeField As New PdfCreationDateField(font,brush) For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. Specifies the location and size of the field. //Creates a new document. PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates Date time field. PdfCreationDateField dateTimeField = new PdfCreationDateField(font, new RectangleF(new PointF(10,10), new SizeF(100,200))); for (int i = 0; i !=3; i++) { //Creates a new page. PdfPage page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf"); doc.Close(true); 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates Date time field. Dim dateTimeField As PdfCreationDateField = New PdfCreationDateField(font, New RectangleF(New PointF(10,10), New SizeF(100,200))) For i As Integer = 0 To 2 'Create a new page. Dim page As PdfPage = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Gets the value of the field at the specified graphics. The graphics. Gets or sets the format string. The format string. //Creates a new document. PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates Date time field. PdfCreationDateField dateTimeField = new PdfCreationDateField(font, new RectangleF(new PointF(10,10), new SizeF(100,200))); dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy"; for (int i = 0; i != 3; i++) { //Creates a new page. PdfPage page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf"); doc.Close(true); 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates Date time field. Dim dateTimeField As PdfCreationDateField = New PdfCreationDateField(font, New RectangleF(New PointF(10,10), New SizeF(100,200))) dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy" For i As Integer = 0 To 2 'Create a page. Dim page As PdfPage = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Represents compression options of the loaded document. To know more about refer this link . //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Initialize new instance of PdfCompressionOptions class. PdfCompressionOptions options = new PdfCompressionOptions(); //set the compress images based on the image quality. options.CompressImages = true; //set the image quality. options.ImageQuality = 50; //set the optimize font. options.OptimizeFont = true; //set the optimize page contents. options.OptimizePageContents = true; //set the remove metadata informations. options.RemoveMetadata = true; ldoc.CompressionOptions = options; //Save and close the document. ldoc.Save("Output.pdf"); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Initialize new instance of PdfCompressionOptions class. Dim options As PdfCompressionOptions = New PdfCompressionOptions() 'set the compress images based on the image quality. options.CompressImages = True 'set the image quality. options.ImageQuality = 50 'set the optimize font. options.OptimizeFont = True 'set the optimize page contents. options.OptimizePageContents = True 'set the remove metadata informations. options.RemoveMetadata = True ldoc.CompressionOptions = options 'Save and Close the document. ldoc.Save("Output.pdf") ldoc.Close(True) Indicates whether remove metadata. Indicates compress the image objects based on the image quality. Represents the image quality. Indicates optimize the page content streams. Indicates optimize the font data. Gets or sets whether remove metadata informations. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Initialize new instance of PdfCompressionOptions class. PdfCompressionOptions options = new PdfCompressionOptions(); //set the compress images based on the image quality. options.CompressImages = true; //set the image quality. options.ImageQuality = 50; //set the optimize font. options.OptimizeFont = true; //set the optimize page contents. options.OptimizePageContents = true; //set the remove metadata informations. options.RemoveMetadata = true; ldoc.CompressionOptions = options; //Save and close the document. ldoc.Save("Output.pdf"); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Initialize new instance of PdfCompressionOptions class. Dim options As PdfCompressionOptions = New PdfCompressionOptions() 'set the compress images based on the image quality. options.CompressImages = True 'set the image quality. options.ImageQuality = 50 'set the optimize font. options.OptimizeFont = True 'set the optimize page contents. options.OptimizePageContents = True 'set the remove metadata informations. options.RemoveMetadata = True ldoc.CompressionOptions = options 'Save and Close the document. ldoc.Save("Output.pdf") ldoc.Close(True) Gets or sets whether compress images based on the image quality. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Initialize new instance of PdfCompressionOptions class. PdfCompressionOptions options = new PdfCompressionOptions(); //set the compress images based on the image quality. options.CompressImages = true; //set the image quality. options.ImageQuality = 50; //set the optimize font. options.OptimizeFont = true; //set the optimize page contents. options.OptimizePageContents = true; //set the remove metadata informations. options.RemoveMetadata = true; ldoc.CompressionOptions = options; //Save and close the document. ldoc.Save("Output.pdf"); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Initialize new instance of PdfCompressionOptions class. Dim options As PdfCompressionOptions = New PdfCompressionOptions() 'set the compress images based on the image quality. options.CompressImages = True 'set the image quality. options.ImageQuality = 50 'set the optimize font. options.OptimizeFont = True 'set the optimize page contents. options.OptimizePageContents = True 'set the remove metadata informations. options.RemoveMetadata = True ldoc.CompressionOptions = options 'Save and Close the document. ldoc.Save("Output.pdf") ldoc.Close(True) Gets or sets the image quality. Default value is 50. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Initialize new instance of PdfCompressionOptions class. PdfCompressionOptions options = new PdfCompressionOptions(); //set the compress images based on the image quality. options.CompressImages = true; //set the image quality. options.ImageQuality = 50; //set the optimize font. options.OptimizeFont = true; //set the optimize page contents. options.OptimizePageContents = true; //set the remove metadata informations. options.RemoveMetadata = true; ldoc.CompressionOptions = options; //Save and close the document. ldoc.Save("Output.pdf"); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Initialize new instance of PdfCompressionOptions class. Dim options As PdfCompressionOptions = New PdfCompressionOptions() 'set the compress images based on the image quality. options.CompressImages = True 'set the image quality. options.ImageQuality = 50 'set the optimize font. options.OptimizeFont = True 'set the optimize page contents. options.OptimizePageContents = True 'set the remove metadata informations. options.RemoveMetadata = True ldoc.CompressionOptions = options 'Save and Close the document. ldoc.Save("Output.pdf") ldoc.Close(True) Gets or sets whether to optimize page contents. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Initialize new instance of PdfCompressionOptions class. PdfCompressionOptions options = new PdfCompressionOptions(); //set the compress images based on the image quality. options.CompressImages = true; //set the image quality. options.ImageQuality = 50; //set the optimize font. options.OptimizeFont = true; //set the optimize page contents. options.OptimizePageContents = true; //set the remove metadata informations. options.RemoveMetadata = true; ldoc.CompressionOptions = options; //Save and close the document. ldoc.Save("Output.pdf"); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Initialize new instance of PdfCompressionOptions class. Dim options As PdfCompressionOptions = New PdfCompressionOptions() 'set the compress images based on the image quality. options.CompressImages = True 'set the image quality. options.ImageQuality = 50 'set the optimize font. options.OptimizeFont = True 'set the optimize page contents. options.OptimizePageContents = True 'set the remove metadata informations. options.RemoveMetadata = True ldoc.CompressionOptions = options 'Save and Close the document. ldoc.Save("Output.pdf") ldoc.Close(True) Gets or sets whether to optimize font data. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Initialize new instance of PdfCompressionOptions class. PdfCompressionOptions options = new PdfCompressionOptions(); //set the compress images based on the image quality. options.CompressImages = true; //set the image quality. options.ImageQuality = 50; //set the optimize font. options.OptimizeFont = true; //set the optimize page contents. options.OptimizePageContents = true; //set the remove metadata informations. options.RemoveMetadata = true; ldoc.CompressionOptions = options; //Save and close the document. ldoc.Save("Output.pdf"); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Initialize new instance of PdfCompressionOptions class. Dim options As PdfCompressionOptions = New PdfCompressionOptions() 'set the compress images based on the image quality. options.CompressImages = True 'set the image quality. options.ImageQuality = 50 'set the optimize font. options.OptimizeFont = True 'set the optimize page contents. options.OptimizePageContents = True 'set the remove metadata informations. options.RemoveMetadata = True ldoc.CompressionOptions = options 'Save and Close the document. ldoc.Save("Output.pdf") ldoc.Close(True) Represernts the PDF optimizer. Indicates the optimization options. Indicates the font references. Indicates the image references. Indicates the TTF font common table list Collection holds used fonts in a page The variable used to store the Optimized dictionary collection Initialize the new instance of the class with input file name. Input file name. Optimize the PDF document Close the optimizer Optimze the annotations content streams. Check page resoucres contains identical resoucres optimize the Apperance dictionary. Optimize the page resources (font, image, xobject contents). Optimize the page content. Optimize the content stream. Trim the operand if contains .00 Remove the meta data entry Optimize all the PDF resources Optimize the font data optimize the image Create a font stream by using used characters Add font used text in a collection Replace the existing image Get the image interpolation. Optimize the PDF true type font optimize the type 0 font Get the local table last index Optimize type0 font Update the existing font data Set the font tables. Update the embedded subset font Name based on the PDF specification. Get the object from parent dictionary Get the object from IPdfPrimitive Calulates the check sum value. Get the font table entry. calculate the local and hmtx table length. Create hash from the current stream and returns true if present in the collection Create hash value from the current stream Find Adobe standard Latin characters Represents date and time automated field. //Creates a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates DateTime field. PdfDateTimeField dateTimeField = new PdfDateTimeField(font); dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy"; for (int i = 0; i !=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } doc.Save("DateTimeField.pdf") doc.Close(True) 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates DateTime field. Dim dateTimeField As PdfDateTimeField = New PdfDateTimeField(font) dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy" For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i doc.Save("DateTimeField.pdf") doc.Close(True) Class Represents automatic field which value can be evaluated in the moment of creation. Class Internal variable to store template of the field. Internal variable to store list of graphics Initializes a new instance of the class. Initializes a new instance of the class with The represents the format of the text. Initializes a new instance of the class with and The represents the format of the text. The provides color and texture to the text. Initializes a new instance of the class with and bounds The represents the format of the text. The Rectangle bounds. Performs draw. The graphics. The location. The scaling X. The scaling Y. Internal variable to store date value of the field. Internal variable to store format of the date. Initializes a new instance of the class. //Creates a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); //Creates DateTime field. PdfDateTimeField dateTimeField = new PdfDateTimeField(); dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy"; for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() 'Creates DateTime field. Dim dateTimeField As PdfDateTimeField = New PdfDateTimeField() dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy" For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Initializes a new instance of the class with . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. //Creates a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates DateTime field. PdfDateTimeField dateTimeField = new PdfDateTimeField(font); dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy"; for (int i = 0; i !=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates DateTime field. Dim dateTimeField As PdfDateTimeField = New PdfDateTimeField(font) dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy" For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. //Creates a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates DateTime field. PdfDateTimeField dateTimeField = new PdfDateTimeField(font, PdfBrushes.Aquamarine); dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy"; for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates DateTime field. Dim dateTimeField As PdfDateTimeField = New PdfDateTimeField(font, PdfBrushes.Aquamarine) dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy" For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i 'Save and clos ethe document. doc.Save("DateTimeField.pdf") doc.Close(True) Initializes a new instance of the class with and rectangle bounds A object that specifies the font attributes (the family name, the size, and the style of the font) to use. Specifies the location and size of the field. //Creates a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates DateTime field. PdfDateTimeField dateTimeField = new PdfDateTimeField(font, new RectangleF(new PointF(10,10), new SizeF(100,200))); dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy"; for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates DateTime field. Dim dateTimeField As PdfDateTimeField = New PdfDateTimeField(font, New RectangleF(New PointF(10,10), New SizeF(100,200))) dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy" For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) Get the value of the field at the specified graphics. The graphics. value Gets or sets the date format string. The format string. //Creates a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document. PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates DateTime field. PdfDateTimeField dateTimeField = new PdfDateTimeField(font, new RectangleF(new PointF(10,10), new SizeF(100,200))); dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy"; for (int i = 0; i!=3; i++) { page = doc.Pages.Add(); dateTimeField.Draw(page.Graphics); } //Save and close the document. doc.Save("DateTimeField.pdf") doc.Close(True) 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates DateTime field. Dim dateTimeField As PdfDateTimeField = New PdfDateTimeField(font, New RectangleF(New PointF(10,10), New SizeF(100,200))) dateTimeField.DateFormatString = "dd'/'MMMM'/'yyyy" For i As Integer = 0 To 2 page = doc.Pages.Add() dateTimeField.Draw(page.Graphics) Next i 'Save and clos ethe document. doc.Save("DateTimeField.pdf") doc.Close(True) Represents class which displays destination page's number. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfDestinationPageNumberField pageNumber = new PdfDestinationPageNumberField(font); for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); // Draws the page number only on the second page if (i == 1) { pageNumber.Page = page; pageNumber.Draw(page.Graphics); } } doc.Save("DateTimeField.pdf") doc.Close(True) ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfDestinationPageNumberField = New PdfDestinationPageNumberField(font) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() ' Draws the page number only on the second page If i = 1 Then pageNumber.Page = page pageNumber.Draw(page.Graphics) End If Next i doc.Save("DateTimeField.pdf") doc.Close(True) Class Represents PDF document page number field. //Create a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font); pageNumber.NumberStyle = PdfNumberStyle.UpperLatin; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageNumber.Draw(page.Graphics); } doc.Save("PageNumberField.pdf"); doc.Close(true); 'Create a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Creates page number field Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font) pageNumber.NumberStyle = PdfNumberStyle.UpperLatin For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageNumber.Draw(page.Graphics) Next i doc.Save("PageNumberField.pdf") doc.Close(True) Class Represents automatic field which has the same value within the Class Internal variable to store numbering style. Initializes a new instance of the class. Initializes a new instance of the class with . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The specifies the color and texture to the text. Initializes a new instance of the class with and rectangle bounds A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The bounds. Gets or sets the specific number style. The provides specific number style. Initializes a new instance of the class. // Create a new document PdfDocument doc = new PdfDocument(); // Creates page number field PdfPageNumberField pageNumber = new PdfPageNumberField(); pageNumber.NumberStyle = PdfNumberStyle.UpperLatin; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageNumber.Draw(page.Graphics); } doc.Save("PageNumberField.pdf"); doc.Close(true); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Creates page number field Dim pageNumber As PdfPageNumberField = New PdfPageNumberField() pageNumber.NumberStyle = PdfNumberStyle.UpperLatin For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageNumber.Draw(page.Graphics) Next i doc.Save("PageNumberField.pdf") doc.Close(True) Initializes a new instance of the class with A object that specifies the font attributes (the family name, the size, and the style of the font) to use. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font); pageNumber.NumberStyle = PdfNumberStyle.UpperLatin; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageNumber.Draw(page.Graphics); } doc.Save("PageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font) pageNumber.NumberStyle = PdfNumberStyle.UpperLatin For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageNumber.Draw(page.Graphics) Next i doc.Save("PageNumberField.pdf") doc.Close(True) Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font, PdfBrushes.Beige); pageNumber.NumberStyle = PdfNumberStyle.UpperLatin; for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); pageNumber.Draw(page.Graphics); } doc.Save("PageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font, PdfBrushes.Beige) pageNumber.NumberStyle = PdfNumberStyle.UpperLatin For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageNumber.Draw(page.Graphics) Next i doc.Save("PageNumberField.pdf") doc.Close(True) Initializes a new instance of the class with and rectangle bounds. A object that specifies the font attributes (the family name, the size, and the style of the font) to use.s The bounds. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font, new RectangleF(10, 10, 100, 200)); pageNumber.NumberStyle = PdfNumberStyle.UpperLatin; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageNumber.Draw(page.Graphics); } doc.Save("PageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font, new RectangleF(10, 10, 100, 200)); pageNumber.NumberStyle = PdfNumberStyle.UpperLatin For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageNumber.Draw(page.Graphics) Next i doc.Save("PageNumberField.pdf") doc.Close(True) Gets the value of the field at the specified graphics. The graphics. result Internal method to get value of the field. The page. Internal method to get value of the field. The page Internal variable to store destination page. Internal variable to store the Loaded Page. Initializes a new instance of the class. // Creates a new document PdfDocument doc = new PdfDocument(); // Creates page number field PdfDestinationPageNumberField pageNumber = new PdfDestinationPageNumberField(); for (int i = 0; i !=2; i++) { PdfPage page = doc.Pages.Add(); // Draws the page number only on the second page if (i == 1) { pageNumber.Page = page; pageNumber.Draw(page.Graphics); } } doc.Save("DestinationPageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Creates page number field Dim pageNumber As PdfDestinationPageNumberField = New PdfDestinationPageNumberField() For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() ' Draws the page number only on the second page If i = 1 Then pageNumber.Page = page pageNumber.Draw(page.Graphics) End If Next i doc.Save("DestinationPageNumberField.pdf"); doc.Close(True) Initializes a new instance of the class with A object that specifies the font attributes (the family name, the size, and the style of the font) to use. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfDestinationPageNumberField pageNumber = new PdfDestinationPageNumberField(font); for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); // Draws the page number only on the second page if (i == 1) { pageNumber.Page = page; pageNumber.Draw(page.Graphics); } } doc.Save("DestinationPageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfDestinationPageNumberField = New PdfDestinationPageNumberField(font) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() ' Draws the page number only on the second page If i = 1 Then pageNumber.Page = page pageNumber.Draw(page.Graphics) End If Next i doc.Save("DestinationPageNumberField.pdf"); doc.Close(True) Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfDestinationPageNumberField pageNumber = new PdfDestinationPageNumberField(font, PdfBrushes.Azure); for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); // Draws the page number only on the second page if (i == 1) { pageNumber.Page = page; pageNumber.Draw(page.Graphics); } } doc.Save("DestinationPageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfDestinationPageNumberField = New PdfDestinationPageNumberField(font, PdfBrushes.Azure) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() ' Draws the page number only on the second page If i = 1 Then pageNumber.Page = page pageNumber.Draw(page.Graphics) End If Next i doc.Save("DestinationPageNumberField.pdf"); doc.Close(True) Initializes a new instance of the class with and rectangle bounds. A object that specifies the font attributes (the family name, the size, and the style of the font) to use. Specifies the location and size of the field. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfDestinationPageNumberField pageNumber = new PdfDestinationPageNumberField(font, new RectangleF(10, 10, 100, 200)); for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); // Draws the page number only on the second page if (i == 1) { pageNumber.Page = page; pageNumber.Draw(page.Graphics); } } doc.Save("DestinationPageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfDestinationPageNumberField = New PdfDestinationPageNumberField(font, New RectangleF(10, 10,100,200)) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() ' Draws the page number only on the second page If i = 1 Then pageNumber.Page = page pageNumber.Draw(page.Graphics) End If Next i doc.Save("DestinationPageNumberField.pdf"); doc.Close(True) Gets the value of the field at the specified graphics. The graphics. Get and sets the PdfLoadedPage // Loads an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SrcDocument.pdf"); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfDestinationPageNumberField pageNumber = new PdfDestinationPageNumberField(font, new RectangleF(10, 10,100,200)); for (int i = 0; i != doc.Pages.Count; i++) { // Draws the page number only on the second page if (i == 1) { pageNumber.LoadedPage = doc.Pages[1] as PdfLoadedPage; pageNumber.Draw(doc.Pages[1].Graphics); } } doc.Save("DestinationPageNumberField.pdf"); doc.Close(true); ' Loads an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SrcDocument.pdf") Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfDestinationPageNumberField = New PdfDestinationPageNumberField(font, New RectangleF(10, 10,100,200)) For i As Integer = 0 To doc.Pages.Count - 1 ' Draws the page number only on the second page If i = 1 Then pageNumber.LoadedPage = TryCast(doc.Pages(1), PdfLoadedPage) pageNumber.Draw(doc.Pages(1).Graphics) End If Next i doc.Save("DestinationPageNumberField.pdf"); doc.Close(True) Gets or sets the page. The page. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page number field PdfDestinationPageNumberField pageNumber = new PdfDestinationPageNumberField(font); for (int i = 0; i !=2; i++) { PdfPage page = doc.Pages.Add(); // Draws the page number only on the second page if (i == 1) { pageNumber.Page = page; pageNumber.Draw(page.Graphics); } } doc.Save("DestinationPageNumberField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page number field Dim pageNumber As PdfDestinationPageNumberField = New PdfDestinationPageNumberField(font) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() ' Draws the page number only on the second page If i = 1 Then pageNumber.Page = page pageNumber.Draw(page.Graphics) End If Next i doc.Save("DestinationPageNumberField.pdf"); doc.Close(True) Represent automatic field which contains document's author name. // Create a new document PdfDocument doc = new PdfDocument(); // Set the document`s information doc.DocumentInformation.Author = "Syncfusion"; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; PdfDocumentAuthorField documentAuthorField = new PdfDocumentAuthorField(font); for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); documentAuthorField.Draw(page.Graphics); } doc.Save("DocumentAuthorField.pdf"); doc.Close(true); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Set the document`s information doc.DocumentInformation.Author = "Syncfusion" Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim documentAuthorField As PdfDocumentAuthorField = New PdfDocumentAuthorField(font) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() documentAuthorField.Draw(page.Graphics) Next i doc.Save("DocumentAuthorField.pdf") doc.Close(True) Class Initializes a new instance of the class. // Create a new document PdfDocument doc = new PdfDocument(); // Set the document`s information doc.DocumentInformation.Author = "Syncfusion"; PdfDocumentAuthorField documentAuthorField = new PdfDocumentAuthorField(); for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); documentAuthorField.Draw(page.Graphics); } doc.Save("DocumentAuthorField.pdf"); doc.Close(true); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Set the document`s information doc.DocumentInformation.Author = "Syncfusion" Dim documentAuthorField As PdfDocumentAuthorField = New PdfDocumentAuthorField() For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() documentAuthorField.Draw(page.Graphics) Next i doc.Save("DocumentAuthorField.pdf") doc.Close(True) Initializes a new instance of the class with A object that specifies the font attributes (the family name, the size, and the style of the font) to use. // Create a new document PdfDocument doc = new PdfDocument(); // Set the document`s information doc.DocumentInformation.Author = "Syncfusion"; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; PdfDocumentAuthorField documentAuthorField = new PdfDocumentAuthorField(font); for (int i = 0; i!=2; i++) { PdfPage page = doc.Pages.Add(); documentAuthorField.Draw(page.Graphics); } doc.Save("DocumentAuthorField.pdf"); doc.Close(true); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Set the document`s information doc.DocumentInformation.Author = "Syncfusion" Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim documentAuthorField As PdfDocumentAuthorField = New PdfDocumentAuthorField(font) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() documentAuthorField.Draw(page.Graphics) Next i doc.Save("DocumentAuthorField.pdf") doc.Close(True) Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the document`s information doc.DocumentInformation.Author = "Syncfusion"; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; PdfDocumentAuthorField documentAuthorField = new PdfDocumentAuthorField(font, brush); for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); documentAuthorField.Draw(page.Graphics); } doc.Save("DocumentAuthorField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the document`s information doc.DocumentInformation.Author = "Syncfusion" Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim documentAuthorField As PdfDocumentAuthorField = New PdfDocumentAuthorField(font, brush) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() documentAuthorField.Draw(page.Graphics) Next i doc.Save("DocumentAuthorField.pdf") doc.Close(True) Initializes a new instance of the class with and rectangle bounds. A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The bounds. // Create a new document PdfDocument doc = new PdfDocument(); // Set the document`s information doc.DocumentInformation.Author = "Syncfusion"; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; PdfDocumentAuthorField documentAuthorField = new PdfDocumentAuthorField(font, new RectangleF(0, 0, 100, 200)); for (int i = 0; i!= 2; i++) { PdfPage page = doc.Pages.Add(); documentAuthorField.Draw(page.Graphics); } doc.Save("DocumentAuthorField.pdf"); doc.Close(true); ' Create a new document Dim doc As PdfDocument = New PdfDocument() ' Set the document`s information doc.DocumentInformation.Author = "Syncfusion" Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim documentAuthorField As PdfDocumentAuthorField = New PdfDocumentAuthorField(font, New RectangleF(0,0,100,200)) For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() documentAuthorField.Draw(page.Graphics) Next i doc.Save("DocumentAuthorField.pdf") doc.Close(True) Gets the value of the field at the specified graphics. The graphics. Utility class for number conversion. Limit number of converting arabic to \"A\" format. Index of A char in the ASCII table. Converts the specified number to numberStyle format. The arabic value. The number style. Converts arabic number to roman. Number in arabic format. Number in Roman format. Converts arabic number to \"A\" format. Number in arabic format. Number in \"A\" format. Utility metnod for converting arabic number to roman format. Current number value. Max current number. Roman equivalent. Roman equivalent. Utility metnod. Helps to convert arabic number to \"A\" format. Arabic number. Sequence of number. Adds letter instead of number. String builder object. Number to be converted to letter. Represents total PDF document page count automatic field. // Create a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; // Creates page count field PdfPageCountField pageCount = new PdfPageCountField(font); pageCount.NumberStyle = PdfNumberStyle.Numeric; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageCount.Draw(page.Graphics); } doc.Save("PageCountField.pdf"); doc.Close(true); ' Create a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black ' Creates page count field Dim pageCount As PdfPageCountField = New PdfPageCountField(font) pageCount.NumberStyle = PdfNumberStyle.Numeric For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageCount.Draw(page.Graphics) Next i doc.Save("PageCountField.pdf") doc.Close(True); Class Internal variable to store numbering style. Initializes a new instance of the class with . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); // Creates page count field PdfPageCountField pageCount = new PdfPageCountField(font); pageCount.NumberStyle = PdfNumberStyle.Numeric; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageCount.Draw(page.Graphics); } doc.Save("PageCountField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) ' Creates page count field Dim pageCount As PdfPageCountField = New PdfPageCountField(font) pageCount.NumberStyle = PdfNumberStyle.Numeric For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageCount.Draw(page.Graphics) Next i doc.Save("PageCountField.pdf") doc.Close(True); Initializes a new instance of the class with and . A object that specifies the font attributes (the family name, the size, and the style of the font) to use. A object that is used to fill the string. //Creates a new document. PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; //Creates page count field. PdfPageCountField pageCount = new PdfPageCountField(font,brush); pageCount.NumberStyle = PdfNumberStyle.Numeric; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageCount.Draw(page.Graphics); } //Save and close the document. doc.Save("PageCountField.pdf"); doc.Close(true); 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black 'Creates page count field. Dim pageCount As PdfPageCountField = New PdfPageCountField(font) pageCount.NumberStyle = PdfNumberStyle.Numeric For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageCount.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("PageCountField.pdf") doc.Close(True); Initializes a new instance of the class with and rectangle bounds A object that specifies the font attributes (the family name, the size, and the style of the font) to use. The rectangle bounds of the field. //Creates a new document. PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); RectangleF rect = new RectangleF(10, 10, 50, 30); //Creates page count field. PdfPageCountField pageCount = new PdfPageCountField(font,rect); pageCount.NumberStyle = PdfNumberStyle.Numeric; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageCount.Draw(page.Graphics); } //Save and close the document. doc.Save("PageCountField.pdf"); doc.Close(true); 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim rect As RectangleF = New RectangleF(10, 10, 50, 30) 'Creates page count field. Dim pageCount As PdfPageCountField = New PdfPageCountField(font) pageCount.NumberStyle = PdfNumberStyle.Numeric For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageCount.Draw(page.Graphics) Next i 'Save and close the document. doc.Save("PageCountField.pdf") doc.Close(True); Gets the value of the field at the specified graphics. The graphics. result Gets or sets the number style. The number style. // Creates a new document PdfDocument doc = new PdfDocument(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); PdfBrush brush = PdfBrushes.Black; // Creates page count field PdfPageCountField pageCount = new PdfPageCountField(font); pageCount.NumberStyle = PdfNumberStyle.Numeric; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); pageCount.Draw(page.Graphics); } doc.Save("PageCountField.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim brush As PdfBrush = PdfBrushes.Black ' Creates page count field Dim pageCount As PdfPageCountField = New PdfPageCountField(font) pageCount.NumberStyle = PdfNumberStyle.Numeric For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() pageCount.Draw(page.Graphics) Next i doc.Save("PageCountField.pdf") doc.Close(True); Represents an automatic field to display the section number. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates section number field. PdfSectionNumberField sectionNumber = new PdfSectionNumberField(font); sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the section number in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) 'Creates section number field. Dim sectionNumber As New PdfSectionNumberField(font) sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the section number in each page of a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionNumber.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Initializes a new instance of the class. // Creates a new document PdfDocument doc = new PdfDocument(); // Creates section number field PdfSectionNumberField sectionNumber = new PdfSectionNumberField(); sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin; for (int i = 0; i != 2; i++) { PdfPage page = doc.Pages.Add(); sectionNumber.Draw(page.Graphics); } doc.Save("SectionNumberField.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Creates section number field Dim sectionNumber As PdfSectionNumberField = New PdfSectionNumberField() sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin For i As Integer = 0 To 1 Dim page As PdfPage = doc.Pages.Add() sectionNumber.Draw(page.Graphics) Next i doc.Save("SectionNumberField.pdf") Class Initializes a new instance of the class. The font. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Creates section number field. PdfSectionNumberField sectionNumber = new PdfSectionNumberField(font); sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the section number in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) 'Creates section number field. Dim sectionNumber As New PdfSectionNumberField(font) sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the section number in each page of a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionNumber.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Initializes a new instance of the class. The font. The brush. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create a PDF brush. PdfBrush brush = new PdfSolidBrush(Color.Red); //Creates section number field. PdfSectionNumberField sectionNumber = new PdfSectionNumberField(font, brush); sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the section number in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) 'Create a PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Creates section number field. Dim sectionNumber As PdfSectionNumberField = New PdfSectionNumberField(font, brush) sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the section number in each page of a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionNumber.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Initializes a new instance of the class. The font. The bounds. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); RectangleF rect = new RectangleF(10, 10, 30, 10); //Creates section number field within specified bounds. PdfSectionNumberField sectionNumber = new PdfSectionNumberField(font, rect); sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the section number in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) Dim rect As RectangleF = New RectangleF(10, 10, 30, 10) 'Creates section number field within specified bounds. Dim sectionNumber As PdfSectionNumberField = New PdfSectionNumberField(font, rect) sectionNumber.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the section number in each page of a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionNumber.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets the value of the field at the specified graphics. The graphics. The value of the field. Represents an automatic field to display number of pages in section. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create section page count field. PdfSectionPageCountField sectionPageCount = new PdfSectionPageCountField(font); sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the sectionPageCount in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageCount.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Create section page count field. Dim sectionPageCount As New PdfSectionPageCountField(font) sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the sectionPageCount each page in a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageCount.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Initializes a new instance of the class. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create section page count field. PdfSectionPageCountField sectionPageCount = new PdfSectionPageCountField(); sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the sectionPageCount in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageCount.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create section page count field. Dim sectionPageCount As New PdfSectionPageCountField() sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the sectionPageCount each page in a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageCount.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Initializes a new instance of the class with . The font. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create section page count field. PdfSectionPageCountField sectionPageCount = new PdfSectionPageCountField(font); sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the sectionPageCount in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageCount.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Create section page count field. Dim sectionPageCount As New PdfSectionPageCountField(font) sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the sectionPageCount each page in a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageCount.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Initializes a new instance of the class with and . The font. The brush. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create a PDF brush. PdfBrush brush = PdfBrushes.Blue; //Create section page count field. PdfSectionPageCountField sectionPageCount = new PdfSectionPageCountField(font,brush); sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the sectionPageCount in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageCount.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) 'Create a PDF brush. Dim brush As PdfBrush = PdfBrushes.Blue 'Create a PDF brush. Dim sectionPageCount As PdfSectionPageCountField = New PdfSectionPageCountField(font, brush) 'Create section page count field. Dim sectionPageCount As New PdfSectionPageCountField(font) sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the sectionPageCount each page in a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageCount.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with and . The font. The bounds. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create a PDF brush. //Create section page count field. PdfSectionPageCountField sectionPageCount = new PdfSectionPageCountField(font,rect); sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin; //Draw the sectionPageCount in each page of a section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageCount.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f) Dim rect As RectangleF = New RectangleF(10, 10, 30, 30) 'Create section page count field. Dim sectionPageCount As PdfSectionPageCountField = New PdfSectionPageCountField(font, rect) sectionPageCount.NumberStyle = PdfNumberStyle.UpperLatin 'Draw the sectionPageCount each page in a section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageCount.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets the value of the field at the specified graphics. The graphics. result Represents an automatic field to display page number within a section. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create section page number field. PdfSectionPageNumberField sectionPageNumber = new PdfSectionPageNumberField(font); sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman; //Draw the sectionPageNumber in section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) 'Create section page number field. Dim sectionPageNumber As New PdfSectionPageNumberField(font) sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman 'Draw the sectionPageNumber in section. For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageNumber.Draw(page.Graphics) Next i 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Initializes a new instance of the class. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create section page number field. PdfSectionPageNumberField sectionPageNumber = new PdfSectionPageNumberField(); sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman; //Draw the sectionPageNumber in section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section Dim section As PdfSection = document.Sections.Add() 'Create section page number field. Dim sectionPageNumber As New PdfSectionPageNumberField() sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman 'Draw the sectionPageNumber in section For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageNumber.Draw(page.Graphics) Next i 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Initializes a new instance of the class. The font. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create section page number field. PdfSectionPageNumberField sectionPageNumber = new PdfSectionPageNumberField(font); sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman; //Draw the sectionPageNumber in section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section Dim section As PdfSection = document.Sections.Add() 'Create a PDF font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) 'Create section page number field. Dim sectionPageNumber As New PdfSectionPageNumberField(font) sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman 'Draw the sectionPageNumber in section For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageNumber.Draw(page.Graphics) Next i 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Initializes a new instance of the class. The font. The brush. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create a PDF brush. PdfBrush brush = PdfBrushes.Blue; //Create section page number field. PdfSectionPageNumberField sectionPageNumber = new PdfSectionPageNumberField(font,brush); sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman; //Draw the sectionPageNumber in section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section Dim section As PdfSection = document.Sections.Add() 'Create a PDF font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) 'Create a PDF brush. Dim brush As PdfBrush = PdfBrushes.Blue 'Create a PDF brush. 'Create section page number field. Dim sectionPageNumber As New PdfSectionPageNumberField(font,brush) sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman 'Draw the sectionPageNumber in section For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageNumber.Draw(page.Graphics) Next i 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Initializes a new instance of the class. The font. The bounds. //Create a new document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f); //Create section page number field with and PdfSectionPageNumberField sectionPageNumber = new PdfSectionPageNumberField(font); sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman; //Draw the sectionPageNumber in section. for (int i = 0; i != 2; i++) { PdfPage page = section.Pages.Add(); sectionPageNumber.Draw(page.Graphics); } //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add the section Dim section As PdfSection = document.Sections.Add() 'Create a PDF font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F) Dim rect As RectangleF = New RectangleF(10, 10, 30, 30) 'Create section page number field with and . Dim sectionPageNumber As New PdfSectionPageNumberField(font,rect) sectionPageNumber.NumberStyle = PdfNumberStyle.LowerRoman 'Draw the sectionPageNumber in section For i As Integer = 0 To 1 Dim page As PdfPage = section.Pages.Add() sectionPageNumber.Draw(page.Graphics) Next i 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets the value of the field at the specified graphics. The graphics. result Represent class to store information about template and value pairs used in automatic fields. Internal variable to store template. Intenal variable to store value. Initializes a new instance of the class. Initializes a new instance of the class. The template. The value. Gets or sets the template. The template. Gets or sets the value. The value. Each instance of this class represents an bookmark node in the bookmark tree. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Set the destination page. bookmark.Destination = new PdfDestination(page); //Set the destination location. bookmark.Destination.Location = new PointF(20, 20); //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Set the destination page. bookmark.Destination = New PdfDestination(page) 'Set the destination location. bookmark.Destination.Location = New PointF(20, 20) 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. This class plays two roles: it's a base class for all bookmarks and it's a root of a bookmarks tree. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get all the bookmarks. PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //get the bookmark count. int count = bookmarks.Count; //Save and close the document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get all the bookmarks. Dim bookmarks As PdfBookmarkBase = loadedDocument.Bookmarks 'get the bookmark count. Dim count As Integer = bookmarks.Count 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. Collection of the descend outlines. Internal variable to store dictinary. Cross table of the document; Internal variable to store loaded bookmark. Temp variable to store loaded bookmark. Gets or sets the whether the bookmark tree is expanded or not Initializes a new instance of the class. Note that the Type field shouldn't be generated. Initializes a new instance of the class. The dictionary. The cross table. Creates and adds an outline. The title of the new outline. PdfBookmark //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Set the destination page. bookmark.Destination = new PdfDestination(page); //Set the destination location. bookmark.Destination.Location = new PointF(20, 20); //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Set the destination page. bookmark.Destination = New PdfDestination(page) 'Set the destination location. bookmark.Destination.Location = New PointF(20, 20) 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Determines whether the specified outline presents in the collection. The outline. true if the specified outline is in the collection; otherwise, false. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Set the destination page. bookmark.Destination = new PdfDestination(page); //check whether the specified bookmark present in the collection document.Bookmarks.Contains(bookmark); //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Set the destination page. bookmark.Destination = New PdfDestination(page) 'Set the destination location. bookmark.Destination.Location = New PointF(20, 20) 'check whether the specified bookmark present in the collection Dim isBookMarkContained As Boolean = document.Bookmarks.Contains(bookmark) 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Remove the specified bookmark from the document. The title of the outline. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get all the bookmarks. PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //Remove bookmark by bookmark name. bookmarks.Remove("Page 1"); //Save and close the document. loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("input.pdf") 'Get all the bookmarks. Dim bookmarks As PdfBookmarkBase = loadedDocument.Bookmarks 'Remove bookmark by bookmark name. bookmarks.Remove("Page 1") 'Save and close the document. loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. Remove the bookmark from the document at the specified index. The index. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get all the bookmarks. PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //Remove bookmark by index. bookmarks.RemoveAt(0); //Save and close the document. loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("input.pdf") 'Get all the bookmarks. Dim bookmarks As PdfBookmarkBase = loadedDocument.Bookmarks 'Remove bookmark by index. bookmarks.RemoveAt(0) 'Save and close the document. loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. Removes all the bookmark from the collection. //Load the PDF document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get the bookmarks PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //Remove all the bookmarks form the collection bookmarks.Clear(); //Save and close the PDF document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get the Bookmarks Dim Bookmarks As PdfAttachmentCollection = loadedDocument.Bookmarks 'Remove all the bookmarks form the collection Bookmarks.Clear() 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. Inserts a new outline at the specified index. The index. The title of the new outline. The new outline. /// //Create a new document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Insert a new bookmark in the existing bookmark collection. PdfBookmark bookmark = loadedDocument.Bookmarks.Insert(1, "New bookmark 2"); //Set the destination page and location. bookmark.Destination = new PdfDestination(loadedDocument.Pages[1]); bookmark.Destination.Location = new PointF(0, 300); //Save and close the PDF document. loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Create a new document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Insert a new bookmark in the existing bookmark collection. Dim bookmark As PdfBookmark = loadedDocument.Bookmarks.Insert(1, "New bookmark 2") 'Set the destination page and location. bookmark.Destination = New PdfDestination(loadedDocument.Pages(1)) bookmark.Destination.Location = New PointF(0, 300) 'Save and close the PDF document. loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. To get the BookMark Collection Dispose bookmark collection Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Reproduces the tree. The list of bookmark kids. Updates all outline dictionary fields. Gets the first book mark. The bookmark. First Bookmark Gets number of the elements in the collection. Read-Only. The value which contains count of the collection.> //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get all the bookmarks. PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //get the bookmark count. int count = bookmarks.Count; //Save and close the document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get all the bookmarks. Dim bookmarks As PdfBookmarkBase = loadedDocument.Bookmarks 'get the bookmark count. Dim count As Integer = bookmarks.Count 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class. Gets the at the specified index. Read-Only. The PdfBookmark object returns from the collection by index. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get all the bookmarks. PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //Get the first bookmark and change the properties of the bookmark. PdfLoadedBookmark bookmark = bookmarks[0] as PdfLoadedBookmark; bookmark.Destination = new PdfDestination(loadedDocument.Pages[1]); bookmark.Color = Color.Green; bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Title = "Changed title"; //Save the document loadedDocument.Save("Output.pdf"); //Close the document loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get all the bookmarks. Dim bookmarks As PdfBookmarkBase = document.Bookmarks 'Get the first bookmark and change the properties of the bookmark. Dim bookmark As PdfLoadedBookmark = TryCast(bookmarks(0), PdfLoadedBookmark) bookmark.Destination = New PdfDestination(loadedDocument.Pages(1)) bookmark.Color = Color.Green bookmark.TextStyle = PdfTextStyle.Bold bookmark.Title = "Changed title" 'Save the document loadedDocument.Save("Output.pdf") 'Close the document loadedDocument.Close(True) Class. Class. Gets the sub items. Gets the dictionary. The dictionary. Gets the cross table. Gets or sets the whether to expand the node or not Gets the element. Internal variable to store destination. Internal variable to store named destination. Internal variable to store color. Internal variable to store text Style. Internal variable to store previous. Internal variable to store next. Internal variable to store parent. Internal variable to store action. Initializes a new instance of the class. The title to be displayed. The parent. The previous. The next. Initializes a new instance of the class. The title. The parent. The previous. The next. The destination. Initializes a new instance of the class. The dictionary. The cross table. Sets the parent. The parent. Updates the color. Updates the outline text style. Gets or sets the outline title. A string value which contains the bookmark title The outline title is the text, which appears in the outline tree as a tree node. /// //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Set the destination page. bookmark.Destination = new PdfDestination(page); //Set the destination location. bookmark.Destination.Location = new PointF(20, 20); //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Set the Bookmark Title. bookmark.Title = "Bookmark"; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Set the destination page. bookmark.Destination = New PdfDestination(page) 'Set the destination location. bookmark.Destination.Location = New PointF(20, 20) 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Set the bookmark title. bookmark.Title = "Bookmark" 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Class. Gets or sets the whether to expand the node or not. true If the bookmark is expanable , otherwise false. > //Create a new document. PdfDocument Document = new PdfDocument(); //Add a page. PdfPage page = Document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = Document.Bookmarks.Add("page1"); //Set color. bookmark.Color = Color.Red; bool expand = bookmark.IsExpanded; //Create a Uri action PdfUriAction uriAction = new PdfUriAction("http://www.google.com"); //Set the Uri action bookmark.Action = uriAction; //Save and close the PDF document. Document.Save("Output.pdf"); Document.Close(true); 'Create a new document. Dim Document As New PdfDocument() 'Add a page. Dim page As PdfPage = Document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = Document.Bookmarks.Add("page1") 'Set color. bookmark.Color = Color.Red bool expand = bookmark.IsExpanded 'Create a Uri action Dim uriAction As New PdfUriAction("http://www.google.com") 'Set the Uri action bookmark.Action = uriAction 'Save and close the PDF document. Document.Save("Output.pdf") Document.Close(True) Class. Class. Gets or sets the previous outline object. The null value means that the object is the first outline. Gets the parent outline base. Gets or sets the next outline object. The null value means that the object is the last outline. Initializes a new instance of the class. The dictionary. The cross table. Gets the title. The title of the bookmark. Gets the unicodestring Gets the color. The color of the bookmark. Gets the text style. The style of bookmark text. Gets the next. The next bookmark to this bookmark. Gets the previos. The previous bookmark to this bookmark. Sets the color. The color. Sets the text style. The value. Gets the destination. The destination of bookmark. Check page have any rotation and set top value for bookmark destionation Gets or sets the outline title. The string value which contains title of the bookmark.> The outline title is the text, which appears in the outline tree as a tree node. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get all the bookmarks. PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //Get the first bookmark and set the properties of the bookmark. PdfLoadedBookmark bookmark = bookmarks[0] as PdfLoadedBookmark; bookmark.Destination = new PdfDestination(loadedDocument.Pages[1]); bookmark.Color = Color.Green; bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Title = "Changed title"; //Save the document loadedDocument.Save("Output.pdf"); //Close the document loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get all the bookmarks. Dim bookmarks As PdfBookmarkBase = document.Bookmarks 'Get the first bookmark and set the properties of the bookmark. Dim bookmark As PdfLoadedBookmark = TryCast(bookmarks(0), PdfLoadedBookmark) bookmark.Destination = New PdfDestination(loadedDocument.Pages(1)) bookmark.Color = Color.Green bookmark.TextStyle = PdfTextStyle.Bold bookmark.Title = "Changed title" 'Save the document loadedDocument.Save("Output.pdf") 'Close the document loadedDocument.Close(True) Class Class Gets or sets the next outline object. The null value means that the object is the last outline. Gets or sets the previous outline object. The null value means that the object is the first outline. Gets the parent outline base. Gets the sub items. Allows to choose outline text style. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Get all the bookmarks. PdfBookmarkBase bookmarks = loadedDocument.Bookmarks; //Get the first bookmark and set the properties of the bookmark. PdfLoadedBookmark bookmark = bookmarks[0] as PdfLoadedBookmark; bookmark.Destination = new PdfDestination(loadedDocument.Pages[1]); bookmark.Color = Color.Green; bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Title = "Changed title"; //Save the document loadedDocument.Save("Output.pdf"); //Close the document loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get all the bookmarks. Dim bookmarks As PdfBookmarkBase = document.Bookmarks 'Get the first bookmark and set the properties of the bookmark. Dim bookmark As PdfLoadedBookmark = TryCast(bookmarks(0), PdfLoadedBookmark) bookmark.Destination = New PdfDestination(loadedDocument.Pages(1)) bookmark.Color = Color.Green bookmark.TextStyle = PdfTextStyle.Bold bookmark.Title = "Changed title" 'Save the document loadedDocument.Save("Output.pdf") 'Close the document loadedDocument.Close(True) Class Class Class Regular text style. Italic text style. Bold text style. Represents a booklet creator, which allows to create a booklet from a PDF document. //Load a PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("SourceDoc.pdf"); //Creates a booklet from the given PDF document. PdfDocument doc = PdfBookletCreator.CreateBooklet(ldoc, new SizeF(300, 500)); //Save the document. doc.Save("Booklet.pdf"); //Close the document. doc.Close(true); 'Load a PDF document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") 'Creates a booklet from the given PDF document. Dim doc As PdfDocument = PdfBookletCreator.CreateBooklet(ldoc, New SizeF(300, 500)) 'Save the document. doc.Save("Booklet.pdf") 'Close the document. doc.Close(True); Initializes a new instance of the class. Initializes a new instance of the class with and page size. The existing PDF document. Size of the page. The initialized PDF document, which could be saved. //Load a PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("SourceDoc.pdf"); // Creates a booklet from the given PDF document. PdfDocument doc = PdfBookletCreator.CreateBooklet(ldoc, new SizeF(300, 500)); //Save the document. doc.Save("Booklet.pdf"); //Close the documents. doc.Close(true); ldoc.Close(true); 'Load a PDF document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") 'Creates a booklet from the given PDF document. Dim doc As PdfDocument = PdfBookletCreator.CreateBooklet(ldoc, New SizeF(300, 500)) 'Save the document. doc.Save("Booklet.pdf") 'Close the documents. doc.Close(True) ldoc.Close(True) Initializes a new instance of the class with source path,destination,page size and flag to set two side print. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight The path to the file on the disk, which the booklet should be created from. The path to the file on the disk, which the booklet should be saved into. Size of the page. if set to true if the result in document should be printed on both sides of paper. //Load a PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("SourceDoc.pdf"); //Create booklet with two sides. PdfDocument doc = PdfBookletCreator.CreateBooklet("SourceDocument.pdf","Booklet.pdf",new SizeF(300, 500), true); 'Load a PDF document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") 'Create booklet with two sides. Dim doc As PdfDocument = PdfBookletCreator.CreateBooklet("SourceDocument.pdf","Booklet.pdf",New SizeF(300, 500), true) 'Save the document. doc.Save("Booklet.pdf") 'Close the documents. doc.Close(True) ldoc.Close(True) Initializes a new instance of the class with source PDF path,destination file name and page size. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight The path to the file on the disk, which the booklet should be created from. The path to the file on the disk, which the booklet should be saved into. Size of the page. The initialized PDF document, which could be saved. //Creates a booklet from the given PDF document. PdfDocument doc = PdfBookletCreator.CreateBooklet("SourceDocument.pdf","Booklet.pdf",new SizeF(300, 500)); //Save the document. doc.Save("Booklet.pdf"); //Close the documents. doc.Close(true); ldoc.Close(true); 'Load a PDF document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") 'Creates a booklet from the given PDF document. Dim doc As PdfDocument = PdfBookletCreator.CreateBooklet(ldoc, New SizeF(300, 500)) 'Save the document. doc.Save("Booklet.pdf") 'Close the document. doc.Close(True) ldoc.Close(True) Initializes a new instance of the class , page size and flag to set two side print. The . Size of the page. if set to true if the result in document should be printed on both sides of paper. The initialized PDF document, which could be saved. //Load a PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("SourceDoc.pdf"); //Creates a booklet from the given PDF document. PdfDocument doc = PdfBookletCreator.CreateBooklet(ldoc, new SizeF(300, 500), false); //Save the document. doc.Save("Booklet.pdf"); //Close the documents. doc.Close(true); ldoc.Close(true); 'Load a PDF document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") 'Creates a booklet from the given PDF document. Dim doc As PdfDocument = PdfBookletCreator.CreateBooklet(ldoc, New SizeF(300, 500), False) 'Save the document. doc.Save("Booklet.pdf") 'Close the document. doc.Close(True) ldoc.Close(True) Initializes a new instance of the class. The Size of the page. if set to true if the result in document should be printed on both sides of paper. The margin value for generated PDF document. The initialized PDF document, which could be saved. //Loads an existing document. PdfLoadedDocument srcDoc = new PdfLoadedDocument("sourceDoc.pdf"); //Specify the margin. PdfMargins margin = new PdfMargins(); margin.All = 10; //Creates a booklet from the given PDF document. PdfDocument doc = PdfBookletCreator.CreateBooklet(srcDoc,new SizeF(300, 500), false,margin); //Save the document. doc.Save("Booklet.pdf"); //Close the documents. doc.Close(true); srcDoc.Close(true); 'Loads an existing document. Dim srcDoc As PdfLoadedDocument = New PdfLoadedDocument("sourceDoc.pdf") 'Specify the margin. Dim margin As PdfMargins = New PdfMargins() margin.All = 10 'Creates a booklet from the given PDF document. Dim doc As PdfDocument = PdfBookletCreator.CreateBooklet(srcDoc,New SizeF(300, 500), False,margin) 'Save the document doc.Save("Booklet.pdf") 'Close the documents. doc.Close(True) srcDoc.Close(True) Gets the next pair of page indeces. The current iteration index. The pages count. if set to true if the result in document should be printed on both sides of paper. An array of integers that holds the indices. Represents internal catalog of the Pdf document. Class Defines the basic interace of the various Primitive.. Saves the object using the specified writer. The writer. Creates a deep copy of the IPdfPrimitive object. Specfies the status of the IPdfPrmitive. Status is registered if it has a reference or else none. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Stores the cloned object for future use. Gets or sets the position of the object. Interface of the objects that support Changable of their internals. Freezes the changes. The freezer. Gets a value indicating whether this is changed. true if changed; otherwise, false. Start marker for dictionary. End marker for dictionary. Collection of items in the object. Flag for PDF file formar 1.5 is dictionary archiving needed. Flag is dictionary need to encrypt. Flag is dictionary need to decrypt. Indicates if the object was changed. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Internal variable to hold PdfCrossTable reference. Internal variable to hold cloned object. Represents the XFA dictionary indicates whether the dictionary is rendered or not. Represents the Font dictionary. Initializes a new empty instance of the class. Initializes a new instance of the class with values taken from the dictionary. The dictionary. Determines whether the dictionary contains key. The key. true if the dictionary contains key; otherwise, false. Determines whether the dictionary contains the key. The key. true if the dictionary contains the key; otherwise, false. Removes the specified key. The key. Removes the specified key. The key. Clears items from object dictionary. Creates a copy of PdfDictionary. Gets a value from itself or one of the parent dictionaries. The cross table. The key of the value. The key to the parent. The value by the key. Gets a value from itself or one of the parent dictionaries. The key of the value. The key to the parent. The value by the key. Returns the string specified by the propertyName parameter. Name of the property. The string by its name. Returns the integer value of the dictionary entry specified by the propertyName variable. Name of the property. The integer value of the property. Save dictionary items. Writer object. Creates a PDF name object. The string which the object is initialized with. The PDF object. Raises event . Event arguments. Raises event . Event arguments. Saves the object using the specified writer. The writer. Saves the object. Writer object. If true - raises the event, False - doesn't raise. Sets the internal property. The key. The primitive. Sets the internal property. The PdfName. The primitive. Sets the internal property. The key. The wrapper. Sets the property. The dictionary. The key. The wrapper. Sets the property. The dictionary. The key. The primitive. Sets the boolean. The key. Boolean value. Sets the integer number. The key. The value. Sets the float number. The key. The value. Sets the array. The key. The list of primitives to be placed into array. Sets the date time. The key. The date time. Gets the date time from Pdf standard date format. The string, which contains Pdf standard date format. The time in Sets the string primitive. The key. The string. Sets the name. The dictionary. The key. The name. Sets the name primitive. The key. The name. Sets the name. The key. The name. Determines whether to process special characters. Checks the changes. Returns true if the dictionary was changed. Freezes the changes. The freezer. Mark this instance modified. Gets or sets the with the specified key. Gets or sets the with the specified key. Gets the count. Gets the values. Get or set flag if need to archive dictionary. Gets or sets flag if encryption is needed. Gets or sets flag if decryption is needed. Gets the keys. Gets the items. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Returns PdfCrossTable associated with the object. Returns cloned object. Represents the Font dictionary Event. Raise before the object saves. Event. Raise after the object saved. Gets a value indicating whether this is changed. true if changed; otherwise, false. Internal variable to store collection of sections. Internal variable to store collection of attachments Internal variable to store viewer's preferences. Internal variable to store catalog's names. The metadata of the stream. Internal variable to store form. Loaded form. Loaded document. Internal variable to store dictionary; Internal variable to store portfolio No Names Internal variable to store StructTreeRoot. Initializes a new instance of the class. Initializes a new instance of the class. The document. The catalog dictionary. Creates the names if there is none. Initializes struct tree root. Reads Xmp from the document. Applies the PDF/X Conformance attributes to the document. Clear PdfCatalog Gets or sets the viewer preferences. The viewer preferences. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Set the document`s viewer preference. doc.ViewerPreferences.PageMode = PdfPageMode.UseAttachments; doc.ViewerPreferences.PageScaling = PageScalingMode.None; doc.ViewerPreferences.FitWindow = true; doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage; // Save the document doc.Save("ViewerPreferences.pdf"); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() ' Set the document`s viewer preference doc.ViewerPreferences.PageMode = PdfPageMode.UseAttachments doc.ViewerPreferences.PageScaling = PageScalingMode.None doc.ViewerPreferences.FitWindow = True doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage ' Save the document doc.Save("ViewerPreferences.pdf") Gets or setsthe Pdfportfolio Returns StructTreeRoot associated with the document. Gets or sets the interactive form. The form. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); // Creates a form PdfForm form = document.Form; PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; //Add the items to the list box listBox.Items.Add(new PdfListFieldItem("English", "English")); listBox.Items.Add(new PdfListFieldItem("French", "French")); listBox.Items.Add(new PdfListFieldItem("German", "German")); //Select the item listBox.SelectedIndex = 2; //Set the multiselect option listBox.MultiSelect = true; document.Save("Form.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() ' Creates a form Dim form As PdfForm = document.Form Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline 'Add the items to the list box listBox.Items.Add(New PdfListFieldItem("English", "English")) listBox.Items.Add(New PdfListFieldItem("French", "French")) listBox.Items.Add(New PdfListFieldItem("German", "German")) 'Select the item listBox.SelectedIndex = 2 'Set the multiselect option listBox.MultiSelect = True document.Save("Form.pdf") Gets the names. The names. Gets the named destinations' dictionary. Gets or sets the loaded form. Gets or sets the loaded Document. Gets or sets the sections, which contain pages. Gets or sets the loaded form. Gets or sets the metadata. The metadata. Represents names dictionary of the document's catalog entry. Interface Internal variable to store collection of attachments. Internal variable to store dictionary. Initializes a new instance of the class. Initializes a new instance of the class. The root. Gets the named object from a tree. The tree root. The name. The named object. Finds the name in the tree. The current. The name. The object specified by its name or null. Gets the proper kid from an array. The current node. The name we're looking for. The proper kid. The name should be within the kid limits. Checks the limits of the named tree node. The kid. The name. Returns true if the kid should have the name (the name is within its limits). Merges the embedded name trees. The names. Appends the list of embedded file dictionaries. The list. Gets the node left limit. The node. The node left limit. Appends the objects to the node of the name tree. Name of the base. The node. The embedded. if set to true the limits should be updated. To be sorted attachment name and update the current document Catalog.Names Note: If the attachment not store in sorted order,the attachments are not open. Check and update unique name as attachment merge Generates the list of embedded file dictionaries. The list of embedded file dictionaries. Collects the objects. The leaf node. The array. Clear catalog names. Gets or sets the embedded files. The embedded files. Gets the destinations. Gets the element. Holds info about current base node and its current child. Internal variable to store Dictionary entry. Internal variable to store index value. Internal variable to store dictionary entries count. Internal variable to store Kids value. Initializes a new instance of the class. The node. Initializes a new instance of the class. The index. The count. Contains types used to create and manipulate the PDF document. Represents a PDF document and can be used to create a new PDF document from the scratch To know more about refer this link . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); //Save the document. document.Save("Document.pdf"); //Close the document. document.Close(true); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = document.Pages.Add() 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) 'Save the document. document.Save("Document.pdf"); 'Close the document. document.Close(True) Class Class Class Class Class Represent common properties of PdfDocument and PdfLoadedDocument classes. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference doc.ViewerPreferences.PageLayout = PdfPageLayout.TwoPageLeft; doc.ViewerPreferences.PageScaling = PageScalingMode.AppDefault; doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; doc.Save("ViewerPreferences.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference doc.ViewerPreferences.PageLayout = PdfPageLayout.TwoPageLeft doc.ViewerPreferences.PageScaling = PageScalingMode.AppDefault doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen doc.Save("ViewerPreferences.pdf") 'Close the document doc.Close(True) Class Class Collection of the main objects. internal variable to store locked array Security properties. Object that is saving currently. Document catlog. Cross table. Document information and properties. String contain either user or owner password. Dictionary used to get the collection of images for extraction. Desired level of the new stream compression. Specifies file structure. A list of the objects that have to be disposed after document closing. Internal variable to store if memory optimization should be done. Internal varible to store portfolio Internal variable to store OCG groups. Internal variable to store position. Internal variable to store order position. Internal variable to store on position. Internal variable to store off position. Internal variable to store layer order. Internal variable to store visible layers. Internal variable to store invisible layers. Internal variable to store Sub Layers. Internal variable to store Sub Layers Position. Stores the array of Print layer references Specifies the document should be compressed in best. Specifies the document is merging. Specifies the collection of layer in document The delegade of the progress event handler. Variable used to maintain fields have kids in imported page Variable used to maintain fields are added in Form Field collection in imported PDF The variable used to store the Optimized dictionary collection variable used to maintain layers in loaded document If PDF is set as tagged, initializes StructTree in the catalog. Merges the specified source documents with PdfMergeOptions and return destination document. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight The destination document, where the other documents are merged into. If it's null a new document object will be created. customize the merging PDF. The options contain Optimizing resources. The source documents. The document containing merged documents. // Destination PDF document PdfDocument destDoc = new PdfDocument(); // Source PDF documents string[] source = { "Src1.pdf", "Src2.pdf" }; PdfMergeOptions option = new PdfMergeOptions(); option.OptimizeResources = true; //Merge the source pdf document. PdfDocumentBase.Merge(destDoc, option, source); destDoc.Save("Merge.pdf"); ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() ' Source PDF documents Dim [option] As PdfMergeOptions = New PdfMergeOptions() [option].OptimizeResources = True PdfDocumentBase.Merge(destDoc, [option], source) 'Merge the source pdf document. PdfDocumentBase.Merge(destDoc, source) destDoc.Save("Merge.pdf") Class Merges the specified source documents and return destination document. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight The destination document, where the other documents are merged into. If it's null a new document object will be created. The source documents. The document containing merged documents. // Destination PDF document PdfDocument destDoc = new PdfDocument(); // Source PDF documents string[] source = { "Src1.pdf", "Src2.pdf" }; //Merge the source pdf document. PdfDocumentBase.Merge(destDoc, source); destDoc.Save("Merge.pdf"); ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() ' Source PDF documents Dim source() As String = { "Src1.pdf", "Src2.pdf" } 'Merge the source pdf document. PdfDocumentBase.Merge(destDoc, source) destDoc.Save("Merge.pdf") Class Merges the PDF documents specified by the paths with PdfMergeOptions. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight The array of string paths. A new PDF document containing all merged documents. customize the merging PDF. The options contain Optimizing resources. // Destination PDF document PdfDocument destDoc = new PdfDocument(); // Source PDF documents string[] source = { "Src1.pdf", "Src2.pdf" }; PdfMergeOptions option = new PdfMergeOptions(); option.OptimizeResources = true; //Merge the source pdf document. destDoc = PdfDocument.Merge(source, option); destDoc.Save("Merge.pdf"); ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() ' Source PDF documents Dim source() As String = { "Src1.pdf", "Src2.pdf" } 'Merge the source pdf document. Dim [option] As PdfMergeOptions = New PdfMergeOptions() [option].OptimizeResources = True destDoc = PdfDocument.Merge(source, [option]) destDoc.Save("Merge.pdf") Class Merges the PDF documents specified by the paths. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight The array of string paths. A new PDF document containing all merged documents. // Destination PDF document PdfDocument destDoc = new PdfDocument(); // Source PDF documents string[] source = { "Src1.pdf", "Src2.pdf" }; //Merge the source pdf document. destDoc = PdfDocument.Merge(source); destDoc.Save("Merge.pdf"); ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() ' Source PDF documents Dim source() As String = { "Src1.pdf", "Src2.pdf" } 'Merge the source pdf document. destDoc = PdfDocument.Merge(source) destDoc.Save("Merge.pdf") Class Merges the specified dest. The destination document. The source document. The merged document // Source document. PdfLoadedDocument srcDoc = new PdfLoadedDocument("Src1.pdf"); // Destination PDF document PdfDocument destDoc = new PdfDocument(); //Merge the source pdf document. PdfDocumentBase.Merge(destDoc, srcDoc); destDoc.Save("Merge.pdf"); ' Source document. Dim srcDoc As PdfLoadedDocument = New PdfLoadedDocument("Src1.pdf") ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() 'Merge the source pdf document. PdfDocumentBase.Merge(destDoc, srcDoc) destDoc.Save("Merge.pdf") Class Adds an object to a collection of the objects that will be disposed during document closing. The object that will be disposed during document closing. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image Image img = Image.FromFile("input.png"); PdfImage pdfImg = new PdfBitmap(img); //Draw the image g.DrawImage(pdfImg,20, 20, 100,200); doc.Save("DisposeOnClose.pdf"); // Dispose the Img object along with the document. doc.DisposeOnClose(img); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim img As Image = Image.FromFile("Logo.png") Dim pdfImg As PdfImage = New PdfBitmap(img) 'Draw the image g.DrawImage(pdfImg,20, 20, 100,200) doc.Save("DisposeOnClose.pdf") ' Dispose the Img object along with the document. doc.DisposeOnClose(img) 'Close the document doc.Close(True) Class Class Class Saves the document to the specified filename. The name of the file where to save the document. It can be a full path or a relative path. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image PdfImage pdfImg = new PdfBitmap(Image.FromFile("Logo.png")); //Draw the image g.DrawImage(pdfImg,20, 20, 100,200); doc.Save("SaveExample.pdf"); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim pdfImg As PdfImage = New PdfBitmap(Image.FromFile("Logo.png")) 'Draw the image g.DrawImage(pdfImg,20, 20, 100,200) doc.Save("SaveExample.pdf") Saves the document into a HTTP response stream. The name of the document. The HTTP response stream object. The type of the reading document. If a document containing digital signature needs to be saved then the destination stream must support seeking, otherwise an exception will be raised. Since the HTTP response stream does not support seeking please write the document to a memory stream first and then flush it to the destination stream to avoid raising an exception. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image PdfImage pdfImg = new PdfBitmap(Image.FromFile("Logo.png")); //Draw the image g.DrawImage(pdfImg,20, 20, 100,200); doc.Save("SaveExample.pdf", Response, HttpReadType.Open); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim pdfImg As PdfImage = New PdfBitmap(Image.FromFile("Logo.png")) 'Draw the image g.DrawImage(pdfImg,20, 20, 100,200) doc.Save("SaveExample.pdf", Response, HttpReadType.Open) 'Close the document doc.Close(True) Class Class Saves the document into a HTTP response stream. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight The stream where to save the PDF document. The HTTP response stream object. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image PdfImage pdfImg = new PdfBitmap(Image.FromFile("Logo.png")); //Draw the image g.DrawImage(pdfImg,20, 20, 100,200); MemoryStream stream = new MemoryStream(); // Save the document as a stream doc.Save(stream, Response); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim pdfImg As PdfImage = New PdfBitmap(Image.FromFile("Logo.png")) 'Draw the image g.DrawImage(pdfImg,20, 20, 100,200) Dim stream As MemoryStream = New MemoryStream() ' Save the document as a stream doc.Save(stream, Response) 'Close the document doc.Close(True) Class Class Closes the document. Releases all common resources. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image PdfImage pdfImg = new PdfBitmap(Image.FromFile("Logo.png")); //Draw the image g.DrawImage(pdfImg,20, 20, 100,200); //Save the document doc.Save("Close.pdf"); //Close the document doc.Close(); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim pdfImg As PdfImage = New PdfBitmap(Image.FromFile("Logo.png")) 'Draw the image g.DrawImage(pdfImg,20, 20, 100,200) 'Save the document doc.Save("Close.pdf") ' Closes the document doc.Close() Class Class Closes the document. if set to true the document should close its stream as well. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image PdfImage pdfImg = new PdfBitmap(Image.FromFile("Logo.png")); //Draw the image g.DrawImage(pdfImg,20, 20, 100,200); //Save the document doc.Save("Close.pdf"); // Closes the document completely. doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim pdfImg As PdfImage = New PdfBitmap(Image.FromFile("Logo.png")) 'Draw the image g.DrawImage(pdfImg,20, 20, 100,200) 'Save the document doc.Save("Close.pdf") ' Closes the document completely. doc.Close(True) Class Class Saves the document to the specified output stream. The stream object where PDF document will be saved. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image PdfImage pdfImg = new PdfBitmap(Image.FromFile("Logo.png")); //Draw the image g.DrawImage(pdfImg, 20, 20, 100, 200); // Save the document as a stream MemoryStream stream = new MemoryStream(); doc.Save(stream); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim pdfImg As PdfImage = New PdfBitmap(Image.FromFile("Logo.png")) 'Draw the image g.DrawImage(pdfImg, 20, 20, 100, 200) ' Save the document as a stream Dim stream As MemoryStream = New MemoryStream() doc.Save(stream) Class Class Imports the specified page into the current document pages collection The loaded document to be imported. The page to be inserted. The page in the target document. The loaded document must remain open until the current document is saved // Source document PdfLoadedDocument srcDoc = new PdfLoadedDocument("SrcDocument.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); // Importing pages from source document. doc.ImportPage(srcDoc, srcDoc.Pages[0]); doc.Save("ImportPages.pdf"); //Close both the instance doc.Close(true); srcDoc.Close(true); ' Source document Dim srcDoc As PdfLoadedDocument = New PdfLoadedDocument("SrcDocument.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() ' Importing pages from source document. doc.ImportPage(srcDoc, srcDoc.Pages(0)) doc.Save("ImportPages.pdf") 'Close both the instance doc.Close(True) srcDoc.Close(True) Class Class Imports the loaded document's page index to the current document. The loaded document to be imported. Index of the page. The page in the target document. The loaded document must remain open until the current document is saved // Source document PdfLoadedDocument srcDoc = new PdfLoadedDocument("SrcDocument.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); // Importing pages from source document. doc.ImportPage(srcDoc, 0); doc.Save("ImportPages.pdf"); //Close both the instance doc.Close(true); srcDoc.Close(true); ' Source document Dim srcDoc As PdfLoadedDocument = New PdfLoadedDocument("SrcDocument.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() ' Importing pages from source document. doc.ImportPage(srcDoc, 0) doc.Save("ImportPages.pdf") 'Close both the instance doc.Close(True) srcDoc.Close(True) Class Class Imports a page range from a loaded document to the current document The loaded document to be imported. The start page index. The end page index. The last created page in the target document. The loaded document must remain open until the current document is saved // Source document PdfLoadedDocument srcDoc = new PdfLoadedDocument("SrcDocument.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); // Importing pages from source document. doc.ImportPageRange(srcDoc, 0, 2); doc.Save("ImportPages.pdf"); //Close both the instance doc.Close(true); srcDoc.Close(true); ' Source document Dim srcDoc As PdfLoadedDocument = New PdfLoadedDocument("SrcDocument.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() ' Importing pages from source document. doc.ImportPageRange(srcDoc, 0, 2) doc.Save("ImportPages.pdf") 'Close both the instance doc.Close(True) srcDoc.Close(True) Class Class Imports a page range from a loaded document to the current document The loaded document to be imported. The start page index. The end page index. Gets value whether to import bookmarks from the imported page. The last created page in the target document. The loaded document must remain open until the current document is saved // Source document PdfLoadedDocument srcDoc = new PdfLoadedDocument("SrcDocument.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); // Importing pages from source document without bookmarks. doc.ImportPageRange(srcDoc, 0, 2, false); doc.Save("ImportPages.pdf"); //Close both the instance doc.Close(true); srcDoc.Close(true); ' Source document Dim srcDoc As PdfLoadedDocument = New PdfLoadedDocument("SrcDocument.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() ' Importing pages from source document. doc.ImportPageRange(srcDoc, 0, 2, true) doc.Save("ImportPages.pdf") 'Close both the instance doc.Close(True) srcDoc.Close(True) Appends the loaded document given as parameter to the current document. The loaded document to be imported. The appended loaded document must remain open until the current document is saved. // Source document PdfLoadedDocument srcDoc = new PdfLoadedDocument("SrcDocument.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); // Appending the document with source document. doc.Append(srcDoc); // Save the document. doc.Save("Append.pdf"); //close both the instance doc.Close(true); srcDoc.Close(true); ' Source document Dim srcDoc As PdfLoadedDocument = New PdfLoadedDocument("SrcDocument.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() ' Appending the document with source document. doc.Append(srcDoc) ' Save the document. doc.Save("Append.pdf") 'Close bothe the instance doc.Close(True) srcDoc.Close(True) Class Class Checks whether the PDF document was encrypted. True if the document was encrypted. Called when a page is saved. The page. Raises the Progress event. The instance containing the event data. Gets the form. The proper PdfForm instance. Sets the main object collection. The main object collection. Allows to use null values as the parameter, which causes assigning null value to the variable. That's used for clearing. Sets the security object. The security. Allows to set null. Sets the cross table. The cross table. Sets the catalog. The catalog. Raises DocumentSaved event. Event arguments. Adds the fields connected to the page. The loaded document. The new page. The lost of the fields. Clones pages and their resource dictionaries and adds them into the document. The loaded document. The page being cloned. The destinations. page Checks form fields are connected with the page. The loaded document. The page. An array where the fields connected to the page are stored. Merges the attachments. The loaded document. This method merges only named attachments. Get the Named Destination Get the Destination Exports the bookmarks to the new document. The loaded document. The bookmarks. The page correspondance dictionary. Marks the bookmarks pointing to the page for exporting. The page bookmarks. The bookmarks. Marks the bookmarks pointing to the page for exporting. The page bookmarks. The bookmarks. Fixes the destinations. The page correspondance. The destinations. Resets the progress mechanism. Sets the progress mechanism. Create hash value from the current stream Get a hash algorithm based on FIPS mode Event. Rises when the document has been saved. Occurs when the document is being saved. This event raised on saving the document. It will keep track of the save progress of the document. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add new pages to the document. PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); document.SaveProgress += new PdfDocument.ProgressEventHandler(document_SaveProgress); //Saves the document document.Save("Document.pdf"); //Close the document document.Close(true); // Event handler for PageAdded event void document_SaveProgress(object sender, ProgressEventArgs arguments) { MessageBox.Show(String.Format("Current: {0}, Progress: {1}, Total {2}", arguments.Current, arguments.Progress, arguments.Total)); } 'Create a new PDF document. Private document As PdfDocument = New PdfDocument() 'Add new pages to the document. Private page As PdfPage = document.Pages.Add() 'Create font and font style. Private font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) AddHandler document.SaveProgress, AddressOf document_SaveProgress 'Saves the document document.Save("Document.pdf") 'Close the document document.Close(True) ' Event handler for PageAdded event Private Sub document_SaveProgress(ByVal sender As Object, ByVal arguments As ProgressEventArgs) MessageBox.Show(String.Format("Current: {0}, Progress: {1}, Total {2}", arguments.Current, arguments.Progress, arguments.Total)) End Sub Delegate Gets the security features of the document like encryption. To know more about refer this link . //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Reading security settings of the document PdfSecurity security = doc.Security; doc.Save("Security.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() ' Reading security settings of the document Dim security As PdfSecurity = doc.Security doc.Save("Security.pdf") 'Close the document doc.Close(True) Class Class Gets a value indicating whether this instance is security granted. true if this instance is security granted; otherwise, false. Gets or sets document's information and properties such as document's title, subject, keyword etc. To know more about refer this link . //Create new pdf document. PdfDocument document = new PdfDocument(); //Set the document author property. document.DocumentInformation.Author = "Syncfusion"; //Get the document author property value. string author = document.DocumentInformation.Author; //Save and close the document. document.Save("output.pdf"); document.Close(true); //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("output.pdf"); //Get the loaded document author property value. author = ldoc.DocumentInformation.Author; //Save and close the document. ldoc.Save("output.pdf"); ldoc.Close(true); 'Create new pdf document. Dim document As PdfDocument = New PdfDocument() 'Set the document author property. document.DocumentInformation.Author = "Syncfusion" 'Get the document author property value. Dim author As String = document.DocumentInformation.Author 'Save and close the document. document.Save("output.pdf") document.Close(True) 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("output.pdf") 'Get the loaded document author property value. author = ldoc.DocumentInformation.Author 'Save and close the document. ldoc.Save("output.pdf") ldoc.Close(True) Class Class Gets or sets a viewer preferences. This property is used for presenting the PDF document in a viewer. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference doc.ViewerPreferences.PageLayout = PdfPageLayout.TwoPageLeft; doc.ViewerPreferences.PageScaling = PageScalingMode.AppDefault; doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; doc.Save("ViewerPreferences.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference doc.ViewerPreferences.PageLayout = PdfPageLayout.TwoPageLeft doc.ViewerPreferences.PageScaling = PageScalingMode.AppDefault doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen doc.Save("ViewerPreferences.pdf") 'Close the document doc.Close(True) Class Class Gets or sets the PDF document compression level. By default the compression level is None To know more about refer this link . //Create a new document. PdfDocument doc = new PdfDocument(); //Set the document`s compression level. doc.Compression = PdfCompressionLevel.Best; //Creates a new page PdfPage page = doc.Pages.Add(); doc.Save("Compression.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Set the document`s compression level. doc.Compression = PdfCompressionLevel.Best 'Create a page. Dim page As PdfPage = doc.Pages.Add() doc.Save("Compression.pdf") 'Close the document. doc.Close(True) Class Class Gets or sets the internal structure of the PDF document. //Create a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); // Set the document`s cross reference Type doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream; // Set the pdf version doc.FileStructure.Version = PdfVersion.Version1_6; // Save the document doc.Save("FileStructure.pdf"); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() ' Set the document`s cross reference Type doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream ' set the pdf version doc.FileStructure.Version = PdfVersion.Version1_6 ' Save the document doc.Save("FileStructure.pdf") Class Class Gets or sets the portfolio information to the Document. To know more about refer this link . // Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Creating new portfolio document.PortfolioInformation = new PdfPortfolioInformation(); //setting the view mode of the portfolio document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Tile; //Creating the attachment PdfAttachment pdfFile = new PdfAttachment("Input.pdf"); pdfFile.FileName = "EmployeeDetails.pdf"; //Setting the startup document to view document.PortfolioInformation.StartupDocument = pdfFile; //Adding the attachment into document document.Attachments.Add(pdfFile); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Creating new portfolio document.PortfolioInformation = New PdfPortfolioInformation() 'setting the view mode of the portfolio document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Tile 'Creating the attachment Dim pdfFile As New PdfAttachment("Input.pdf") pdfFile.FileName = "EmployeeDetails.pdf" 'Setting the startup document to view document.PortfolioInformation.StartupDocument = pdfFile 'Adding the attachment into document document.Attachments.Add(pdfFile) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Gets a value indicating whether the document was encrypted. Gets a value indicating whether the document was Pdf viewer document. Gets the PDF objects collection, which stores all objects and references to it.. Gets or sets the current saving object number. Gets the cross-reference table. Gets the PDF document catalog. Gets a list of the objects that have to be disposed after document closing. Gets the number of pages. Gets or sets whether to optimize memory. Optimization will be effective only with merge, append and import functions. Only memory will be optimized, different in time occur based on the document size. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Enable memory optimization. document.EnableMemoryOptimization = true; //Merge source document PdfDocument.Merge(document, "Source.pdf"); //Save and close the pdf document. document.Save("Output.pdf"); document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Enable memory optimization. document.EnableMemoryOptimization = True 'Merge source document. PdfDocument.Merge(document, "Source.pdf") 'Save and close the document. document.Save("Output.pdf") document.Close(True) Gets the collection of PdfLayer from the PDF document Gets the Optimized dictionary collection Delegate. Is used for raising events after document saving. Delegate for the event. The sender. The arguments. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add new pages to the document. PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); document.SaveProgress += new PdfDocument.ProgressEventHandler(document_SaveProgress); //Saves the document document.Save("Document.pdf"); Close the document document.Close(true); // Handles the event void document_SaveProgress(object sender, ProgressEventArgs arguments) { MessageBox.Show(String.Format("Current: {0}, Progress: {1}, Total {2}", arguments.Current, arguments.Progress, arguments.Total)); } 'Create a new PDF document. Private document As PdfDocument = New PdfDocument() 'Add new pages to the document. Private page As PdfPage = document.Pages.Add() 'Create font and font style. Private font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) AddHandler document.SaveProgress, AddressOf document_SaveProgress 'Saves the document document.Save("Document.pdf") 'Close the document document.Close(True) ' Handles the event Private Sub document_SaveProgress(ByVal sender As Object, ByVal arguments As ProgressEventArgs) MessageBox.Show(String.Format("Current: {0}, Progress: {1}, Total {2}", arguments.Current, arguments.Progress, arguments.Total)) End Sub Holds info about current node. Internal variable to store index value. Internal variable to store Bookmark. Internal variable to store ArrayList. Initializes a new instance of the class. The bookmark base. The kids. Default margin value. Font used in complex objects to draw strings and text when it is not defined explicitly. Cache of the objects. Helps to lock s_cache to avoid race conditions. Internal variable to store template which is applied to each page of the document. Internal variable to store document's collection of attachments. Internal variable to store document's collection of pages. Internal variable to store document's collection of named destinations. Indicates whether the document was Pdf Viewer document. Internal variable to store document's collection of sections. Default page settings. Root outline. Indicates if the page labels were set. Indicates whether the document was encrypted or not. Internal variable to store additional document's actions. Defines the color space of the document Local Variable to store the Conformance Level. Indicates whether enable cache or not Indicates whether enable unique naming or not Indicates whether enable threadsafe or not. Indicates whether the object was disposed. Indicates whether the document is tagged Internal variable to store the structure tree internal variable to store image collection Internal variable to store the private font collection. internal varialbe store fonts to avoid multi threading issues Initializes a new instance of the class. To know more about refer this link . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) ; //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); //Save the document. document.Save("Document.pdf"); //Close the document. document.Close(true); ' Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = document.Pages.Add() 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) 'Save the document. document.Save("Document.pdf") 'Close the document. document.Close(True) Class Class Initializes a new instance of the class. Initializes a new instance of the class with the specified . The conformance level. Not Supported under medium trust environment. This Constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. To know more about document conformance refer this link . //Create a new PDF document. PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A1B); //Create a new page PdfPage page = document.Pages.Add(); //Create font and font style. PdfFont font = new PdfTrueTypeFont(new Font(FontFamily.GenericMonospace, 12f, FontStyle.Bold)); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); //Saves the document document.Save("Document.pdf"); Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A1B) 'Creates a new page Dim page As PdfPage = document.Pages.Add() 'Create font and font style. Dim font As PdfFont = New PdfTrueTypeFont(New Font(FontFamily.GenericMonospace, 12f, FontStyle.Bold)) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) 'Saves the document document.Save("Document.pdf") 'Close the document document.Close(True) Enumeration Saves the document to the specified output stream. The stream object where PDF document will be saved. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; // Loads an Image PdfImage pdfImg = new PdfBitmap(Image.FromFile("Logo.png")); //Draw the image g.DrawImage(pdfImg, 20, 20, 100, 200); // Save the document as a stream MemoryStream stream = new MemoryStream(); doc.Save(stream); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics ' Loads an Image Dim pdfImg As PdfImage = New PdfBitmap(Image.FromFile("Logo.png")) 'Draw the image g.DrawImage(pdfImg, 20, 20, 100, 200) ' Save the document as a stream Dim stream As MemoryStream = New MemoryStream() doc.Save(stream) 'Close the document doc.Close(True) Close the document completely. if set to true the document should be disposed completely. The document cannot be saved if Close method was invoked. To know more about refer this link . //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; //Create a solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); float fontSize = 20f; //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Draw the text g.DrawString("Hello world!", font, brush,new PointF(20,20)); doc.Save("Sample.pdf"); // Closes the document. doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics 'Create a solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) Dim fontSize As Single = 20f 'Set the font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Draw the text g.DrawString("Hello world!", font, brush,New PointF(20,20)) doc.Save("Sample.pdf") ' Closes the document. doc.Close(True) Releases all the resources used by document instances. The document cannot be saved if Dispose method was invoked. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; //Loads an Image Image img = Image.FromFile("input.png"); PdfImage pdfImg = new PdfBitmap(img); //Draw the image g.DrawImage(pdfImg,20, 20, 100,200); //Save the document. doc.Save("DisposeOnClose.pdf"); //Dispose the document doc.Dispose(); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics 'Loads an Image Dim img As Image = Image.FromFile("Logo.png") Dim pdfImg As PdfImage = New PdfBitmap(img) 'Draw the image g.DrawImage(pdfImg,20, 20, 100,200) 'Save the document. doc.Save("Dispose.pdf") 'Dispose the document doc.Dispose() Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. The resulting clone must be of the same type as or a compatible type to the original instance. A new object that is a copy of this instance. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; //Create a solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); float fontSize = 20f; //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Draw the text g.DrawString("Hello world!", font, brush,new PointF(20,20)); // Cloning the document PdfDocument cloneDoc = doc.Clone() as PdfDocument; cloneDoc.Save("Clone.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics 'Create a solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) Dim fontSize As Single = 20f 'Set the font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Draw the text g.DrawString("Hello world!", font, brush,New PointF(20,20)) ' Cloning the document Dim cloneDoc As PdfDocument = TryCast(doc.Clone(), PdfDocument) cloneDoc.Save("Clone.pdf") doc.Close(True) Releases all the font resources in multi-threading Checks whether license is valid. Informs the document that the page labels were set. Checks the pages presence. Processes the page labels. Embeds the RGB ICC ColorProfile to the document to attain PDF/A conformance. Get the hash value from the image Gets the form. The proper PdfForm instance. Adds the fields connected to the page. The loaded document. The new page. The lost of the fields. Add Acroform font resources Set to create a separate table on pagination in Tagged PDF document Get or set the ZugferdConformanceLevel It supports only in PdfConformanceLevel Pdf_A3B //Creates a new PDF document. PdfDocument doc = new PdfDocument(PdfConformanceLevel.Pdf_A3B); //Add a page. PdfPage page = doc.Pages.Add(); //Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic; //Create the PdfTrueTypeFont PdfFont font = new PdfTrueTypeFont(new Font("arial", 12f, FontStyle.Regular), true); page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty); //Creates an attachment PdfAttachment attachment = new PdfAttachment("ZUGFeRD-invoice.xml"); //Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative; attachment.ModificationDate = DateTime.Now; attachment.Description = "About Syncfusion"; attachment.MimeType = "application/xml"; //add attachment to the doucment doc.Attachments.Add(attachment); doc.Save("output.pdf"); 'Creates a new PDF document. Dim doc As New PdfDocument(PdfConformanceLevel.Pdf_A3B) 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic 'Create the PdfTrueTypeFont Dim font As PdfFont = New PdfTrueTypeFont(New Font("arial", 12F, FontStyle.Regular), True) page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty) 'Creates an attachment Dim attachment As New PdfAttachment("ZUGFeRD-invoice.xml") 'Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative attachment.ModificationDate = DateTime.Now attachment.Description = "About Syncfusion" attachment.MimeType = "application/xml" 'add attachment to the doucment doc.Attachments.Add(attachment) doc.Save("output.pdf") Get or set the ZUGFeRD version to the PDF It supports only in PdfConformanceLevel Pdf_A3B /// //Creates a new PDF document. PdfDocument doc = new PdfDocument(PdfConformanceLevel.Pdf_A3B); //Add a page. PdfPage page = doc.Pages.Add(); //Set the ZugferdProfile. doc.ZugferdVersion = ZugferdVersion.ZugferdVersion1_0; //Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic; //Create the PdfTrueTypeFont PdfFont font = new PdfTrueTypeFont(new Font("arial", 12f, FontStyle.Regular), true); page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty); //Creates an attachment PdfAttachment attachment = new PdfAttachment("ZUGFeRD-invoice.xml"); //Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative; attachment.ModificationDate = DateTime.Now; attachment.Description = "About Syncfusion"; attachment.MimeType = "application/xml"; //add attachment to the doucment doc.Attachments.Add(attachment); doc.Save("output.pdf"); 'Creates a new PDF document. Dim doc As New PdfDocument(PdfConformanceLevel.Pdf_A3B) 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Set the ZugferdProfile. doc.ZugferdVersion = ZugferdVersion.ZugferdVersion1_0 'Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic 'Create the PdfTrueTypeFont Dim font As PdfFont = New PdfTrueTypeFont(New Font("arial", 12F, FontStyle.Regular), True) page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty) 'Creates an attachment Dim attachment As New PdfAttachment("ZUGFeRD-invoice.xml") 'Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative attachment.ModificationDate = DateTime.Now attachment.Description = "About Syncfusion" attachment.MimeType = "application/xml" 'add attachment to the doucment doc.Attachments.Add(attachment) doc.Save("output.pdf") Gets or sets a template to all pages in the document. //Create a PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height); //Creates a new page. PdfPageTemplateElement footer = new PdfPageTemplateElement(rect); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); PdfSolidBrush brush = new PdfSolidBrush(Color.Gray); //Create page number field. PdfPageNumberField pageNumber = new PdfPageNumberField(font, brush); //Create page count field. PdfPageCountField count = new PdfPageCountField(font, brush); PdfCompositeField compositeField = new PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count); compositeField.Bounds = footer.Bounds; compositeField.Draw(footer.Graphics, new PointF(40, footer.Height - 50)); //Add the footer template at the bottom. doc.Template.Bottom = footer; //Save the document. doc.Save("Template.pdf"); //Close the document. doc.Close(true); 'Create a PDF document. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height) 'Create a page template. Dim footer As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Gray) 'Create page number field. Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font, brush) 'Create page count field. Dim count As PdfPageCountField = New PdfPageCountField(font, brush) Dim compositeField As PdfCompositeField = New PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count) compositeField.Bounds = footer.Bounds compositeField.Draw(footer.Graphics, New PointF(40, footer.Height - 50)) 'Add the footer template at the bottom. doc.Template.Bottom = footer doc.Save("Template.pdf") 'Close the document. doc.Close(True) The specifying the default template for the document. Class Gets a value indicating whether the document was PDF viewer document. Gets the actions to be performed when the document is opened/closed //Create a new PDF document PdfDocument document = new PdfDocument(); //Create and add new launch Action to the document PdfLaunchAction action = new PdfLaunchAction("input.txt", PdfFilePathType.Relative); document.Actions.AfterOpen = action; //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create and add new launch Action to the document. Dim action As PdfLaunchAction = New PdfLaunchAction("myAction.txt", PdfFilePathType.Relative) document.Actions.AfterOpen = action 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) The specifying the document action. Class Class Class Class Class Class Class Class Class Class Gets or sets a value indicates whether the document is auto-tagged or not. To know more about refer this link . //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element with tag type heading. PdfStructureElement header = new PdfStructureElement(PdfTagType.Heading); //Initialize new instance of structure element with tag type HeadingLevel1. PdfStructureElement header1 = new PdfStructureElement(PdfTagType.HeadingLevel1); header1.Parent = header; //Initialize new instance of structure element with tag type Paragraph. PdfStructureElement structElement = new PdfStructureElement(PdfTagType.Paragraph); structElement.Parent = header1; //Create PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element with tag type heading. Dim header As PdfStructureElement = New PdfStructureElement(PdfTagType.Heading) 'Initialize new instance of structure element with tag type HeadingLevel1. Dim header1 As PdfStructureElement = New PdfStructureElement(PdfTagType.HeadingLevel1) header1.Parent = header 'Initialize new instance of structure element with tag type Paragraph. Dim structElement As PdfStructureElement = New PdfStructureElement(PdfTagType.Paragraph) structElement.Parent = header1 'Create PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Gets the collection of pages in the document. A object containing the list of document's pages. //Creates a new document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Page collection. PdfDocumentPageCollection pageCollection = doc.Pages; PdfFont standardFont = new PdfStandardFont(PdfFontFamily.TimesRoman,10); //Drawing string on first page. pageCollection[0].Graphics.DrawString("FirstPage", standardFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Creates a new document. Dim doc As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = doc.Pages.Add() 'Page collection. Dim pageCollection As PdfDocumentPageCollection = doc.Pages Dim standardFont As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman,10) 'Drawing string on the page. pageCollection(0).Graphics.DrawString("FirstPage", standardFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Class Class Class Gets the named destination collection of the document. A specifies the document's named destinations. To know more about refer this link . //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page PdfPage page = doc.Pages.Add(); //Create named destination PdfNamedDestination namedDestination = new PdfNamedDestination("Interactive Feature"); namedDestination.Title = "Interactive Feature"; namedDestination.Destination = new PdfDestination(page); doc.NamedDestinationCollection.Add(namedDestination); //Save the document doc.Save("NamedDestination.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page Dim page As PdfPage = doc.Pages.Add() 'Create named destination Dim namedDestination As PdfNamedDestination = New PdfNamedDestination("Interactive Feature") namedDestination.Title = "Interactive Feature" namedDestination.Destination = New PdfDestination(page) doc.NamedDestinationCollection.Add(namedDestination) doc.Save("NamedDestination.pdf") //Close the document doc.Close(True) Class Gets the collection of the sections in the document. A object containing the list of document's sections. To know more about refer this link . //Create a PDF document PdfDocument doc = new PdfDocument(); // Create a new section PdfSection mySection = doc.Sections.Add(); //Creates a new page mySection.Pages.Add(); // Gets the section collection PdfSectionCollection sectionCollection = doc.Sections; // Gets the first page from first section PdfPage page = sectionCollection[0].Pages[0]; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); // Draw the string in first page of the section page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, new Point(100, 100)); doc.Save("Sections.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As PdfDocument = New PdfDocument() ' Create a new section Dim mySection As PdfSection = doc.Sections.Add() 'Creates a new page mySection.Pages.Add() ' Gets the section collection Dim sectionCollection As PdfSectionCollection = doc.Sections ' Gets the first page from first section Dim page As PdfPage = sectionCollection(0).Pages(0) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) ' Draw the string in first page of the section page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, New Point(100, 100)) doc.Save("Sections.pdf") 'Close the document doc.Close(True) Gets or sets the document's page setting. A object containing the setting for a document`s pages. //Create a new document class object. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Set page size. doc.PageSettings.Size = PdfPageSize.A6; //Set page orientation. doc.PageSettings.Orientation = PdfPageOrientation.Landscape; doc.Save("PageSettings.pdf"); //Close the document. doc.Close(true); 'Create a new document class object. Dim doc As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = doc.Pages.Add() 'Set page size. doc.PageSettings.Size = PdfPageSize.A6 'Set page orientation. doc.PageSettings.Orientation = PdfPageOrientation.Landscape doc.Save("PageSettings.pdf") 'Close the document. doc.Close(True) The changing of the settings doesn't take any effect on the already existing pages. To know more about refer this link . Gets the bookmark collection of the document. A specifies the document's bookmark. To know more about refer this link . //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page PdfPage page = doc.Pages.Add(); //Create outline PdfBookmark bookMark = doc.Bookmarks.Add("InteractiveFeature"); bookMark.Color = Color.DarkBlue; bookMark.TextStyle = PdfTextStyle.Bold; bookMark.Title = "Interactive Feature"; bookMark.Destination = new PdfDestination(page); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page Dim page As PdfPage = doc.Pages.Add() 'Create outline Dim bookMark As PdfBookmark = document.Bookmarks.Add("InteractiveFeature") bookMark.Color = Color.DarkBlue bookMark.TextStyle = PdfTextStyle.Bold bookMark.Title = "Interactive Feature" bookMark.Destination = New PdfDestination(page) doc.Save("Bookmarks.pdf") //Close the document doc.Close(True) Class Gets the attachment collection of the document. To know more about refer this link . //Create a new document. PdfDocument doc = new PdfDocument(); // Creates a new page in document PdfPage page = doc.Pages.Add(); // Adding an image as attachment PdfAttachment attachment = new PdfAttachment("Logo.jpg"); attachment.Description = "Syncfusion Logo"; attachment.MimeType = "application/jpeg"; // Add the attachment in document doc.Attachments.Add(attachment); //Save the document doc.Save("Attachment.pdf"); //Close the document doc.Close(true); ' Create a new document. Dim doc As PdfDocument = New PdfDocument() ' Creates a new page in document Dim page As PdfPage = doc.Pages.Add() ' Adding an image as attachment Dim attachment As PdfAttachment = New PdfAttachment("Logo.jpg") attachment.Description = "Syncfusion Logo" attachment.MimeType = "application/jpeg" ' Add the attachment in document doc.Attachments.Add(attachment) 'Save the document doc.Save("Attachment.pdf") 'Close the document doc.Close(True) The object contains list of files which are attached in the PDF document. Class. Gets the interactive form of the document. To know more about refer this link . //Create a document. PdfDocument document = new PdfDocument(); //Creates a new page. PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 14); //Create a text box. PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; //Add the textbox in form. document.Form.Fields.Add(firstNameTextBox); //Save the document. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a document. Dim document As PdfDocument = New PdfDocument() 'Create a page. Dim page As PdfPage = document.Pages.Add() 'Create a text box. Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font 'Add the textbox in form. document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") 'Close the document. document.Close(True) The object contains the list of form elements of the document. Class Class Gets or sets the color space of the document. This property can be used to create PDF document in RGB, Grayscale or CMYK color spaces. By default the document uses RGB color space. This property has impact on the new created pages only. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page PdfPage page = doc.Pages.Add(); // Set the document`s color spaces as GrayScale doc.ColorSpace = PdfColorSpace.GrayScale; doc.Save("ColorSpace.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() ' Set the document`s color spaces as GrayScale doc.ColorSpace = PdfColorSpace.GrayScale doc.Save("ColorSpace.pdf") 'Close the document doc.Close(True) The of the document. Class Gets collection of the cached objects. Gets the Private Font Collection Gets the default font. It is used for complex objects when font is not explicitly defined. The default font. Gets a value indicating whether the document was encrypted. true if the document was encrypted; otherwise, false. get the image collection Gets the number of pages. Gets or sets the PDF conformance level. This property can be used to create PDF/A-1b or Pdf_X1A2001 compliant documents. By default is None. The ENUM. Not Supported under Medium Trust environment. To know more about refer this link . //Create a new PDF document. PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A1B); //Creates a new page and adds it as the last page of the document to the document. PdfPage page = document.Pages.Add(); // Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); // Create font with bold font style. PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save document to disk. document.Save("ConformanceLevel.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A1B) ' Create a page to the document. Dim page As PdfPage = document.Pages.Add() ' Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) ' Create font with bold font style. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save document to disk. document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) Class Gets or sets the enable cache. This property is used to cache the fonts. Default value is True. //Create a new document. PdfDocument doc = new PdfDocument(); //Diable the font cache PdfDocument.EnableCache = false; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; //Create a solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); float fontSize = 20f; //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, fontSize); //Draw the text g.DrawString("Hello world!", font, brush, new PointF(20, 20)); doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Diable the font cache PdfDocument.EnableCache = False 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics 'Create a solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) Dim fontSize As Single = 20.0F 'Set the font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, fontSize) 'Draw the text g.DrawString("Hello world!", font, brush, New PointF(20, 20)) doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets boolean value which enables or disables unique resource naming, Default value is true. By default this value will be true, if the uniform resource naming is needed then this value can be set false. //Disables unique resource naming. PdfDocument.EnableUniqueResourceNaming = false; //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the colorspace for the document. graphics.ColorSpace = PdfColorSpace.CMYK; //Set the transparency of this graphics. graphics.SetTransparency(0.5f); //Create new instance for PDF font. PdfFont font1 = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font1, PdfBrushes.Blue, new PointF(50, 50)); //Create new instance for PDF font. PdfFont font2 = new PdfTrueTypeFont(new Font("Arial", 20), true); //Draw the text. graphics.DrawString("Hello World!!!", font2, PdfBrushes.Blue, new PointF(50, 100)); //Create new instance for PDF font. PdfFont font3 = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20); //Draw the text. graphics.DrawString("こんにちは世界", font3, PdfBrushes.Blue, new PointF(50, 150)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Disables unique resource naming. PdfDocument.EnableUniqueResourceNaming = False 'Create a new PDF document. Dim doc As PdfDocument = New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the colorspace for the document. graphics.ColorSpace = PdfColorSpace.CMYK 'Set the transparency of this graphics graphics.SetTransparency(0.5F) 'Create new instance for PDF font. Dim font1 As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font1, PdfBrushes.Blue, New PointF(50, 50)) 'Create new instance for PDF font. Dim font2 As PdfFont = New PdfTrueTypeFont(New Font("Arial", 20), True) 'Draw the text. graphics.DrawString("Hello World!!!", font2, PdfBrushes.Blue, New PointF(50, 100)) 'Create new instance for PDF font. Dim font3 As PdfFont = New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20) 'Draw the text. graphics.DrawString("こんにちは世界", font3, PdfBrushes.Blue, New PointF(50, 150)) 'Save and close the document. doc.Save("Output.pdf") doc.Close(True) Shows the saving progress of the PDF document. The Total The Current object. Initializes a new instance of the class. The current index. The total number. Initializes a new instance of the class. The current index. The total number. The total number of pages progressed. Initializes a new instance of the class. The current index. The total number. The total number of pages progressed. The number of changed pages. Initializes a new instance of the class. Gets the total number of the elements (pages) that need to be saved. Gets the current element (page) index that just was saved. The index value increases constantly from 0 to Total. Gets the progress. Progress constantly increases from 0.0 to 1.0. 1.0 value means that entire document has been saved. Arguments for event raised after document saving. Document's destination stream. Initializes a new instance of the class. The writer. Gets document's destination stream. Represents to customize the support of merging PDF documents. // Destination PDF document PdfDocument destDoc = new PdfDocument(); // Source PDF documents string[] source = { "Src1.pdf", "Src2.pdf" }; PdfMergeOptions option = new PdfMergeOptions(); option.OptimizeResources = true; //Merge the source pdf document. PdfDocumentBase.Merge(destDoc, option, source); destDoc.Save("Merge.pdf"); ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() ' Source PDF documents Dim source() As String = { "Src1.pdf", "Src2.pdf" } 'Merge the source pdf document. Dim [option] As PdfMergeOptions = New PdfMergeOptions() [option].OptimizeResources = True PdfDocumentBase.Merge(destDoc, [option], source) destDoc.Save("Merge.pdf") Class Class The variable to indicates whether resource optimization needed. The variable to indicates whether final PDF externs margin. Gets or sets to optimize resources while merging PDF documents. /// // Destination PDF document PdfDocument destDoc = new PdfDocument(); // Source PDF documents string[] source = { "Src1.pdf", "Src2.pdf" }; PdfMergeOptions option = new PdfMergeOptions(); option.OptimizeResources = true; //Merge the source pdf document. PdfDocumentBase.Merge(destDoc, option, source); destDoc.Save("Merge.pdf"); ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() ' Source PDF documents Dim source() As String = { "Src1.pdf", "Src2.pdf" } 'Merge the source pdf document. Dim [option] As PdfMergeOptions = New PdfMergeOptions() [option].OptimizeResources = True PdfDocumentBase.Merge(destDoc, [option], source) destDoc.Save("Merge.pdf") When ExtendMargin is set to true, then specified margin is considered while importing the pages from the existing document. // Destination PDF document PdfDocument destDoc = new PdfDocument(); PdfMargins margin = new PdfMargins(); //Set left margin. margin.Left = 20; //Set right margin. margin.Right = 40; //Set top margin. margin.Top = 100; //Set bottom margin. margin.Bottom = 100; //Set margin. destDoc.PageSettings.Margins = margin; // Source PDF documents string[] source = { "Src1.pdf", "Src2.pdf" }; PdfMergeOptions option = new PdfMergeOptions(); option.ExtendMargin = true; //Merge the source pdf document. PdfDocumentBase.Merge(destDoc, option, source); destDoc.Save("Merge.pdf"); ' Destination PDF document Dim destDoc As PdfDocument = New PdfDocument() Dim margin As New PdfMargins() 'Set left margin. margin.Left = 20 'Set right margin. margin.Right = 40 'Set top margin. margin.Top = 100 'Set bottom margin. margin.Bottom = 100 'Set margin. destDoc.PageSettings.Margins = margin ' Source PDF documents Dim source() As String = { "Src1.pdf", "Src2.pdf" } 'Merge the source pdf document. Dim [option] As PdfMergeOptions = New PdfMergeOptions() [option].ExtendMargin = True PdfDocumentBase.Merge(destDoc, [option], source) destDoc.Save("Merge.pdf") A class containing the information about the document. To know more about refer this link . //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Interface Class Class Xmp metadata of the document. Parent catalog class. Author of the document. Title of the document. The subject of the document. Keywords associated with the document. If the document was converted to PDF from another format, the name of the application that created the original document from which it was converted. If the document was converted to PDF from another format, the name of the application that converted it to PDF. The date and time the document was created. The date and time the document was modified. Internal variable to store dictionary. Internal variable to store dictionary. To store custom keyvalue m_customValue To store Array of string customValue m_arrayString Internal class to add customMetaData. Indicates the language of the document Creates a new object. Initializes a new instance of the class. The dictionary. The catalog. Update Custom metadata to PdfDocumentInfo Dictionary Applies to attributes to attain PDF/X1a:2001 conformance. Remove the modification date from existing document. Gets or sets the creation date of the PDF document The . //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets or sets the modification date. The . //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets or sets the title. The title. //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets or sets the author. The author of the document. //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets or sets the subject. The subject. //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets or sets the keywords. The keywords. //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets or sets the creator. The creator. //Create a new document PdfDocument pdfDoc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = pdfDoc.Pages.Add(); //Set the document`s information pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; // Sets the documents creator information pdfDoc.DocumentInformation.Creator = "Essential PDF"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument = New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'Set the document`s information. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" ' Sets the documents creator information pdfDoc.DocumentInformation.Creator = "Essential PDF" pdfDoc.DocumentInformation.CreationDate = DateTime.Now pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class If the document was converted to PDF from another format, the name of the application (for example, Acrobat Distiller) that converted it to PDF. The producer of the document. //Create a new document PdfDocument pdfDoc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = pdfDoc.Pages.Add(); //Set the document`s information pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; // Sets the documents creator information pdfDoc.DocumentInformation.Creator = "Essential PDF"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument = New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'Set the document`s information. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" ' Sets the documents creator information pdfDoc.DocumentInformation.Creator = "Essential PDF" pdfDoc.DocumentInformation.CreationDate = DateTime.Now pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets Xmp metadata of the document. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight Represents the document information in Xmp format. PdfDocument pdfDoc = new PdfDocument(); PdfPage page = pdfDoc.Pages.Add(); // Get xmp object. XmpMetadata xmp = pdfDoc.DocumentInformation.XmpMetadata; // XMP Basic Schema. BasicSchema basic = xmp.BasicSchema; basic.Advisory.Add("advisory"); basic.BaseURL = new Uri("http://google.com"); basic.CreateDate = DateTime.Now; basic.CreatorTool = "creator tool"; basic.Identifier.Add("identifier"); basic.Label = "label"; basic.MetadataDate = DateTime.Now; basic.ModifyDate = DateTime.Now; basic.Nickname = "nickname"; basic.Rating.Add(-25); pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); Dim pdfDoc As PdfDocument = New PdfDocument() Dim page As PdfPage = pdfDoc.Pages.Add() ' Get xmp object. Dim xmp As XmpMetadata = pdfDoc.DocumentInformation.XmpMetadata ' XMP Basic Schema. Dim basic As BasicSchema = xmp.BasicSchema basic.Advisory.Add("advisory") basic.BaseURL = New Uri("http://google.com") basic.CreateDate = DateTime.Now basic.CreatorTool = "creator tool" basic.Identifier.Add("identifier") basic.Label = "label" basic.MetadataDate = DateTime.Now basic.ModifyDate = DateTime.Now basic.Nickname = "nickname" basic.Rating.Add(-25) pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class CusotmMetadata used for add CustomMetadata to PDFDictionry Remove CustomMetadata values Modify CustomMetadata values Add CustomMetadata values Gets the dictionary. The dictionary. get or set the ZugFerdConformanceLevel Gets or sets the Language. The Language. //Create a new document. PdfDocument pdfDoc= new PdfDocument(); //Creates a new page PdfPage page = pdfDoc.Pages.Add(); //Set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information"; pdfDoc.DocumentInformation.Language = "En-Us"; pdfDoc.DocumentInformation.Author = "Syncfusion"; pdfDoc.DocumentInformation.Keywords = "PDF"; pdfDoc.DocumentInformation.Subject = "PDF demo"; pdfDoc.DocumentInformation.Producer = "Syncfusion Software"; pdfDoc.DocumentInformation.CreationDate = DateTime.Now; //Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now; //Save the document pdfDoc.Save("DocumentInformation.pdf"); pdfDoc.Close(true); 'Create a new document. Dim pdfDoc As PdfDocument= New PdfDocument() 'Create a new page Dim page As PdfPage = pdfDoc.Pages.Add() 'set the Document`s properties. pdfDoc.DocumentInformation.Title = "Document Properties Information" pdfDoc.DocumentInformation.Language = "En-Us" pdfDoc.DocumentInformation.Author = "Syncfusion" pdfDoc.DocumentInformation.Keywords = "PDF" pdfDoc.DocumentInformation.Subject = "PDF demo" pdfDoc.DocumentInformation.Producer = "Syncfusion Software" pdfDoc.DocumentInformation.CreationDate = DateTime.Now 'Sets the modification date pdfDoc.DocumentInformation.ModificationDate = DateTime.Now 'Save the document pdfDoc.Save("DocumentInformation.pdf") pdfDoc.Close(True) Class Class Gets the element. CusotmMetadata used for add CustomMetadata to PDFDictionary Remove the custom field from CustomMetadataDictionary,Dictionary,CustomSchema Gets the the key value at present or not Add the CustomMetadataDictionary Get Enumerator of the CustomMetadataDictionary Add Cusotm MetaData to CustomMetadataDictionary Gets the current count CustomMetadataDictionary Gets the dictionary. The dictionary. This class represents a set of the properties that define the internal structure of PDF file. //Create a new document PdfDocument doc = new PdfDocument(); //Create a new page PdfPage page = doc.Pages.Add(); //Create new instance for PDF file structure. PdfFileStructure structure = new PdfFileStructure(); //Set the file structure cross reference type. structure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream; //Set the document`s file structure. doc.FileStructure = structure; // Save the document doc.Save("FileStructure.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Create a new page Dim page As PdfPage = doc.Pages.Add() 'Create new instance for PDF file structure. Dim pdfstructure As PdfFileStructure = New PdfFileStructure() 'Set the file structure cross reference type pdfstructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream 'Set the document`s file structure doc.FileStructure = pdfstructure 'Save the document doc.Save("FileStructure.pdf") doc.Close(True) Class Class the version of the file. The type of the cross-reference. Indicates the file format. Incremental operator bool value Tagged bool value Indicates whether enable FileID or not Initializes a new instance of the class. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); PdfFileStructure structure = new PdfFileStructure(); //Set the document`s cross reference type structure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream; //Set the PDF version. doc.FileStructure = structure; //Draw the text. page.Graphics.DrawString("File structure", new PdfStandardFont(PdfFontFamily.Courier, 12), PdfBrushes.Green, new PointF(10, 10)); //Save and close the document. doc.Save("FileStructure.pdf"); doc.Close(true); 'Create new document. Dim doc As PdfDocument = New PdfDocument() 'Add new page. Dim page As PdfPage = doc.Pages.Add() 'Create new instance for PDF file structure. Dim pdfstructure As PdfFileStructure = New PdfFileStructure() 'Set the document`s cross reference type pdfstructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream 'Set the PDF version. doc.FileStructure = pdfstructure 'Draw the text. page.Graphics.DrawString("File structure", New PdfStandardFont(PdfFontFamily.Courier, 12), PdfBrushes.Green, New PointF(10, 10)) 'Save and close the document. doc.Save("FileStructure.pdf") doc.Close(True) Class Class enum. Create the OnPropertyChanged method to raise the event Notifies if TaggedPDF property is changed. Gets or sets the version of the PDF document. The document version. //Create a new document PdfDocument doc = new PdfDocument(); //Create a new page PdfPage page = doc.Pages.Add(); // Set the document`s cross reference type doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream; // Set the PDF version doc.FileStructure.Version = PdfVersion.Version1_6; // Save the document doc.Save("FileStructure.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Create a new page Dim page As PdfPage = doc.Pages.Add() ' Set the document`s cross reference type doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream ' Set the PDF version doc.FileStructure.Version = PdfVersion.Version1_6 ' Save the document doc.Save("FileStructure.pdf") doc.Close(True) Gets or sets a value indicating whether [incremental update]. true if [incremental update]; otherwise, false. // Load an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("SourceDoc.pdf"); // Sets the incremental update as True lDoc.FileStructure.IncrementalUpdate = true; //Create a new page lDoc.Pages.Add(); // Saves the document lDoc.Save("FileStructure.pdf"); lDoc.Close(true); ' Load an existing document Dim lDoc As New PdfLoadedDocument("SourceDoc.pdf") ' Sets the incremental update as True lDoc.FileStructure.IncrementalUpdate = True 'Create a new page lDoc.Pages.Add() ' Saves the document lDoc.Save("FileStructure.pdf") lDoc.Close(True) Gets or sets a value indicating whether the trailer Id is added or not to the PDF document. If true trailer Id is added to the PDF document, otherwise false. Default value is false Gets or sets the type of PDF cross-reference. Please see the description of for more details. //Create a new document PdfDocument doc = new PdfDocument(); //Create a new page PdfPage page = doc.Pages.Add(); // Set the document`s cross reference type doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream; // Set the PDF version doc.FileStructure.Version = PdfVersion.Version1_6; // Save the document doc.Save("FileStructure.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Create a new page Dim page As PdfPage = doc.Pages.Add() ' Set the document`s cross reference type doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream ' Set the PDF version doc.FileStructure.Version = PdfVersion.Version1_6 ' Save the document doc.Save("FileStructure.pdf") doc.Close(True) Gets or sets the value indicating the format of the file. Gets the value indicating whether the PDF document is tagged one or not. If true PDF document is tagged, otherwise false. //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element with tag type heading. PdfStructureElement header = new PdfStructureElement(PdfTagType.Heading); //Initialize new instance of structure element with tag type HeadingLevel1. PdfStructureElement header1 = new PdfStructureElement(PdfTagType.HeadingLevel1); header1.Parent = header; //Initialize new instance of structure element with tag type Paragraph. PdfStructureElement structElement = new PdfStructureElement(PdfTagType.Paragraph); structElement.Parent = header1; //Create PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); bool tagged = document.FileStructure.TaggedPdf; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element with tag type heading. Dim header As PdfStructureElement = New PdfStructureElement(PdfTagType.Heading) 'Initialize new instance of structure element with tag type HeadingLevel1. Dim header1 As PdfStructureElement = New PdfStructureElement(PdfTagType.HeadingLevel1) header1.Parent = header 'Initialize new instance of structure element with tag type Paragraph. Dim structElement As PdfStructureElement = New PdfStructureElement(PdfTagType.Paragraph) structElement.Parent = header1 'Create PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) Dim tagged As Boolean = document.FileStructure.TaggedPdf 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class The class represents the creation of PDF portfolio //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Create new portfolio. document.PortfolioInformation = new PdfPortfolioInformation(); //Set the view mode of the portfolio. document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Details; //Create portfolio schema. PdfPortfolioSchema schema = new PdfPortfolioSchema(); //Create portfolio schema field. PdfPortfolioSchemaField fromField = new PdfPortfolioSchemaField(); fromField.Name = "From"; fromField.Type = PdfPortfolioSchemaFieldType.String; fromField.Order = 1; fromField.Visible = true; fromField.Editable = false; schema.AddSchemaField(fromField); PdfPortfolioSchemaField toField = new PdfPortfolioSchemaField(); toField.Name = "To"; toField.Type = PdfPortfolioSchemaFieldType.String; toField.Order = 2; toField.Visible = true; toField.Editable = false; schema.AddSchemaField(toField); //Add schema to the portfolio. document.PortfolioInformation.Schema = schema; //Create attachment. PdfAttachment pdfFile = new PdfAttachment("CorporateBrochure.pdf"); pdfFile.FileName = "CorporateBrochure.pdf"; //Set schema field attributed. pdfFile.PortfolioAttributes = new PdfPortfolioAttributes(); pdfFile.PortfolioAttributes.AddAttributes("From", "Steven"); pdfFile.PortfolioAttributes.AddAttributes("To", "John"); //Add attachment to document. document.Attachments.Add(pdfFile); //Add new page to document. document.Pages.Add(); //Save and close the document. document.Save("Sample.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Create new portfolio. document.PortfolioInformation = New PdfPortfolioInformation() 'Set the view mode of the portfolio. document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Details 'Create portfolio schema. Dim schema As New PdfPortfolioSchema() 'Create portfolio schema field. Dim fromField As New PdfPortfolioSchemaField() fromField.Name = "From" fromField.Type = PdfPortfolioSchemaFieldType.[String] fromField.Order = 1 fromField.Visible = True fromField.Editable = False schema.AddSchemaField(fromField) Dim toField As New PdfPortfolioSchemaField() toField.Name = "To" toField.Type = PdfPortfolioSchemaFieldType.[String] toField.Order = 2 toField.Visible = True toField.Editable = False schema.AddSchemaField(toField) 'Add schema to the portfolio. document.PortfolioInformation.Schema = schema 'Create attachment. Dim pdfFile As New PdfAttachment("CorporateBrochure.pdf") pdfFile.FileName = "CorporateBrochure.pdf" 'Set schema field attributed. pdfFile.PortfolioAttributes = New PdfPortfolioAttributes() pdfFile.PortfolioAttributes.AddAttributes("From", "Steven") pdfFile.PortfolioAttributes.AddAttributes("To", "John") 'Add attachment to document. document.Attachments.Add(pdfFile) 'Add new page to document. document.Pages.Add() 'Save and close the document. document.Save("Sample.pdf") document.Close(True) Internal variable to store value specifying document's catalog. Internal variable to store dictionary; internal variable to store schema of portfolio internal variable to store view mode internal varible to store startup attachment document Initializes new instance of class Initialize the new instance portfolio dictionary Initializes instance. Gets or sets the collection of portfolio schema field the Gets and sets the view mode of the portfolio The represents visual mode of the files in portfolio Get and set the startup document of portfolio The , represents the attached documents Gets the element. The class represents attributes of attached files in the portfolio such as Title,Name,Author..etc Internal variable to store dictionary; Internal variable to store attribute keys Internal variable to store attributes Internal variable to store attributes Initialize the instance of the class Initialize the instance of the class Initializes instance. Add the attributes into portfolio The attribute key such as name,date,author..etc The attribute value Remove the attributes from the portfolio The attribute key Remove the attributes from the portfolio The attribute key Gets attribute keys The array of attribute keys Gets the element. The class represents the collection of schema attributes. The class represents the collections of schema field Internal variable to store dictionary; Variable to store Schema field internal variable to store field keys Internal variable to store field collections Initialize the instance of the class Initialize the instance of the class used to add the schema field into schema dictionary The ,contains custom fields of the attached file used to remove the schema field from schema dictionary The field key used to retrieve the schema fields from schema dictionary The ,contains custom fields of the attached file Initializes instance. Get the field keys from schema field The array of field keys Gets the element. The class represents the creation of schema filed //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Create new portfolio. document.PortfolioInformation = new PdfPortfolioInformation(); //Set the view mode of the portfolio. document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Details; //Create portfolio schema. PdfPortfolioSchema schema = new PdfPortfolioSchema(); //Create portfolio schema field. PdfPortfolioSchemaField fromField = new PdfPortfolioSchemaField(); fromField.Name = "From"; fromField.Type = PdfPortfolioSchemaFieldType.String; fromField.Order = 1; fromField.Visible = true; fromField.Editable = false; schema.AddSchemaField(fromField); PdfPortfolioSchemaField toField = new PdfPortfolioSchemaField(); toField.Name = "To"; toField.Type = PdfPortfolioSchemaFieldType.String; toField.Order = 2; toField.Visible = true; toField.Editable = false; schema.AddSchemaField(toField); //Add schema to the portfolio. document.PortfolioInformation.Schema = schema; //Create attachment. PdfAttachment pdfFile = new PdfAttachment("CorporateBrochure.pdf"); pdfFile.FileName = "CorporateBrochure.pdf"; //Set schema field attributed. pdfFile.PortfolioAttributes = new PdfPortfolioAttributes(); pdfFile.PortfolioAttributes.AddAttributes("From", "Steven"); pdfFile.PortfolioAttributes.AddAttributes("To", "John"); //Add attachment to document. document.Attachments.Add(pdfFile); //Add new page to document. document.Pages.Add(); //Save and close the document. document.Save("Sample.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Create new portfolio. document.PortfolioInformation = New PdfPortfolioInformation() 'Set the view mode of the portfolio. document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Details 'Create portfolio schema. Dim schema As New PdfPortfolioSchema() 'Create portfolio schema field. Dim fromField As New PdfPortfolioSchemaField() fromField.Name = "From" fromField.Type = PdfPortfolioSchemaFieldType.[String] fromField.Order = 1 fromField.Visible = True fromField.Editable = False schema.AddSchemaField(fromField) Dim toField As New PdfPortfolioSchemaField() toField.Name = "To" toField.Type = PdfPortfolioSchemaFieldType.[String] toField.Order = 2 toField.Visible = True toField.Editable = False schema.AddSchemaField(toField) 'Add schema to the portfolio. document.PortfolioInformation.Schema = schema 'Create attachment. Dim pdfFile As New PdfAttachment("CorporateBrochure.pdf") pdfFile.FileName = "CorporateBrochure.pdf" 'Set schema field attributed. pdfFile.PortfolioAttributes = New PdfPortfolioAttributes() pdfFile.PortfolioAttributes.AddAttributes("From", "Steven") pdfFile.PortfolioAttributes.AddAttributes("To", "John") 'Add attachment to document. document.Attachments.Add(pdfFile) 'Add new page to document. document.Pages.Add() 'Save and close the document. document.Save("Sample.pdf") document.Close(True) variable to store editable value Variable to store name of the schema field variable to store the order of the schema field variable to store visibility of schema field Internal variable to store dictionary; initialize the instance of the class initialize the instance of the class schema field dictionary Initializes instance. Gets or Sets the whether the value of the schema field is editable if true editable,else can't editable Gets or Sets the name of the schema field The name of the schema field Gets or sets the order of the Schema field. the numeric value show the order of the field Gets or Sets the schema field Type The provides the data type of the field Gets or Sets the visibility of the Schema field if true the filed is visible,otherwise field is not visible Gets the element. Defines the way the document is to be presented on the screen or in print. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.PageMode = PdfPageMode.UseAttachments; doc.ViewerPreferences.PageScaling = PageScalingMode.None; doc.ViewerPreferences.FitWindow = true; doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference doc.ViewerPreferences.PageMode = PdfPageMode.UseAttachments doc.ViewerPreferences.PageScaling = PageScalingMode.None doc.ViewerPreferences.FitWindow = True doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) Class Class Internal variable to store value whether to center document's window. Internal variable to store value whether to display window�s title bar. Internal variable to store value whether to resize the document�s window to fit the size of the first displayed page. Internal variable to store value whether to hide the viewer application�s menu bar when the document is active. Internal variable to store value whether to hide the viewer application�s tool bars when the document is active. Internal vaiable to store value whether to hide user interface elements in the document�s window. Internal variable to store value how the document should be displayed when opened Internal variable to store value specifying the page layout to be used when the document is opened. Internal variable to store value specifying document's catalog. Internal variable to store dictionary; Internal variable to store value specifying the page scaling mode used while printing. Gets or sets print duplex mode handling option to use when printing the file from the print dialog. Initializes a new instance of the class. Initializes new instance. Catalog of the document. A flag specifying whether to position the document�s window in the center of the screen. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.CenterWindow = true; doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.CenterWindow = True doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) Class Class A flag specifying whether the window�s title bar should display the document title taken from the Title entry of the document information dictionary. If false, the title bar should instead display the name of the PDF file containing the document. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.CenterWindow = true; doc.ViewerPreferences.DisplayTitle = true; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.CenterWindow = True doc.ViewerPreferences.DisplayTitle = True 'Save and close the document doc.Save("ViewerPreferences.pdf") doc.Close(True) Class Class A flag specifying whether to resize the document�s window to fit the size of the first displayed page. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.FitWindow = true; doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true); 'Create a new document. Dim doc As New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.FitWindow = True doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) Class Class A flag specifying whether to hide the viewer application�s menu bar when the document is active. //Create a new document. PdfDocument doc = new PdfDocument(); //Create a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.HideMenubar = true; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true) 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.HideMenubar = True 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) Class Class A flag specifying whether to hide the viewer application�s tool bars when the document is active. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.HideToolbar = true; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true) 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.HideToolbar = True 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) A flag specifying whether to hide user interface elements in the document�s window (such as scroll bars and navigation controls), leaving only the document�s contents displayed. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.HideWindowUI = true; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true) 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.HideWindowUI = True 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) A name object specifying how the document should be displayed when opened. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.PageMode = PdfPageMode.UseAttachments; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true) 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference doc.ViewerPreferences.PageMode = PdfPageMode.UseAttachments 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) A name object specifying the page layout to be used when the document is opened. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(True) 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.PageLayout = PdfPageLayout.SinglePage 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) Gets or sets print duplex mode handling option to use when printing the file from the print dialog. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.Duplex = DuplexMode.DuplexFlipShortEdge; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(True) 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.Duplex = DuplexMode.DuplexFlipShortEdge 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) Gets or Set the page scaling option to be selected when a print dialog is displayed for this document. //Create a new document. PdfDocument doc = new PdfDocument(); //Creates a new page. PdfPage page = doc.Pages.Add(); //Set the document`s viewer preference. doc.ViewerPreferences.PageScaling = PageScalingMode.None; //Save and close the document. doc.Save("ViewerPreferences.pdf"); doc.Close(true) 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Set the document`s viewer preference. doc.ViewerPreferences.PageScaling = PageScalingMode.None 'Save and close the document. doc.Save("ViewerPreferences.pdf") doc.Close(True) Gets the element. Specifies the type of PDF file format. Specifies plain PDF file format. Specifies Linearized PDF file format. Specifies the different way of presenting the document at the client browser. To know more about using HttpReadType refer this link. //Create a new document. PdfDocument doc = new PdfDocument(); //Add a page in the PDF document. PdfPage page = doc.Pages.Add(); //Load an existing image. PdfBitmap bmp = new PdfBitmap("Logo.png"); //Draw the image in PDF page. page.Graphics.DrawImage(bmp, 20, 20, 100, 200); //Open the document in browser after saving it. doc.Save("Sample.pdf", Response, HttpReadType.Open); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Add a page in the PDF document. Dim page As PdfPage = doc.Pages.Add() 'Load an existing image. Dim bmp As PdfBitmap = New PdfBitmap("Logo.png") 'Draw the image in PDF page. page.Graphics.DrawImage(bmp, 20, 20, 100, 200) 'Open the document in browser after saving it. doc.Save("Sample.pdf", Response, HttpReadType.Open) Class Class Send the generated document to the client browser and will open document inside browser or using application associated with .pdf extension externally. Send the generated document to the client browser and presents an option to save the document to disk or open inside the browser. Specifies the available PDF versions to save the PDF document. Default Value is Version1_5 //Create a new document. PdfDocument doc = new PdfDocument(); //Add a page in the PDF document. PdfPage page = doc.Pages.Add(); //Set the pdf version as Version1_7. doc.FileStructure.Version = PdfVersion.Version1_7; //Save the PDF document to disk. doc.Save("FileStructure.pdf"); //Close the document. doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Add a page in the PDF document. Dim page As PdfPage = doc.Pages.Add() 'Set the pdf version as Version1_7. doc.FileStructure.Version = PdfVersion.Version1_7 'Save the PDF document to disk. doc.Save("FileStructure.pdf") 'Close the document. doc.Close(True) Class Class Class PDF version 1.0. PDF version 1.1. PDF version 1.2. PDF version 1.3. Adobe Acrobat 4. PDF version 1.4. Adobe Acrobat 5. PDF version 1.5. Adobe Acrobat 6. PDF version 1.6. Adobe Acrobat 7. PDF version 1.7. Adobe Acrobat 8. PDF version 2.0. Specifies the type of the PDF cross-reference. Default value is CrossReferenceStream //Create a new document. PdfDocument doc = new PdfDocument(); //Add a page in the PDF document. PdfPage page = doc.Pages.Add(); //Set the CrossReferenceType as CrossReferenceStream. doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream; //Save the PDF document to disk. doc.Save("FileStructure.pdf"); //Close the document. doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Add a page in the PDF document. Dim page As PdfPage = doc.Pages.Add() 'Set the CrossReferenceType as CrossReferenceStream. doc.FileStructure.CrossReferenceType = PdfCrossReferenceType.CrossReferenceStream 'Save the PDF document to disk. doc.Save("FileStructure.pdf") 'Close the document. doc.Close(True) Class Class Class The cross-reference table contains information that permits random access to indirect objects within the file so that the entire file need not be read to locate any particular object. The structure is useful for incremental updates, since it allows a new cross-reference section to be added to the PDF file, containing entries only for objects that have been added or deleted. Cross-reference is represented by cross-reference table. The cross-reference table is the traditional way of representing reference type. Cross-reference is represented by cross-reference stream. Cross-reference streams are stream objects, and contain a dictionary and a data stream. This leads to more compact representation of the file data especially along with the compression enabled. This format is supported by PDF 1.5 version and higher only. Specifies the Pdf document's Conformance-level. Default value is None. To know more about PDF conformance refer this link. //Create a new PDF document. PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A1B); //Add a page in the PDF document. PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font. Font font = new Font("Times New Roman", 10); //Create the PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk. document.Save("ConformanceLevel.pdf"); //Close the document. //document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A1B) 'Create a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk. document.Save("ConformanceLevel.pdf") 'Close the document. document.Close(True) Class Namespace Class Specifies Default / No Conformance. This PDF/A ISO standard [ISO 19005-1:2005] is based on Adobe PDF version 1.4 and This Level B conformance indicates minimal compliance to ensure that the rendered visual appearance of a conforming file is preservable over the long term. This PDF/X-1a:2001 ISO standard [ISO 15930-1] is based on Adobe PDF version 1.3 which uses only CMYK + Spot Color and this compliance to ensure that the contents will be reliably reproduced in the repress environment. PDF/A-2 Standard is based on a PDF 1.7 (ISO 32000-1) which provides support for transparency effects and layers embedding of OpenType fonts //Create a new PDF document PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A2B); //Add a page in the PDF document PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); //Create the PDF font instance PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk document.Save("ConformanceLevel.pdf"); //Close the document //document.Close(true); 'Create a new PDF document Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A2B) 'Create a page to the document Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) PDF/A-3 Standard is based on a PDF 1.7 (ISO 32000-1) which provides support for embedding the arbitrary file formats (XML, CSV, CAD, Word Processing documents) //Create a new PDF document PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A3B); //Add a page in the PDF document PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); //Create the PDF font instance PdfFont pdfFont = new PdfTrueTypeFont(font, false); //Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk document.Save("ConformanceLevel.pdf"); //Close the document //document.Close(true); 'Create a new PDF document Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A3B) 'Create a page to the document Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, False) 'Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) This PDF/A ISO standard [ISO 19005-1:2005] is based on Adobe PDF version 1.4 and This Level A conformance was intended to increase the accessibility of conforming files for physically impaired users by allowing assistive software, such as screen readers, to more precisely extract and interpret a file's contents. /// //Create a new PDF document PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A1A); //Add a page in the PDF document PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); //Create the PDF font instance PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 12, false, true); //Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk document.Save("ConformanceLevel.pdf"); //Close the document //document.Close(true); 'Create a new PDF document Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A1A) 'Create a page to the document Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 12, False, True) 'Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) PDF/A-2 Standard is based on a PDF 1.7 (ISO 32000-1) and This Level A conformance was intended to increase the accessibility of conforming files for physically impaired users by allowing assistive software, such as screen readers, to more precisely extract and interpret a file's contents. /// //Create a new PDF document PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A2A); //Add a page in the PDF document PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); //Create the PDF font instance PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 12, false, true); //Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk document.Save("ConformanceLevel.pdf"); //Close the document //document.Close(true); 'Create a new PDF document Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A2A) 'Create a page to the document Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 12, False, True) 'Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) PDF/A-2 Standard is based on a PDF 1.7 (ISO 32000-1) and This Level U conformance represents Level B conformance (PDF/A-2b) with the additional requirement that all text in the document have Unicode mapping. /// //Create a new PDF document PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A2U); //Add a page in the PDF document PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); //Create the PDF font instance PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 12, false, true); //Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk document.Save("ConformanceLevel.pdf"); //Close the document //document.Close(true); 'Create a new PDF document Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A2U) 'Create a page to the document Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 12, False, True) 'Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) PDF/A-3 Standard is based on a PDF 1.7 (ISO 32000-1) which provides support for embedding the arbitrary file formats (XML, CSV, CAD, Word Processing documents) and This Level A conformance was intended to increase the accessibility of conforming files for physically impaired users by allowing assistive software, such as screen readers, to more precisely extract and interpret a file's contents. /// //Create a new PDF document PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A3A); //Add a page in the PDF document PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); //Create the PDF font instance PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 12, false, true); //Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk document.Save("ConformanceLevel.pdf"); //Close the document //document.Close(true); 'Create a new PDF document Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A3A) 'Create a page to the document Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 12, False, True) 'Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) PDF/A-3 Standard is based on a PDF 1.7 (ISO 32000-1) and This Level U conformance represents Level B conformance (PDF/A-3b) with the additional requirement that all text in the document have Unicode mapping. /// //Create a new PDF document PdfDocument document = new PdfDocument(PdfConformanceLevel.Pdf_A3U); //Add a page in the PDF document PdfPage page = document.Pages.Add(); //Create a 'Times New Roman' font Font font = new Font("Times New Roman", 10); //Create the PDF font instance PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 12, false, true); //Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, new PointF(10, 10)); //Save the document to disk document.Save("ConformanceLevel.pdf"); //Close the document //document.Close(true); 'Create a new PDF document Dim document As PdfDocument = New PdfDocument(PdfConformanceLevel.Pdf_A3U) 'Create a page to the document Dim page As PdfPage = document.Pages.Add() 'Create a 'Times New Roman' font Dim font As Font = New Font("Times New Roman", 10) 'Create the PDF font instance Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 12, False, True) 'Draw text in the new page page.Graphics.DrawString("Essential PDF", pdfFont, PdfBrushes.Black, New PointF(10, 10)) 'Save the document to disk document.Save("ConformanceLevel.pdf") 'Close the document document.Close(True) Specifies the ZugferdConformanceLevel It supports only in PdfConformanceLevel Pdf_A3B //Creates a new PDF document. PdfDocument doc = new PdfDocument(PdfConformanceLevel.Pdf_A3B); //Add a page. PdfPage page = doc.Pages.Add(); //Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic; //Create the PdfTrueTypeFont PdfFont font = new PdfTrueTypeFont(new Font("arial", 12f, FontStyle.Regular), true); page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty); //Creates an attachment PdfAttachment attachment = new PdfAttachment("ZUGFeRD-invoice.xml"); //Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative; attachment.ModificationDate = DateTime.Now; attachment.Description = "About Syncfusion"; attachment.MimeType = "application/xml"; //add attachment to the doucment doc.Attachments.Add(attachment); doc.Save("output.pdf"); 'Creates a new PDF document. Dim doc As New PdfDocument(PdfConformanceLevel.Pdf_A3B) 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic 'Create the PdfTrueTypeFont Dim font As PdfFont = New PdfTrueTypeFont(New Font("arial", 12F, FontStyle.Regular), True) page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty) 'Creates an attachment Dim attachment As New PdfAttachment("ZUGFeRD-invoice.xml") 'Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative attachment.ModificationDate = DateTime.Now attachment.Description = "About Syncfusion" attachment.MimeType = "application/xml" 'add attachment to the doucment doc.Attachments.Add(attachment) doc.Save("output.pdf") Represent the no Level Represent the Basic Level, which contains basic details and additional information included as free text. Represent the Comfort Level, The details are structured and fully automated. Represent the Extend Level, which contains still more structured data for exchanging invoice across different industry segments. This level is fully automated and highly qualified XML Represent the Minimum Level, which contains basic invoice details and compatible with the French standard Factur-X Supported only in version ZUGFeRD 2.0 Represent the EN1 6931 Level, The European standard supported in ZUGFeRD 2.0. Supported only in version ZUGFeRD 2.0 Represent the Basic_WL Level, it does not contain any invoicing information and therefore does not represent VAT-conformant invoices, but in document level it contains accounting entries. Supported only in version ZUGFeRD 2.1 Specifies the ZUGFeRD versions supported. It is supported only in PdfConformanceLevel Pdf_A3B conformance /// //Creates a new PDF document. PdfDocument doc = new PdfDocument(PdfConformanceLevel.Pdf_A3B); //Add a page. PdfPage page = doc.Pages.Add(); //Set the ZugferdProfile. doc.ZugferdVersion = ZugferdVersion.ZugferdVersion1_0; //Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic; //Create the PdfTrueTypeFont PdfFont font = new PdfTrueTypeFont(new Font("arial", 12f, FontStyle.Regular), true); page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty); //Creates an attachment PdfAttachment attachment = new PdfAttachment("ZUGFeRD-invoice.xml"); //Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative; attachment.ModificationDate = DateTime.Now; attachment.Description = "About Syncfusion"; attachment.MimeType = "application/xml"; //add attachment to the doucment doc.Attachments.Add(attachment); doc.Save("output.pdf"); 'Creates a new PDF document. Dim doc As New PdfDocument(PdfConformanceLevel.Pdf_A3B) 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Set the ZugferdProfile. doc.ZugferdVersion = ZugferdVersion.ZugferdVersion1_0 'Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic 'Create the PdfTrueTypeFont Dim font As PdfFont = New PdfTrueTypeFont(New Font("arial", 12F, FontStyle.Regular), True) page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty) 'Creates an attachment Dim attachment As New PdfAttachment("ZUGFeRD-invoice.xml") 'Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative attachment.ModificationDate = DateTime.Now attachment.Description = "About Syncfusion" attachment.MimeType = "application/xml" 'add attachment to the doucment doc.Attachments.Add(attachment) doc.Save("output.pdf") Represent the ZUGFeRD version 1.0 Represent the ZUGFeRD version 2.0 Represent the ZUGFeRD version 2.1 Specifies the file relationship of attachment. //Creates a new PDF document. PdfDocument doc = new PdfDocument(PdfConformanceLevel.Pdf_A3B); //Add a page. PdfPage page = doc.Pages.Add(); //Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic; //Create the PdfTrueTypeFont PdfFont font = new PdfTrueTypeFont(new Font("arial", 12f, FontStyle.Regular), true); page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty); //Creates an attachment PdfAttachment attachment = new PdfAttachment("ZUGFeRD-invoice.xml"); //Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative; attachment.ModificationDate = DateTime.Now; attachment.Description = "About Syncfusion"; attachment.MimeType = "application/xml"; //add attachment to the doucment doc.Attachments.Add(attachment); doc.Save("output.pdf"); 'Creates a new PDF document. Dim doc As New PdfDocument(PdfConformanceLevel.Pdf_A3B) 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Set the ZugferdProfile. doc.ZugferdConformanceLevel = ZugferdConformanceLevel.Basic 'Create the PdfTrueTypeFont Dim font As PdfFont = New PdfTrueTypeFont(New Font("arial", 12F, FontStyle.Regular), True) page.Graphics.DrawString("Hello World", font, PdfBrushes.Black, PointF.Empty) 'Creates an attachment Dim attachment As New PdfAttachment("ZUGFeRD-invoice.xml") 'Set the file relationship attachment.Relationship = PdfAttachmentRelationship.Alternative attachment.ModificationDate = DateTime.Now attachment.Description = "About Syncfusion" attachment.MimeType = "application/xml" 'add attachment to the doucment doc.Attachments.Add(attachment) doc.Save("output.pdf") The original source material for the associated content Represents information used to derive a visual presentation Alternative representation of the PDF contents supplemental representation of the original source or data that may be more easily consumable Relationship is not known or cannot be described using one of the other values Specifies the different page scaling option that shall be selected when a print dialog is displayed for this document. Default value is AppDefault. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Set AppDefault mode as page`s scaling mode. document.ViewerPreferences.PageScaling = PageScalingMode.AppDefault; //Add a page in the PDF document. PdfPage page = document.Pages.Add(); //Create the PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw the text in PDF page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); //Save documen to disk. document.Save("ScalingMode.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Set AppDefault mode as page`s scaling mode. document.ViewerPreferences.PageScaling = PageScalingMode.AppDefault 'Add a page in the PDF document. Dim page As PdfPage = document.Pages.Add() 'Create the PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold) 'Draw the text in PDF page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) 'Save document to disk. document.Save("ScalingMode.pdf") 'Close the document. document.Close(True) Class Class Class Class Class Indicates the conforming reader�s default print scaling. Indicates no page scaling. indicates the type of the portfolio schema field. Represent the types as string Represent the type of the portfolio schema field as date Represent the type of the portfolio schema field as number Represent the type of the portfolio schema field as filename Represent the type of the portfolio schema field as description Represent the type of the portfolio schema field as moddate Represent the type of the portfolio schema field as creationdate Represent the type of the portfolio schema field as size indicates the type of the portfolio view mode. Represent the portfolio view mode as details Represent the portfolio view mode as tile Represent the portfolio view mode as hidden Represents the analyzer of the Pdf document. Initializes a new instance of the class with the specified input file path. A relative or absolute path for the file. string filePath = "Input.pdf"; //load the document PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(filePath); //Analyze the synyax issue SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Initializes a new instance of the class with the specified stream. The stream containing the PDF document to analyze. string filePath = "Input.pdf"; Stream streamFile = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); load the stream PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(streamFile); //Analyze syntax issues. SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Initializes a new instance of the class. A relative or absolute path for the file. The password (user or owner) of the encrypted document. string filePath = "Input.pdf"; //load the document PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(filePath, "password"); //Analyze the synyax issue SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Initializes a new instance of the class. The stream containing the PDF document to analyze. The password (user or owner) of the encrypted document. string filePath = "Input.pdf"; Stream streamFile = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); load the stream with password PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(streamFile, "passsword"); //Analyze the syntax issues. SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Analyze the given PDF file and check whether any syntax issues found. string filePath = "Input.pdf"; //load the document PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(filePath); //Analyze the synyax issue SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Close the class. string filePath = "Input.pdf"; //load the document PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(filePath); //Analyze the syntax issues. SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Represents the PDF document analyzer result. string filePath = "Input.pdf"; //load the document PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(filePath); //Analyze the synyax issue SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Gets the errors. Represernts the PDF document syntax analyzer result. string filePath = "Input.pdf"; //load the document PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(filePath); //Analyze the syntax issues. SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Gets the Syntax errors. Gets whether the document is corrupted or not. string filePath = "Input.pdf"; //load the document PdfDocumentAnalyzer analyzer = new PdfDocumentAnalyzer(filePath); //Analyze the synyax issue SyntaxAnalyzerResult analyzerResult = analyzer.AnalyzeSyntax(); if(analyzerResult.IsCorrupted) { throw new Exception("The document is corrupt"); } analyzer.Close(); Decodes the ASCII85 encoded byte[] encoded byte[] decoded byte[] asciihexdecode using our own implementation local variable to store the value true if image is used for extraction Converts DeviceCMYK colorspace to RGB colourspace Converts the CMYK values to RGB Process the ColorSpace property in the Image dictionary To Apply the ICCBased Colorspace in the Image Stream Skips the escape sequence from the given input string String with the escape sequence String without escape sequence Decodes the ASCII85 encoded stream Encoded stream Decoded Stream Decodes the Flate encoded stream Encoded stream Decoded Stream Decodes JBIG2 encoded input stream Input image stream Returns the output as image. Merges the stream of the two images Stream of the original image Encoded stream of the mask image Stream of the merged image sRgbToScRgb conversion Byte value of the color Equivalent float value ScRgbTosRgb conversion Float value of the color Equivalent byte value Decodes the stream of the mask image in the PDF document Encoded stream from the PDF document Decoded stream of the image Decodes the stream based on the predictor values Predictor from the decode params Colors from the decode params Columns from the decode params Stream the encoded image Decoded stream Converts YCCK colorspace to RGB colorspace Byte array of YCCK image Byte array of RGB image Converts YCC colorspace image to RGB image Byte array of YCC image Byte array of RGB image Render the RGB Pixels from the Image Bytes Image Bytes which converts into Pixels Gets or sets "true" when an image is used for Extraction. Holds the stream of the mask image associated with the original image Gets BitsPerComponent value of the original image Occurs prior to the rendering of every image in the document ImagePreRenderEventArgs Custom event argument class used to notify before image is rendered in the viewer. Gets or sets the content stream of the image. Gets or sets height of the image. Gets or sets width of the image. Returns filter names used in the image. white run lengths black run lengths Display information found in this COD marker segment Display information found in this COC marker segment Display information found in this RGN marker segment Decodes the image stream in the PDF document into an image Sets the fields associated with the TIFF image Number of fields Value of the field Name of the TIFF tag Type of the tag value Writes the header to the TIFF image Specifies the header of the TIFF image Writes the list of fields associated with the TIFF image List of TIFF fields Writes short value into the TIFF stream Short value to be written Writes integer value into the TIFF stream Integer value to be written Structure of the TIFF header Size of the byte order of the tiff image TIFF version number byte offset to first directory Tag entry to the TIFF stream Represents the TIFF tag Represents the type of the TIFF tag number of items; length in spec byte offset to field data Width of the image in pixels Height of the image in pixels Bits per channel (sample). Compression technique Photometric interpretation. Offsets to data strips. Samples per pixel. Bytes counts for strips. 16-bit unsigned integer. 32-bit unsigned integer. The Syncfusion.Pdf.Exporting namespace contains classes to perform export operations. Represents the utility class to store information about Images and its location. //Load PDF document. PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Gets ImageInfo from the first page. PdfImageInfo[] imageInfo = document.Pages[0].ImagesInfo; //Gets the Image Boundary location. RectangleF imageBounds = imageInfo[0].Bounds; //Gets the Image. Image image = imageInfo[0].Image; //Gets the Image index. int imageIndex = imageInfo[0].Index; //Closing the PDF document. document.Close(true); 'Load PDF document. Dim document As New PdfLoadedDocument("Input.pdf") 'Gets ImageInfo from the first page. Dim imageInfo As PdfImageInfo() = document.Pages(0).ImagesInfo 'Gets the Image Boundary location. Dim imageBounds As RectangleF = imageInfo(0).Bounds 'Gets the Image. Dim image As Image = imageInfo(0).Image 'Gets the Image index. Dim imageIndex As Integer = imageInfo(0).Index 'Closing the PDF document. document.Close(True) Local Variable to store the image bounds. Local Variable to store the image. Local Variable to store the image index. Internal variable to store the image name. Internal variable to store the matrix. Internal variable to store the image name. Internal variable , it identifies the image is extracted or not. Initializes a new instance of the class. Initializes a new instance of the class. Image bounds Image Image index Initializes a new instance of the class. Image bounds Image Image index Image name Gets the Image Boundary location. Gets the Image. Gets the Image index. Gets the image name. Gets the matrix. Gets the matrix. Returns true, if soft masking is applied. Set to true when the image is undergone soft masking. Returns true, if image masking is applied. Set to true when the image is undergone image masking. Returns true, when the image property in the PDF document is set to undergo interpolation. Gets or sets the image is extracted or not. Gets XMP metadata of the image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk with enable metadata extraction. PdfBitmap image = new PdfBitmap(File.OpenRead("Autumn Leaves.jpg"), true); //Get image metadata XmpMetadata metadata = image.Metadata; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk with enable metadata extraction. Dim image As New PdfBitmap(File.OpenRead("Autumn Leaves.jpg"), true) 'Get image metadata Dim metadata As XmpMetadata = image.Metadata 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represents the utility class for extracting text from the stream. Internal variable to store the number of characters. variable to hold font name and difference arrary. variable to hold decoded Character Initializes a new instance of the class. Extracts text from the bytes. The byte array. The Extracted Text. Extracts text from the bytes. The byte array. type The Extracted Text. Extracts text from the bytes. The byte array. The Current Page Object. Font Name Collection. Font Reference Holder Colllection. The Extracted Text. Extracts text from the bytes(True Type Font Documents). The byte array. The Extracted Text. Extracts text from the bytes(Embed Fonts). The byte array. The Current Page Object. Font Name Collection. Font Reference Holder Colllection. The Extracted Text. Extracts text from Type0 The byte array. The Extracted Text. Checks the token. The tokens. The recent. token Gets Latin Character The decodedCharacter. decodedCharacter Gets Latin Character The decodedCharacter. decodedCharacter Variable to hold the glyph string and its glyph shapes Variable to hold the font matrix Variable to hold the character code and character Variable to hold the already cached path Variable to hold the globalBias value for glyphs Gets or sets the glyph string and its shapes Gets or sets the globalbias Gets or sets the font matrix Gets or sets the character code and character Gets or sets the already cached path Writes short value into the font stream Short value to be written Writes integer value into the font stream Integer value to be written Writes string value into the font stream String value to be written Write the bytes into the font stream byte array to be written constant used in eexec and charset decode constant used in eexec and charset decode Represents the number of random bytes in stream to ignore Variable to hold the glyph string and its glyph shapes Variable to hold the character code and character Variable to hold the font matrix Variable to cff glyphs needed so CIDFOnt0 can extend Parse the difference encoding Handle encoding for type1 fonts parse the encoded part from a type 1 font extract the subroutine data Extract Font Data extract bytestream with char data Variable to hold the font matrix Variable to cff glyphs lookup table for names for type 1C glyphs Lookup table to map values lookup data to convert Expert values Represents the graphics object Generate the font stream with respect to the font tables present in the entries list of font tables in the font stream of the font Writes the header into the font stream Header information of the font Writes table entry into the font stream Table entry Writes short value into the font stream Short value to be written Writes integer value into the font stream Integer value to be written Writes string value into the font stream String value to be written Write the bytes into the font stream byte array to be written Calculates the search range of the font Number of tables in the font Value of the search range Calculates the entry selector of the font Number of tables in the font Value of the entry selector Calculates the range shift of the font Number of tables in the font Search range of the font Value of the range shift Reads the header of the font Reads the table part to get the details about the tables in the font read Returns the id of the font table corresponding to the tag Font tag Corresponding table ID Reads 4 bytes from the byte array Corresponding value Reads 8 bytes from the byte array Corresponding value Read 4 bytes from the byte array Corresponding string value Read 2 bytes from the byte array Corresponding integer value Separated the byte array corresponding to the table entry from the font stream Table ID Byte array of the table Get table bytes Reads 4 bytes from the byte array Corresponding value Reads 8 bytes from the byte array Corresponding value Read 4 bytes from the byte array Corresponding string value Read 2 bytes from the byte array Corresponding integer value Internal variable that holds cff glyphs Takes in the encoded text, identifies the type of encoding used, decodes the encoded text, returns the decoded text. Encoded string from the PDF document. Decoded string, human readable. Decodes the octal text in the encoded text. The text encoded from the PDF document Decoded text with replaced octal texts Decodes the HEX encoded string. HEX encoded string. Decoded string. Extracts the font name associated with the string. Font name. Extracts the font style associated with the text string Font style. Extracts the font encoding associated with the text string Font style. Parsing the stream from the Adobe-Japan1-6.cidmap resource to create CIDMapTable CID map table resource Adobe Japan CID map table Parse the Japanese character where the value is reference to another key in the Adobe Japan Cid Map Table mapped value which is a reference to another key Mapped Character present in the Adobe Japan Cid Map table Decodes the ASCII85 encoded stream Encoded stream Decoded Stream Decodes the Flate encoded stream Encoded stream Decoded Stream Builds the mapping table that is used to map the decoded text to get the expected text. A dictionary with key as the encoded element and value as the value to be mapped to. Builds the mapping table that is used to map the decoded text to get the expected text. Gets Latin Character The decodedCharacter. decodedCharacter Gets Latin Character The decodedCharacter. decodedCharacter Takes in the decoded text and maps it with its corresponding entry in the CharacterMapTable decoded text Expected text string Takes in the decoded text and maps it with its corresponding entry in the CharacterMapTable encoded text Expected text string Method to remove the new line character Text with new line character Text without new line character Organizes the hex string enclosed within the hexa brackets Mapping string in the map table of the document list of HEX entries in the string Checks whether the specified character is Non-Printable character or not. The character to be verified as either Non-Printable or not Returns true, if the specified character is Non-Printable character. Otherwise it returns false Gets or sets the value indicating whether the encoded text is hexa decimal string Holds the font name associated with the text element Holds the font style of the text to be decoded. Gets and sets whether same font is denoted in more than one XObject. Holds the font encoding associated with the text element Collects all the ExtendedGraphicsSatate elements in the pdf document containing all the resources of the document dictionary of ExtGState elements Collects all the fonts in the page in a dictionary dictionary containing all the resources in the Xobjects dictionary containing font name and the font Extracts the text from the page given page from which text is extracted font used in the text text in the page to be decoded decoded text Collects all the fonts in the page in a dictionary dictionary containing all the resources in the page page in which text is to be extracted dictionary containing font name and the font Collects all the images in the pdf document containing all the resources of the document dictionary of images Updates the resources in the page Existing page resources Dictionary items to the updated Updated page resource The class provides methods and properties to access the PDF page resources. Returns if the FontCollection has same font face. if font present true, else false Initializes the new instance of the class Adds the resource with the specified name. Name of the resource Resource to add Returns if the key already exists. if key present true,else false Gets the PDF page resources. Gets or sets the value associated with the key. Gets or sets the value that indicating the extracting of text data. Gets or sets the value that indicating the extracting of text data. Gets or sets the value that indicating the extracting of text data. Represents class which draws form fields. Internal variable to store white brush. Internal variable to store black brush. Internal variable to store silver brush. Internal variable to store gray brush. Internal variable to store cached pens. Internal variable to store string format for check field symbols. Draws a button. The g. The paint params. The text. The font. The format. Draws a pressed button. The g. The paint params. The text. The font. The format. Draws a button. The g. The paint params. The text. The font. The format. Draws a list box. The graphics. The paint params. The items. The selected item index. The font. The string format. Draws a check box. The g. The paint params. The check symbol. The state. Draws a check box. The g. The paint params. The check symbol. The state. The font. Draws a combo box. The g. The paint params. Draws a combo box. The g. The paint params. Draws the radio button. The g. The paint params. The check symbol. The state. Draws the signature. The g. The paint params. Draws the ellipseannotation. The g. The paint params. The x. The y. The width. The height. Draws the rectangleannotation. The g. The paint params. The x. The y. The width. The height. Draws the Cloud polygon annotation. The g. The paint params. The radius. The points. Draws the cloud rectangle annotation. The g. The paint params. The rectangle. The radius. The width. The borderwidth. Draws the cloud shape. The g. The PdfBrush. The PdfPen. The radius. The overlap. The PointF. The Appearance. Draws the freetextannotation. The g. The paint params. The text. The font. The rect. Draws a border. The g. The bounds. The border pen. The style. Width of the border. Draws the round border. The g. The bounds. The border pen. Width of the border. Draws a rectangular control. The g. The paint params. Draws the left top shadow. The g. The bounds. The width. The brush. Draws the right bottom shadow. The g. The bounds. The width. The brush. Draws the round shadow. The g. The paint params. The state. Gets the pen. The color. The width. Gets the white brush. The white brush. Gets the black brush. The black brush. Gets the gray brush. The gray brush. Gets the silver brush. The silver brush. Gets the check box format. The check box format. Represents class with field's paint parameters. Internal variable to store back brush. Internal variable to store fore brush. Internal variable to store border width. Internal variable to store border pen. Internal variable to store border style. Internal variable to store bounds. Internal variable to store shadow brush. Rotation angle of the form fields. Initializes a new instance of the class. Initializes a new instance of the class. The bounds. The back brush. The fore brush. The border pen. The style. Width of the border. The shadow brush. Gets or sets the back brush. The back brush. Gets or sets the fore brush. The fore brush. Gets or sets the border pen. The border pen. Gets or sets the border style. The border style. Gets or sets the width of the border. The width of the border. Gets or sets the bounds. The bounds. Gets or sets the shadow brush. The shadow brush. Gets or Set the rotation angle. Rotation of current form field page Represents form field with appearance custom support. Class Represents form's field with style parameters. Class Represents field of the PDF document's interactive form. Interface Internal variable to store field's name. Internal variable to store page. Internal variable to store flags of the field. Internal variable to store form. Internal variable to store mapping name. Internal variable to store value whether to export field's data. Internal variable to store value whether the field is read only. Internal variable to store value whether the field is required. Internal variable to store tool tip. Internal variable to store dictionary. Form flatten. Indicates if AutoFormat has to be removed. Internal variable to store tab index of the field Internal variable to store form field index Indicates whether the field support complex script. Indicates variable to store the PdfLayer map to the field Initializes a new instance of the class with the specific page and name. The page where the field should be placed. The name. Initializes a new instance of the class. Sets the form. The form. Saves an object. Draws this instance if it is flatten. Sets the proper name to the field. The name. Clones the field. The page. The copy of the field. Defines default appearance. Initializes this instance. Handles the BeginSave event of the m_dictionary control. The source of the event. The instance containing the event data. Obtain Document layer from AcroFrom Finds the excepted object with layer collection Gets the name of the .[Read-Only] The name. Gets the form of the .[Read-Only] The form. Gets or sets the mapping name to be used when exporting interactive form field data from the document. The mapping name. Gets or sets a value indicating whether this is export. true if export; otherwise, false. Gets or sets a value indicating whether this field is read-only. if the field is read only, set to true. Gets or sets a value indicating whether this is required. true if required; otherwise, false. Gets or sets the tool tip. The tool tip. Gets the page of the field.[Read-Only] The page. Gets or sets a value indicating whether to flatten this . Gets or sets the flags. The flags. Gets or sets the dictionary. The dictionary. Gets or sets a value indicating whether to disable auto format this . Get or set tag for the field Gets or sets the tab index for form fields Gets or sets the form field index Gets or sets the PdfLayer to the AcroForm fields //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Creates a PdfLayer PdfLayer layer = document.Layers.Add("Hello"); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; //Set layer to text box field firstNameTextBox.Layer = layer; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Creates a PdfLayer Dim layer As PdfLayer = document.Layers.Add("Hello") Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font 'Set layer to text box field firstNameTextBox.Layer = layer page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Gets the element. Internal variable to store color shift value. Internal variable to store rotation value. Internal variable to store widget of the field. Internal variable to store field's font. Internal variable to store actions of the field. Internal variable to store appearance template. Internal variable to store back color. Internal variable to store color of background rectangle. Internal variable to store fore pen. Internal variable to store border pen. Internal variable to store string format. Internal variable to store shadow brush. Internal variable to store visibility of the field. Represents the visibility of the field Initializes a new instance of the class with the specific page and name. The page where the field should be placed. The name. Initializes a new instance of the class. Draws this instance if it is flatten. Removes the annotation from page. The page. The widget. Adds the annotation to page. The page. The widget. Gets the font. If font is undefined default font will be used. font Initializes an instance. Defines the default appearance. Creates the border pen. Creates the back brush. Gets or sets the bounds. The bounds. Gets or sets the form field visibility Gets or sets the location of the field. The location. Gets and sets the Rotation angle in the form fields //create a new PDF document PdfDocument document = new PdfDocument(); //Add a new page to the PDF document. PdfPage page = document.Pages.Add(); //set the page rotation angle. document.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle0; //Create a textbox field and add the properties. PdfTextBoxField textBoxField = new PdfTextBoxField(page, "FirstName"); textBoxField.Bounds = new RectangleF(0, 40, 100, 20); textBoxField.ToolTip = "First Name"; //Gets and sets the rotation angle in the form fields. textBoxField.RotationAngle = 90; //add the field to the collection document.Form.Fields.Add(textBoxField); //enable or disable set appearance document.Form.SetDefaultAppearance(true); //Save the document. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Add a new page to the PDF document. Dim page As PdfPage = document.Pages.Add() 'set the page rotation angle. document.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle0; 'Create a textbox field and add the properties. Dim textBoxField As PdfTextBoxField = New PdfTextBoxField(page, "FirstName") textBoxField.ToolTip = "First Name"; 'Gets and sets the rotation angle in the form fields. textBoxField.RotationAngle = 90; 'add the field to the collection document.Form.Fields.Add(textBoxField) 'enable or disable set appearance document.Form.SetDefaultAppearance(True) 'save the document document.Save("Output.pdf") 'close the document document.Close(True) /// The rotation angle value shall be a multiple of 90. Default value: 0. Gets or sets the size of the field. The size. Gets or sets the color of the border. The color of the border. Gets or sets the color of the background. The color of the background. Gets or sets the color of the background rectangle of field. The color of the background rectangle of field. Gets or sets the color of the text. The color of the text. Gets or sets the width of the border. The width of the border. Gets or sets the highlighting mode. The highlighting mode. Gets or sets the font. The font. Gets or sets the text alignment. The text alignment. This property is meaningful for fields containing variable text only. (i.e. , and ). Gets the actions of the field.[Read-Only] The actions. Gets or sets the border style. The border style. Gets or sets a value indicating whether this is visible. true if visible; otherwise, false. Gets the right bottom beveled Shadow brush. The right bottom beveled Shadow brush. Gets the widget. The widget. Gets the appearance template. The appearance template. Gets the back brush. The back brush. Gets the border pen. The border pen. Gets the fore pen. The fore pen. Gets the string format. The string format. Initializes a new instance of the class. Initializes a new instance of the class. Page The name. Saves an object. Draws this instance if it is flatten. Draws the appearance. The template. Gets the appearance.[Read-Only] The appearance. Represents button field in the PDF form. This class is used to add the button field to the PDF form. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; // Creating action PdfSubmitAction submitAction = new PdfSubmitAction("http://stevex.net/dump.php"); submitAction.DataFormat = SubmitDataFormat.Html; //Create submit button to transfer the values in the form PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(100, 500, 90, 20); submitButton.Font = font; submitButton.Text = "Submit"; submitButton.Actions.MouseUp = submitAction; document.Form.Fields.Add(submitButton); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics ' Creating action Dim submitAction As PdfSubmitAction = New PdfSubmitAction("http://stevex.net/dump.php") submitAction.DataFormat = SubmitDataFormat.Html 'Create submit button to transfer the values in the form Dim submitButton As PdfButtonField = New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(100, 500, 90, 20) submitButton.Font = font submitButton.Text = "Submit" submitButton.Actions.MouseUp = submitAction document.Form.Fields.Add(submitButton) document.Save("Form.pdf") document.Close(True) Class Class Class Internal variable to store button's caption. Initializes a new instance of the class with the specific page and name. The page where the fields should be placed. The name of the button. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; // Creating action PdfSubmitAction submitAction = new PdfSubmitAction("http://stevex.net/dump.php"); submitAction.DataFormat = SubmitDataFormat.Html; //Create submit button to transfer the values in the form PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(100, 500, 90, 20); submitButton.Font = font; submitButton.Text = "Submit"; submitButton.Actions.MouseUp = submitAction; document.Form.Fields.Add(submitButton); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics ' Creating action Dim submitAction As PdfSubmitAction = New PdfSubmitAction("http://stevex.net/dump.php") submitAction.DataFormat = SubmitDataFormat.Html 'Create submit button to transfer the values in the form Dim submitButton As PdfButtonField = New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(100, 500, 90, 20) submitButton.Font = font submitButton.Text = "Submit" submitButton.Actions.MouseUp = submitAction document.Form.Fields.Add(submitButton) document.Save("Form.pdf") document.Close(True) Class Class Class Initializes a new instance of the class. Adds Print action to current button field. Clicking on the specified button will trigger the Print Dialog Box. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; // Creating action PdfSubmitAction submitAction = new PdfSubmitAction("http://stevex.net/dump.php"); submitAction.DataFormat = SubmitDataFormat.Html; //Create submit button to transfer the values in the form PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(100, 500, 90, 20); submitButton.Font = font; submitButton.Text = "Submit"; // Subscribing print action submitButton.AddPrintAction(); submitButton.Actions.MouseUp = submitAction; document.Form.Fields.Add(submitButton); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics ' Creating action Dim submitAction As PdfSubmitAction = New PdfSubmitAction("http://stevex.net/dump.php") submitAction.DataFormat = SubmitDataFormat.Html 'Create submit button to transfer the values in the form Dim submitButton As PdfButtonField = New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(100, 500, 90, 20) submitButton.Font = font submitButton.Text = "Submit" ' Subscribing print action submitButton.AddPrintAction() submitButton.Actions.MouseUp = submitAction document.Form.Fields.Add(submitButton) document.Save("Form.pdf") document.Close(True) Class Class Class Draws this instance if it is flatten. Saves an instance. Initializes an instance. Draws the appearance. The template. Draws the pressed appearance. The template. Gets or sets the complex script language support. /// //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Create a new button field. PdfButtonField buttonField = new PdfButtonField(page, "Click"); //Set bounds buttonField.Bounds = new RectangleF(0, 0, 300, 20); //Set font. buttonField.Font = pdfFont; //Set text. buttonField.Text = "เสนอ"; //Enable complex script. buttonField.ComplexScript = true; //Add field to form. document.Form.Fields.Add(buttonField); document.Form.SetDefaultAppearance(false); //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Create a new button field. Dim buttonField As New PdfButtonField(page, "Click") 'Set bounds buttonField.Bounds = New RectangleF(0, 0, 300, 20) 'Set font. buttonField.Font = pdfFont 'Set text. buttonField.Text = "เสนอ" 'Enable complex script. buttonField.ComplexScript = True 'Add field to form. document.Form.Fields.Add(buttonField) document.Form.SetDefaultAppearance(False) 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or sets the caption text. The caption text. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; // Creating action PdfSubmitAction submitAction = new PdfSubmitAction("http://stevex.net/dump.php"); submitAction.DataFormat = SubmitDataFormat.Html; //Create submit button to transfer the values in the form PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(100, 500, 90, 20); submitButton.Font = font; submitButton.Text = "Submit"; submitButton.Actions.MouseUp = submitAction; document.Form.Fields.Add(submitButton); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics ' Creating action Dim submitAction As PdfSubmitAction = New PdfSubmitAction("http://stevex.net/dump.php") submitAction.DataFormat = SubmitDataFormat.Html 'Create submit button to transfer the values in the form Dim submitButton As PdfButtonField = New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(100, 500, 90, 20) submitButton.Font = font submitButton.Text = "Submit" submitButton.Actions.MouseUp = submitAction document.Form.Fields.Add(submitButton) document.Save("Form.pdf") document.Close(True) Class Class Represents check box field in the PDF form. This class is used to add the check box field to the PDF form. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); checkBox.Bounds = new RectangleF(100, 290, 20, 20); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; //Set the value for the check box checkBox.Checked = true; document.Form.Fields.Add(checkBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") checkBox.Bounds = New RectangleF(100, 290, 20, 20) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled 'Set the value for the check box checkBox.Checked = True document.Form.Fields.Add(checkBox) document.Save("Form.pdf") document.Close(True) Class Class Class Represents base class for field which can be in checked and unchecked states. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); checkBox.Bounds = new RectangleF(100, 290, 20, 20); document.Form.Fields.Add(checkBox); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; //Set the value for the check box checkBox.Checked = true; document.Form.Fields.Add(checkBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") checkBox.Bounds = New RectangleF(100, 290, 20, 20) document.Form.Fields.Add(checkBox) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled 'Set the value for the check box checkBox.Checked = True document.Form.Fields.Add(checkBox) document.Save("Form.pdf") document.Close(True) Class Class Class Class Internal variable to store check box' style. Internal variable to store template for checked state. Internal variable to store template for unchecked state. Internal variable to store template for pressed checked state. Internal variable to store template for presssed unchecked state. Initializes a new instance of the class with the specific page and name. The page where the fields should be placed. The name of the check box field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); checkBox.Bounds = new RectangleF(100, 290, 20, 20); document.Form.Fields.Add(checkBox); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; //Set the value for the check box checkBox.Checked = true; document.Form.Fields.Add(checkBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") checkBox.Bounds = New RectangleF(100, 290, 20, 20) document.Form.Fields.Add(checkBox) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled 'Set the value for the check box checkBox.Checked = True document.Form.Fields.Add(checkBox) document.Save("Form.pdf") document.Close(True) Class Class Class Class Initializes a new instance of the class. Styles to string. The style. String representation of the check box' style. Initializes an instance. Saves an instance. Draws the appearance. Ensures the template is created. The template. Releases the template. Draws this instance if it is flatten. Gets or sets the style. The object specifies the style of the check box field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); //Set the value for the check box checkBox.Style = PdfCheckBoxStyle.Circle; checkBox.Bounds = new RectangleF(100, 290, 20, 20); document.Form.Fields.Add(checkBox); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; //Set the value for the check box checkBox.Checked = true; document.Form.Fields.Add(checkBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") 'Set the value for the check box checkBox.Style = PdfCheckBoxStyle.Circle checkBox.Bounds = New RectangleF(100, 290, 20, 20) document.Form.Fields.Add(checkBox) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled 'Set the value for the check box checkBox.Checked = True document.Form.Fields.Add(checkBox); document.Save("Form.pdf") document.Close(True) Class Class Class Class Gets or sets the checked template. The checked template. Gets or sets the unchecked template. The unchecked template. Gets or sets the pressed checked template. The pressed checked template. Gets or sets the pressed unchecked template. The pressed unchecked template. Internal variable to store value whether the check box is checked. Initializes a new instance of the class with the specific page and name. The page where the fields should be placed. The name of the check box field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); checkBox.Bounds = new RectangleF(100, 290, 20, 20); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; //Set the value for the check box checkBox.Checked = true; document.Form.Fields.Add(checkBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") checkBox.Bounds = New RectangleF(100, 290, 20, 20) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled 'Set the value for the check box checkBox.Checked = True document.Form.Fields.Add(checkBox) document.Save("Form.pdf") document.Close(True) Class Class Class Saves an instance. Draws this instance if it is flatten. Draws the appearance of the field. Gets or sets a value indicating whether this is checked. true if checked; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics graphics = page.Graphics; //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); //Set the value for the check box checkBox.Checked = true; checkBox.Bounds = new RectangleF(100, 290, 20, 20); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; //Set the value for the check box checkBox.Checked = true; document.Form.Fields.Add(checkBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim graphics As PdfGraphics = page.Graphics 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") 'Set the value for the check box checkBox.Checked = True checkBox.Bounds = New RectangleF(100, 290, 20, 20) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled 'Set the value for the check box checkBox.Checked = True document.Form.Fields.Add(checkBox) document.Save("Form.pdf") document.Close(True) Class Class Class Represents combo box field in the PDF Form. This class is used to create the combo box field in PDF forms. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) document.Save("Form.pdf") document.Close(True) Class Class Class Class Class Represents base class for form's list fields. Class Internal variable to store collection of items. Internal variable to store selected item index. Internal variable to store mulitple selected items. Initializes a new instance of the class with the specific page and name. Page which the field to be placed on. The name of the field. Initializes a new instance of the class. Draws this instance if it is flatten. Initializes an instance. Gets the list field items.[Read-Only] The items. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); listBox.SelectedIndex = 0; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) listBox.SelectedIndex = 0 document.Save("Form.pdf") document.Close(True) Class Interface Class Class Class Gets or sets the first selected item in the list. The index of the selected item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); //Set the first selected item in the list. listBox.SelectedIndex = 0; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) 'Set the first selected item in the list. listBox.SelectedIndex = 0 document.Save("Form.pdf") document.Close(True) Class Interface Class Class Class Gets or sets the value of the first selected item in the list. The selected value. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); //Set the value of the first selected item in the list. listBox.SelectedValue = "English"; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) 'Set the value of the first selected item in the list. listBox.SelectedValue = "English" document.Save("Form.pdf") document.Close(True) Class Interface Class Class Class Gets the first selected item in the list.[Read-Only] The selected item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); //Get the first selected item in the list. PdfListFieldItem selectedItem = listBox.SelectedItem; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) 'Get the first selected item in the list. Dim selectedItem As PdfListFieldItem = listBox.SelectedItem document.Save("Form.pdf") document.Close(True) Class Interface Class Class Class Gets or sets multiple selected indexes Internal variable to store value whether the combobox is editable. Initializes a new instance of the class with the specific page and name. Page of the field to be placed on. The name of the field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) document.Save("Form.pdf") document.Close(True) Class Class Class Class Initializes a new instance of the class. Draws this instance if it is flatten. Initializes an instance. Draws the appearance. The template. Gets the height of the font. The calculated size of font. Gets or sets the complex script language support. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Create a new combo box field. PdfComboBoxField comboBox = new PdfComboBoxField(page, "combo"); //Set bounds comboBox.Bounds = new RectangleF(0, 0, 300, 20); //Set font. comboBox.Font = pdfFont; //Add items. comboBox.Items.Add(new PdfListFieldItem("สวัสดีชาวโลก", "One")); comboBox.Items.Add(new PdfListFieldItem("สวัสดีชาวโลก", "Two")); //Set selected index. comboBox.SelectedIndex = 0; //Enable complex script. comboBox.ComplexScript = true; //Add field to form. document.Form.Fields.Add(comboBox); document.Form.SetDefaultAppearance(false); //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Create a new combo box field. Dim comboBox As New PdfComboBoxField(page, "combo") 'Set bounds comboBox.Bounds = New RectangleF(0, 0, 300, 20) 'Set font. comboBox.Font = pdfFont 'Add items. comboBox.Items.Add(New PdfListFieldItem("สวัสดีชาวโลก", "One")) comboBox.Items.Add(New PdfListFieldItem("สวัสดีชาวโลก", "Two")) 'Set selected index. comboBox.SelectedIndex = 0 'Enable complex script. comboBox.ComplexScript = True 'Add field to form. document.Form.Fields.Add(comboBox) document.Form.SetDefaultAppearance(False) 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or sets a value indicating whether this is editable. true if editable; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) document.Save("Form.pdf") document.Close(True) Class Class Class Class Internal variable to store duplicate field exception message. Internal variable to store array of fields. Private variable to store the form field names and thier index Initializes a new instance of the class. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = new PdfFieldCollection(); fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = New PdfFieldCollection() fieldCollection = document.Form.Fields ' Flatten the form collection For i As Integer = 0 To fieldCollection.Count - 1 fieldCollection(i).Flatten = True Next i 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Class Interface Adds the specified field to the collection. The field item which is added in the PDF form. The field to be added on the page. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfFieldCollection fieldCollection = document.Form.Fields; //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; fieldCollection.Add(positionComboBox as PdfField); //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True fieldCollection.Add(TryCast(positionComboBox, PdfField)) 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Class Add the XFA form fields Inserts the field at the specified index. The index of the field. The field which should be inserted at the specified index. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); checkBox.Bounds = new RectangleF(100, 290, 20, 20); document.Form.Fields.Add(checkBox); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; //Set the value for the check box checkBox.Checked = true; document.Form.Fields.Add(checkBox); PdfFieldCollection fieldCollection = document.Form.Fields; //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; // Insert the field at first position in the collection fieldCollection.Insert(0, positionComboBox as PdfField); //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") checkBox.Bounds = New RectangleF(100, 290, 20, 20) document.Form.Fields.Add(checkBox) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled 'Set the value for the check box checkBox.Checked = True document.Form.Fields.Add(checkBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True ' Insert the field at first position in the collection fieldCollection.Insert(0, TryCast(positionComboBox, PdfField)) 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Class Determines whether field is contained within the collection. Check whether object is present in the field collection or not. true if field is present in the collection, otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfFieldCollection fieldCollection = document.Form.Fields; //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; if (fieldCollection.Contains(positionComboBox as PdfField)) MessageBox.Show("Already added field"); else fieldCollection.Add(positionComboBox as PdfField); //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True If fieldCollection.Contains(TryCast(positionComboBox, PdfField)) Then MessageBox.Show("Already added field") Else fieldCollection.Add(TryCast(positionComboBox, PdfField)) End If 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Class Gets the index of the specific field. The object whose index is requested. Index of the field in collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfFieldCollection fieldCollection = document.Form.Fields; //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; document.Form.Fields.Add(positionComboBox); int index = fieldCollection.IndexOf(positionComboBox as PdfField); //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True document.Form.Fields.Add(positionComboBox) Dim index As Integer = fieldCollection.IndexOf(TryCast(positionComboBox, PdfField)) 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Class Removes the specified field in the collection. The object to be removed from collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfFieldCollection fieldCollection = document.Form.Fields; //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); document.Form.Fields.Add(positionComboBox); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; fieldCollection.Remove(positionComboBox as PdfField); //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") document.Form.Fields.Add(positionComboBox) positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True fieldCollection.Remove(TryCast(positionComboBox, PdfField)) 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Class Removes field at the specified position. The index where to remove the item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfFieldCollection fieldCollection = document.Form.Fields; //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); document.Form.Fields.Add(positionComboBox); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; // Remove the first element fieldCollection.RemoveAt(0); //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") document.Form.Fields.Add(positionComboBox) positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True ' Remove the first element fieldCollection.RemoveAt(0) 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Class Adds the specified field. The field. The new page. Index of added field. Add the specified XFA form fields Adds a field to collection. The field. field. Inserts a filed into collection. The index. The field. Removes the field from collection. The field. Removes the field at the specified position. The index. Clears the collection. Inserts the loaded field. The field. The new page. field. Updates the references. The kids array. The array. The new array. Returns the form field index by validating the fieldnames Gets the at the specified index.[Read-Only] //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields ' Flatten the form collection For i As Integer = 0 To fieldCollection.Count - 1 fieldCollection(i).Flatten = True Next i 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Gets the with their field name.[Read-Only] //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection fieldCollection["positionComboBox"].Flatten = true; //Save the document to disk. document.Save("Form.pdf"); //Close the document. document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields ' Flatten the form collection fieldCollection("positionComboBox").Flatten = True 'Save the document to disk. document.Save("Form.pdf") 'Close the document. document.Close(True) Class Class Gets the items. The items. Gets the element. Represents interactive form of the PDF document. Please refer the UG docuemntation link for more details of working with forms. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); // Creates a form PdfForm form = document.Form; PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; //Add the items to the list box listBox.Items.Add(new PdfListFieldItem("English", "English")); listBox.Items.Add(new PdfListFieldItem("French", "French")); listBox.Items.Add(new PdfListFieldItem("German", "German")); //Select the item listBox.SelectedIndex = 2; //Set the multi-select option listBox.MultiSelect = true; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() ' Creates a form Dim form As PdfForm = document.Form Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline 'Add the items to the list box listBox.Items.Add(New PdfListFieldItem("English", "English")) listBox.Items.Add(New PdfListFieldItem("French", "French")) listBox.Items.Add(New PdfListFieldItem("German", "German")) 'Select the item listBox.SelectedIndex = 2 'Set the multi-select option listBox.MultiSelect = True document.Save("Form.pdf") document.Close(True) Interface Class Class Internal variable to store form's collection of fields. Internal variable to store resources. Internal value indicating whether the form is read only. Internal variable to store signature flags. Internal variable to store dictionary. Internal variable to store value whether to generate default appearancesof the fields. Indicates is form flatten or not. Internal variable to store value whether to change the name of the field. Holds the fields names of the form. Internal values to hold form fields values. Internal variable to ensure the form is XFA or not Indicates if AutoFormat has to be removed. Holds the reference of the loaded page and the cloned page Internal field to check whether any field is modified. field to check whether use DefaultEncoding field to check whether use DefaultAppearance. Indicate to m_enableXfaFormfill to fill support PdfLoadedXfaFormField with help of AcroFormAPI Initializes a new instance of the class. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); // Creates a form PdfForm form = new PdfForm(); form = document.Form; PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; //Add the items to the list box listBox.Items.Add(new PdfListFieldItem("English", "English")); listBox.Items.Add(new PdfListFieldItem("French", "French")); listBox.Items.Add(new PdfListFieldItem("German", "German")); //Select the item listBox.SelectedIndex = 2; //Set the multi-select option listBox.MultiSelect = true; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() ' Creates a form Dim form As PdfForm = New PdfForm() form = document.Form Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline 'Add the items to the list box listBox.Items.Add(New PdfListFieldItem("English", "English")) listBox.Items.Add(New PdfListFieldItem("French", "French")) listBox.Items.Add(New PdfListFieldItem("German", "German")) 'Select the item listBox.SelectedIndex = 2 'Set the multi-select option listBox.MultiSelect = True document.Save("Form.pdf") document.Close(True) Interface Class Class Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Clears PdfForm. Checks for the flatten fields. Add Form field font resources to page font resources Deletes from pages. The field. Deletes the annotation from the page dictionary. The field. Gets the new name of the field. The name. The field name. Specifies whether to set the default appearance for the form or not. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); // Creates a form PdfForm form = document.Form; PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; //Add the items to the list box listBox.Items.Add(new PdfListFieldItem("English", "English")); listBox.Items.Add(new PdfListFieldItem("French", "French")); listBox.Items.Add(new PdfListFieldItem("German", "German")); //Select the item listBox.SelectedIndex = 2; //Set the multi-select option listBox.MultiSelect = true; //Enable the default Appearance form.SetDefaultAppearance(true); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() ' Creates a form Dim form As PdfForm = document.Form Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline 'Add the items to the list box listBox.Items.Add(New PdfListFieldItem("English", "English")) listBox.Items.Add(New PdfListFieldItem("French", "French")) listBox.Items.Add(New PdfListFieldItem("German", "German")) 'Select the item listBox.SelectedIndex = 2 'Set the multi-select option listBox.MultiSelect = True 'Enable the default Appearance form.SetDefaultAppearance(True) document.Save("Form.pdf") document.Close(True) Interface Class Class XFA document Gets or sets the complex script layout for form fields. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Create a new text box field. PdfTextBoxField textBox = new PdfTextBoxField(page, "textBox"); //Set bounds textBox.Bounds = new RectangleF(0, 0, 300, 20); //Set font. textBox.Font = pdfFont; //Set text. textBox.Text = "สวัสดีชาวโลก"; //Add field to form. document.Form.Fields.Add(textBox); //Enable complex script document.Form.ComplexScript = true; document.Form.SetDefaultAppearance(false) //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Create a new text box field. Dim textBox As New PdfTextBoxField(page, "textBox") 'Set bounds textBox.Bounds = New RectangleF(0, 0, 300, 20) 'Set font. textBox.Font = pdfFont 'Set text. textBox.Text = "สวัสดีชาวโลก" 'Add field to form. document.Form.Fields.Add(textBox) 'Enable complex script document.Form.ComplexScript = True document.Form.SetDefaultAppearance(False) 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or sets whether the form is default encoding or not. True if the form is default encoding , otherwise false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } Set default encoding to form. form.IsDefaultEncoding = true; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Flatten the form collection For i As Integer = 0 To fieldCollection.Count - 1 fieldCollection(i).Flatten = True Next i Set default encoding to form. form.IsDefaultEncoding = True document.Save("Form.pdf") document.Close(True) Class Class Class Gets the field names. The field names. Gets or sets a value indicating whether the form is XFA. Gets the fields collection.[Read-Only] The Form fields. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields 'Flatten the form collection For i As Integer = 0 To fieldCollection.Count - 1 fieldCollection(i).Flatten = True Next i document.Save("Form.pdf") document.Close(True) Class Class Class PDF provides support to flatten a form field by removing the existing form field and replacing it with graphical objects that would resemble the form field and cannot be edited. Gets or sets a value indicating whether this is flatten. True if the is flatten , otherwise false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields ' Flatten the form collection For i As Integer = 0 To fieldCollection.Count - 1 fieldCollection(i).Flatten = True Next i document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether the form is read only. true if the form is read only; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); PdfForm form = document.Form; // Sets the form as read only form.ReadOnly = true; //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() ' Creates a form Dim form As PdfForm = document.Form ' Sets the form as read only form.ReadOnly = True 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields ' Flatten the form collection For i As Integer = 0 To fieldCollection.Count - 1 fieldCollection(i).Flatten = True Next i document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether [field auto naming]. true if the form is field auto naming; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); // Creates a form PdfForm form = document.Form; // Sets the form fields as auto naming. form.FieldAutoNaming = true; //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() ' Creates a form Dim form As PdfForm = document.Form ' Sets the form fields as auto naming. form.FieldAutoNaming = True 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a combo box Dim positionComboBox As PdfComboBoxField = New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields ' Flatten the form collection For i As Integer = 0 To fieldCollection.Count - 1 fieldCollection(i).Flatten = True Next i document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether the viewer must generate appearances for fields. true if viewer must generate appearance; otherwise, false. Gets or sets the signature flags. The signature flags. Gets or sets the resources. The resources. Gets or sets the dictionary. The dictionary. Gets or sets whether to disable auto formating. Specifies if any formfield is changed since loading that would affect the appearance. Gets the element. Represents a collection of form fields. This class is used to get the collection of form fields. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12F) 'Create a combo box Dim positionComboBox As New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFieldCollection = document.Form.Fields ' Flatten the form collection Dim i As Integer = 0 While i != fieldCollection.Count fieldCollection(i).Flatten = True i += 1 End While document.Save("Form.pdf") document.Close(True) Class Class Class Internal variable to store form. Initializes a new instance of the class. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a combo box PdfComboBoxField positionComboBox = new PdfComboBoxField(page, "positionComboBox"); positionComboBox.Editable = true; positionComboBox.Bounds = new RectangleF(100, 115, 200, 20); positionComboBox.Font = font; positionComboBox.Editable = true; //Add it to document document.Form.Fields.Add(positionComboBox); PdfFieldCollection fieldCollection = new PdfFormFieldCollection(); fieldCollection = document.Form.Fields; // Flatten the form collection for (int i = 0; i != fieldCollection.Count; i++) { fieldCollection[i].Flatten = true; } document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12F) 'Create a combo box Dim positionComboBox As New PdfComboBoxField(page, "positionComboBox") positionComboBox.Editable = True positionComboBox.Bounds = New RectangleF(100, 115, 200, 20) positionComboBox.Font = font positionComboBox.Editable = True 'Add it to document document.Form.Fields.Add(positionComboBox) Dim fieldCollection As PdfFormFieldCollection = New PdfFormFieldCollection() fieldCollection = document.Form.Fields ' Flatten the form collection Dim i As Integer = 0 While i != fieldCollection.Count fieldCollection(i).Flatten = True i += 1 End While document.Save("Form.pdf") document.Close(True) Class Class Adds a field to collection. The field. Inserts a filed into collection. The index. The field. Removes the field from collection. The field. Removes the field at the specified position. The index. Clears the collection. Check whether the field with the same name already exists. The name. true if there are no fields with the same name within the collection; otherwise false. Gets or sets the form. Represents list box field of the PDF form. This class is used to create the list box field in PDF forms. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; //Add the items to the list box listBox.Items.Add(new PdfListFieldItem("English", "English")); listBox.Items.Add(new PdfListFieldItem("French", "French")); listBox.Items.Add(new PdfListFieldItem("German", "German")); //Select the item listBox.SelectedIndex = 2; //Set the multiselect option listBox.MultiSelect = true; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline 'Add the items to the list box listBox.Items.Add(New PdfListFieldItem("English", "English")) listBox.Items.Add(New PdfListFieldItem("French", "French")) listBox.Items.Add(New PdfListFieldItem("German", "German")) 'Select the item listBox.SelectedIndex = 2 'Set the multiselect option listBox.MultiSelect = True document.Save("Form.pdf") document.Close(True) Class Class Class Class Class Internal variable to store value whether the fiels is multiselectable. Initializes a new instance of the class with the specific page and name. Page the field to be placed on. The name of the field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; //Add the items to the list box listBox.Items.Add(new PdfListFieldItem("English", "English")); listBox.Items.Add(new PdfListFieldItem("French", "French")); listBox.Items.Add(new PdfListFieldItem("German", "German")); //Select the item listBox.SelectedIndex = 2; //Set the multiselect option listBox.MultiSelect = true; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline 'Add the items to the list box listBox.Items.Add(New PdfListFieldItem("English", "English")) listBox.Items.Add(New PdfListFieldItem("French", "French")) listBox.Items.Add(New PdfListFieldItem("German", "German")) 'Select the item listBox.SelectedIndex = 2 'Set the multiselect option listBox.MultiSelect = True document.Save("Form.pdf") document.Close(True) Class Class Class Class Draws this instance if it is flatten. Initializes an instance. Draws the appearance. The template. Gets or sets the complex script language support. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Create a new list box field. PdfListBoxField listBoxField = new PdfListBoxField(page, "list1"); //Set bounds listBoxField.Bounds = new RectangleF(0, 0, 300, 20); //Set font. listBoxField.Font = pdfFont; //Add items. listBoxField.Items.Add(new PdfListFieldItem("สวัสดีชาวโลก", "One")); listBoxField.Items.Add(new PdfListFieldItem("สวัสดีชาวโลก", "Two")); //Set selected index. listBoxField.SelectedIndex = new int[] {0}; //Enable complex script. listBoxField.ComplexScript = true; //Add field to form. document.Form.Fields.Add(listBoxField); document.Form.SetDefaultAppearance(false) //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Create a new list box field. Dim listBoxField As New PdfListBoxField(page, "list1") 'Set bounds listBoxField.Bounds = New RectangleF(0, 0, 300, 20) 'Set font. listBoxField.Font = pdfFont 'Add items. listBoxField.Items.Add(New PdfListFieldItem("สวัสดีชาวโลก", "One")) listBoxField.Items.Add(New PdfListFieldItem("สวัสดีชาวโลก", "Two")) 'Set selected index. listBoxField.SelectedIndex = New Integer() {0} 'Enable complex script. listBoxField.ComplexScript = True 'Add field to form. document.Form.Fields.Add(listBoxField) document.Form.SetDefaultAppearance(False) 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or sets a value indicating whether the field is multiselectable. true if multiselectable; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; //Add the items to the list box listBox.Items.Add(new PdfListFieldItem("English", "English")); listBox.Items.Add(new PdfListFieldItem("French", "French")); listBox.Items.Add(new PdfListFieldItem("German", "German")); //Select the item listBox.SelectedIndex = 2; //Set the multiselect option listBox.MultiSelect = true; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline 'Add the items to the list box listBox.Items.Add(New PdfListFieldItem("English", "English")) listBox.Items.Add(New PdfListFieldItem("French", "French")) listBox.Items.Add(New PdfListFieldItem("German", "German")) 'Select the item listBox.SelectedIndex = 2 'Set the multiselect option listBox.MultiSelect = True document.Save("Form.pdf") document.Close(True) Class Class Class Class Text position it the primitive array. Value position in the primitive array. Internal variable to store caption of the list item. Internal variable to store value of the list item. Internal variable to store array primitive. Initializes a new instance of the class. Initializes the specified text. The text. The value. Gets the element. The primitive. Represents list field item collection. This class is used to get the collection of list field items in PDF forms. Please refer the UG docuemntation link for more details //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); listBox.SelectedIndex = 0; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) listBox.SelectedIndex = 0 document.Save("Form.pdf") document.Close(True) Class Interface Class Class Class Internal variable to store array of Initializes a new instance of the class. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = new PdfListFieldItemCollection(); itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); listBox.SelectedIndex = 0; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = New PdfListFieldItemCollection() itemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) listBox.SelectedIndex = 0 document.Save("Form.pdf") document.Close(True) Class Interface Class Class Class Inserts the list item field at the specified index. The index where to insert the new item. The object to be added to collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); PdfListFieldItem item = new PdfListFieldItem("Arabic", "Arabic"); // Inserting an item at second position itemCollection.Insert(1, item); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) Dim item As PdfListFieldItem = New PdfListFieldItem("Arabic", "Arabic") ' Inserting an item at second position itemCollection.Insert(1, item) document.Save("Form.pdf") document.Close(True) Class Class Class Removes the specified . The object which to be removed in the collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box PdfListFieldItem item = new PdfListFieldItem("English", "English"); itemCollection.Add(item); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); // Remove an item from collection itemCollection.Remove(item); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box Dim item As PdfListFieldItem = New PdfListFieldItem("English", "English") itemCollection.Add(item) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) ' Remove an item from collection itemCollection.Remove(item) document.Save("Form.pdf") document.Close(True) Class Class Class Removes the item at the specified position. The index where to remove the item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box PdfListFieldItem item = new PdfListFieldItem("English", "English"); itemCollection.Add(item); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); // Remove an item from collection itemCollection.RemoveAt(1); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box Dim item As PdfListFieldItem = New PdfListFieldItem("English", "English") itemCollection.Add(item) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) ' Remove an item from collection itemCollection.RemoveAt(1) document.Save("Form.pdf") document.Close(True) Class Class Class Determines whether the item is present in the collection. Check whether object is exists in the collection or not. true if the item is contained within the collection; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box PdfListFieldItem item = new PdfListFieldItem("English", "English"); itemCollection.Add(item); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); if (itemCollection.Contains(item)) MessageBox.Show("Already, item has added!"); else itemCollection.Add(item); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box Dim item As PdfListFieldItem = New PdfListFieldItem("English", "English") itemCollection.Add(item) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) If itemCollection.Contains(item) Then MessageBox.Show("Already, item has added!") Else itemCollection.Add(item) End If document.Save("Form.pdf") document.Close(True) Class Class Class Gets the index of the specified item. A object whose index is requested. The index of the given item, -1 if the item does not exist. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box PdfListFieldItem item = new PdfListFieldItem("English", "English"); itemCollection.Add(item); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); // Gets the index of an item int index = itemCollection.IndexOf(item); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box Dim item As PdfListFieldItem = New PdfListFieldItem("English", "English") itemCollection.Add(item) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) ' Gets the index of an item Dim index As Integer = itemCollection.IndexOf(item) document.Save("Form.pdf") document.Close(True) Class Class Class Clears the collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box PdfListFieldItem item = new PdfListFieldItem("English", "English"); itemCollection.Add(item); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); // Clear the collection itemCollection.Clear(); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box Dim item As PdfListFieldItem = New PdfListFieldItem("English", "English") itemCollection.Add(item) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) ' Clear the collection itemCollection.Clear() document.Save("Form.pdf") document.Close(True) Class Class Class Adds the item. The item. Index of the added item. Inserts the item. The index. The item. Removes the element at the specified position. The index. Removes the item. The item. Gets the at the specified index.[Read-Only] The object. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create list box PdfListBoxField listBox = new PdfListBoxField(page, "list1"); //Add the field to listbox. document.Form.Fields.Add(listBox); //Set the properties. listBox.Bounds = new RectangleF(100, 350, 100, 50); listBox.HighlightMode = PdfHighlightMode.Outline; // Creates list items PdfListFieldItemCollection itemCollection = listBox.Items; //Add the items to the list box itemCollection.Add(new PdfListFieldItem("English", "English")); itemCollection.Add(new PdfListFieldItem("French", "French")); itemCollection.Add(new PdfListFieldItem("German", "German")); // Reading the second item in the collection and assigning new values PdfListFieldItem item = itemCollection[1]; item.Text = "Arabic"; item.Value = "Arabic"; listBox.SelectedIndex = 0; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create list box Dim listBox As PdfListBoxField = New PdfListBoxField(page, "list1") 'Add the field to listbox. document.Form.Fields.Add(listBox) 'Set the properties. listBox.Bounds = New RectangleF(100, 350, 100, 50) listBox.HighlightMode = PdfHighlightMode.Outline ' Creates list items Dim itemCollection As PdfListFieldItemCollection = listBox.Items 'Add the items to the list box itemCollection.Add(New PdfListFieldItem("English", "English")) itemCollection.Add(New PdfListFieldItem("French", "French")) itemCollection.Add(New PdfListFieldItem("German", "German")) ' Reading the second item in the collection and assigning new values Dim item As PdfListFieldItem = itemCollection(1) item.Text = "Arabic" item.Value = "Arabic" listBox.SelectedIndex = 0 document.Save("Form.pdf") document.Close(True) Class Class Class Gets the element. Represents collection of radio buttons items. This class is used to . Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); g.DrawString("10-49", font, brush, new RectangleF(150, 175, 180, 20)); PdfRadioButtonListItem radioItem3 = new PdfRadioButtonListItem("50-99"); radioItem3.Bounds = new RectangleF(100, 200, 20, 20); g.DrawString("50-99", font, brush, new RectangleF(150, 205, 180, 20)); PdfRadioButtonListItem radioItem4 = new PdfRadioButtonListItem("100-499"); radioItem4.Bounds = new RectangleF(100, 230, 20, 20); g.DrawString("100-499", font, brush, new RectangleF(150, 235, 180, 20)); PdfRadioButtonListItem radioItem5 = new PdfRadioButtonListItem("500-more"); radioItem5.Bounds = new RectangleF(100, 260, 20, 20); g.DrawString("500-more", font, brush, new RectangleF(150, 265, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); employeesRadioList.Items.Add(radioItem2); employeesRadioList.Items.Add(radioItem3); employeesRadioList.Items.Add(radioItem4); employeesRadioList.Items.Add(radioItem5); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) g.DrawString("10-49", font, brush, New RectangleF(150, 175, 180, 20)) Dim radioItem3 As PdfRadioButtonListItem = New PdfRadioButtonListItem("50-99") radioItem3.Bounds = New RectangleF(100, 200, 20, 20) g.DrawString("50-99", font, brush, New RectangleF(150, 205, 180, 20)) Dim radioItem4 As PdfRadioButtonListItem = New PdfRadioButtonListItem("100-499") radioItem4.Bounds = New RectangleF(100, 230, 20, 20) g.DrawString("100-499", font, brush, New RectangleF(150, 235, 180, 20)) Dim radioItem5 As PdfRadioButtonListItem = New PdfRadioButtonListItem("500-more") radioItem5.Bounds = New RectangleF(100, 260, 20, 20) g.DrawString("500-more", font, brush, New RectangleF(150, 265, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) employeesRadioList.Items.Add(radioItem2) employeesRadioList.Items.Add(radioItem3) employeesRadioList.Items.Add(radioItem4) employeesRadioList.Items.Add(radioItem5) document.Save("Form.pdf") document.Close(True) Class Class Class Class Internal variable to store array of item's primitives. Internal variable to store field. Initializes a new instance of the class with the specific . The field. Adds the specified item. Please refer the UG docuemntation link for more details. The object to be added to collection. The index of the added field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) document.Save("Form.pdf") document.Close(True) Class Class Class Inserts an item at the specified index. The index where to insert the new item.. A object to be added to collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Insert(0, radioItem2); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Insert(0, radioItem2) document.Save("Form.pdf") document.Close(True) Class Class Class Removes the specified item from the collection. The object which is to be removed from the collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Remove the item employeesRadioList.Items.Remove(radioItem1); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Remove the item employeesRadioList.Items.Remove(radioItem1) document.Save("Form.pdf") document.Close(True) Class Class Class Removes the item at the specified index. The index where to remove the item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Remove the item employeesRadioList.Items.RemoveAt(0); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Remove the item employeesRadioList.Items.RemoveAt(0) document.Save("Form.pdf") document.Close(True) Class Class Class Gets the index of the item within the collection. A object whose index is requested. Index of the item with the collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Find the index int index = employeesRadioList.Items.IndexOf(radioItem1); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'Add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Find the index Dim index As Integer = employeesRadioList.Items.IndexOf(radioItem1) document.Save("Form.pdf") document.Close(True) Class Class Class Determines whether the collection contains the specified item. Check whether object is exists in the collection or not. true if collection contains specified item; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Check whether the specified item is in Collection if (employeesRadioList.Items.Contains(radioItem1)) MessageBox.Show("Item already added in the collection"); else //add the items to radio button group employeesRadioList.Items.Add(radioItem1); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Check whether the specified item is in Collection If employeesRadioList.Items.Contains(radioItem1) Then MessageBox.Show("Item already added in the collection") Else 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) End If document.Save("Form.pdf") document.Close(True) Class Class Class Clears the item collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Clears the item employeesRadioList.Items.Clear(); document.Save("Form.pdf"); document.Close(true); 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Clears the item employeesRadioList.Items.Clear() document.Save("Form.pdf") document.Close(True) Class Class Class Adds the item. The item. Index of the inserted item. Inserts the item. The index. The item. Removes the specified item. The item. Clears the collection. Gets the at the specified index. Returns item at the specified position. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Gets the first item from the collection PdfRadioButtonListItem item = employeesRadioList.Items[0]; document.Save("Form.pdf"); document.Close(true); 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Gets the first item from the collection Dim item As PdfRadioButtonListItem = employeesRadioList.Items(0) document.Save("Form.pdf") document.Close(True) Class Class Class Gets the element. Represents radio button field in the PDF form. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); g.DrawString("10-49", font, brush, new RectangleF(150, 175, 180, 20)); PdfRadioButtonListItem radioItem3 = new PdfRadioButtonListItem("50-99"); radioItem3.Bounds = new RectangleF(100, 200, 20, 20); g.DrawString("50-99", font, brush, new RectangleF(150, 205, 180, 20)); PdfRadioButtonListItem radioItem4 = new PdfRadioButtonListItem("100-499"); radioItem4.Bounds = new RectangleF(100, 230, 20, 20); g.DrawString("100-499", font, brush, new RectangleF(150, 235, 180, 20)); PdfRadioButtonListItem radioItem5 = new PdfRadioButtonListItem("500-more"); radioItem5.Bounds = new RectangleF(100, 260, 20, 20); g.DrawString("500-more", font, brush, new RectangleF(150, 265, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); employeesRadioList.Items.Add(radioItem2); employeesRadioList.Items.Add(radioItem3); employeesRadioList.Items.Add(radioItem4); employeesRadioList.Items.Add(radioItem5); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) g.DrawString("10-49", font, brush, New RectangleF(150, 175, 180, 20)) Dim radioItem3 As PdfRadioButtonListItem = New PdfRadioButtonListItem("50-99") radioItem3.Bounds = New RectangleF(100, 200, 20, 20) g.DrawString("50-99", font, brush, New RectangleF(150, 205, 180, 20)) Dim radioItem4 As PdfRadioButtonListItem = New PdfRadioButtonListItem("100-499") radioItem4.Bounds = New RectangleF(100, 230, 20, 20) g.DrawString("100-499", font, brush, New RectangleF(150, 235, 180, 20)) Dim radioItem5 As PdfRadioButtonListItem = New PdfRadioButtonListItem("500-more") radioItem5.Bounds = New RectangleF(100, 260, 20, 20) g.DrawString("500-more", font, brush, New RectangleF(150, 265, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) employeesRadioList.Items.Add(radioItem2) employeesRadioList.Items.Add(radioItem3) employeesRadioList.Items.Add(radioItem4) employeesRadioList.Items.Add(radioItem5) document.Save("Form.pdf") document.Close(True) Class Class Class Class Internal variable to store collection of items. Internal variable to store selected item index. Initializes a new instance of the class with the specific page and name. Page which the field to be placed on. The name of the field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); g.DrawString("10-49", font, brush, new RectangleF(150, 175, 180, 20)); PdfRadioButtonListItem radioItem3 = new PdfRadioButtonListItem("50-99"); radioItem3.Bounds = new RectangleF(100, 200, 20, 20); g.DrawString("50-99", font, brush, new RectangleF(150, 205, 180, 20)); PdfRadioButtonListItem radioItem4 = new PdfRadioButtonListItem("100-499"); radioItem4.Bounds = new RectangleF(100, 230, 20, 20); g.DrawString("100-499", font, brush, new RectangleF(150, 235, 180, 20)); PdfRadioButtonListItem radioItem5 = new PdfRadioButtonListItem("500-more"); radioItem5.Bounds = new RectangleF(100, 260, 20, 20); g.DrawString("500-more", font, brush, new RectangleF(150, 265, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); employeesRadioList.Items.Add(radioItem2); employeesRadioList.Items.Add(radioItem3); employeesRadioList.Items.Add(radioItem4); employeesRadioList.Items.Add(radioItem5); document.Save("Form.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) g.DrawString("10-49", font, brush, New RectangleF(150, 175, 180, 20)) Dim radioItem3 As PdfRadioButtonListItem = New PdfRadioButtonListItem("50-99") radioItem3.Bounds = New RectangleF(100, 200, 20, 20) g.DrawString("50-99", font, brush, New RectangleF(150, 205, 180, 20)) Dim radioItem4 As PdfRadioButtonListItem = New PdfRadioButtonListItem("100-499") radioItem4.Bounds = New RectangleF(100, 230, 20, 20) g.DrawString("100-499", font, brush, New RectangleF(150, 235, 180, 20)) Dim radioItem5 As PdfRadioButtonListItem = New PdfRadioButtonListItem("500-more") radioItem5.Bounds = New RectangleF(100, 260, 20, 20) g.DrawString("500-more", font, brush, New RectangleF(150, 265, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) employeesRadioList.Items.Add(radioItem2) employeesRadioList.Items.Add(radioItem3) employeesRadioList.Items.Add(radioItem4) employeesRadioList.Items.Add(radioItem5) document.Save("Form.pdf") Class Class Class Draws this instance if it is flatten. Gets or sets the first selected item in the list. The index of the selected item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); // Set the selected item index index employeesRadioList.SelectedIndex = 0; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) ' Set the selected item index index employeesRadioList.SelectedIndex = 0 document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets the value of the first selected item in the list. The selected value of the list field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Set the selected item value employeesRadioList.SelectedValue = "1-9"; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Set the selected item value employeesRadioList.SelectedValue = "1-9" document.Save("Form.pdf") document.Close(True) Class Class Class Gets the first selected item in the list.[Read-Only] The selected item of the field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Set the selected item employeesRadioList.SelectedItem = radioItem1; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Set the selected item employeesRadioList.SelectedItem = radioItem1 document.Save("Form.pdf") document.Close(True) Class Class Class Gets the items of the radio button field.[Read-Only] The radio button field item collection. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); // Insert the item as first item employeesRadioList.Items.Add(radioItem2); // Set the selected item value employeesRadioList.SelectedValue = "1-9"; // Getting item collection PdfRadioButtonItemCollection itemCollection = employeesRadioList.Items; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) ' Insert the item as first item employeesRadioList.Items.Add(radioItem2) ' Set the selected item value employeesRadioList.SelectedValue = "1-9" ' Getting item collection Dim itemCollection As PdfRadioButtonItemCollection = employeesRadioList.Items document.Save("Form.pdf"); document.Close(True) Class Class Class Represents an item of a radio button list. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); PdfBrush brush = PdfBrushes.Black; PdfGraphics g = page.Graphics; //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); g.DrawString("1-9", font, brush, new RectangleF(150, 145, 180, 20)); PdfRadioButtonListItem radioItem2 = new PdfRadioButtonListItem("10-49"); radioItem2.Bounds = new RectangleF(100, 170, 20, 20); g.DrawString("10-49", font, brush, new RectangleF(150, 175, 180, 20)); PdfRadioButtonListItem radioItem3 = new PdfRadioButtonListItem("50-99"); radioItem3.Bounds = new RectangleF(100, 200, 20, 20); g.DrawString("50-99", font, brush, new RectangleF(150, 205, 180, 20)); PdfRadioButtonListItem radioItem4 = new PdfRadioButtonListItem("100-499"); radioItem4.Bounds = new RectangleF(100, 230, 20, 20); g.DrawString("100-499", font, brush, new RectangleF(150, 235, 180, 20)); PdfRadioButtonListItem radioItem5 = new PdfRadioButtonListItem("500-more"); radioItem5.Bounds = new RectangleF(100, 260, 20, 20); g.DrawString("500-more", font, brush, new RectangleF(150, 265, 180, 20)); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); employeesRadioList.Items.Add(radioItem2); employeesRadioList.Items.Add(radioItem3); employeesRadioList.Items.Add(radioItem4); employeesRadioList.Items.Add(radioItem5); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) Dim brush As PdfBrush = PdfBrushes.Black Dim g As PdfGraphics = page.Graphics 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) g.DrawString("1-9", font, brush, New RectangleF(150, 145, 180, 20)) Dim radioItem2 As PdfRadioButtonListItem = New PdfRadioButtonListItem("10-49") radioItem2.Bounds = New RectangleF(100, 170, 20, 20) g.DrawString("10-49", font, brush, New RectangleF(150, 175, 180, 20)) Dim radioItem3 As PdfRadioButtonListItem = New PdfRadioButtonListItem("50-99") radioItem3.Bounds = New RectangleF(100, 200, 20, 20) g.DrawString("50-99", font, brush, New RectangleF(150, 205, 180, 20)) Dim radioItem4 As PdfRadioButtonListItem = New PdfRadioButtonListItem("100-499") radioItem4.Bounds = New RectangleF(100, 230, 20, 20) g.DrawString("100-499", font, brush, New RectangleF(150, 235, 180, 20)) Dim radioItem5 As PdfRadioButtonListItem = New PdfRadioButtonListItem("500-more") radioItem5.Bounds = New RectangleF(100, 260, 20, 20) g.DrawString("500-more", font, brush, New RectangleF(150, 265, 180, 20)) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) employeesRadioList.Items.Add(radioItem2) employeesRadioList.Items.Add(radioItem3) employeesRadioList.Items.Add(radioItem4) employeesRadioList.Items.Add(radioItem5) document.Save("Form.pdf") document.Close(True) Class Class Class Class Internal variable to store field which this item belongs to. Internal variable to store item's value. Initializes a new instance of the class. Initializes a new instance of the class with the specific value. The value. Initializes instance. Sets the field. The field. Handles the Save event of the Widget control. The source of the event. The instance containing the event data. Saves an instance. Draws the appearance. Gets the value. m_value Draws this instance if it is flatten. Gets or sets the bounds. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem("1-9"); radioItem1.Bounds = new RectangleF(100, 140, 20, 20); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem("1-9") radioItem1.Bounds = New RectangleF(100, 140, 20, 20) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) document.Save("Form.pdf") document.Close(True) Class Class Class Class Gets or sets the value. The value. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a Radiobutton PdfRadioButtonListField employeesRadioList = new PdfRadioButtonListField(page, "employeesRadioList"); //Add to document document.Form.Fields.Add(employeesRadioList); //Create radiobutton items PdfRadioButtonListItem radioItem1 = new PdfRadioButtonListItem(); radioItem1.Value = "1-9"; radioItem1.Bounds = new RectangleF(100, 140, 20, 20); //add the items to radio button group employeesRadioList.Items.Add(radioItem1); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a Radiobutton Dim employeesRadioList As PdfRadioButtonListField = New PdfRadioButtonListField(page, "employeesRadioList") 'Add to document document.Form.Fields.Add(employeesRadioList) 'Create radiobutton items Dim radioItem1 As PdfRadioButtonListItem = New PdfRadioButtonListItem() radioItem1.Value = "1-9" radioItem1.Bounds = New RectangleF(100, 140, 20, 20) 'add the items to radio button group employeesRadioList.Items.Add(radioItem1) document.Save("Form.pdf") document.Close(True) Class Class Class Gets the element. Represents form field with appearance custom support. Class Represents form's field with style parameters. Class Class Class Class Internal variable to store color shift value. Internal variable to store rotation value. Internal variable to store widget of the field. Internal variable to store actions of the field. Internal variable to store appearance template. Internal variable to store back color. Internal variable to store border pen. Internal variable to store shadow brush. Internal variable to store visibility of the field. Initializes a new instance of the class with the specific page and name. The page where the field should be placed. The name. Initializes a new instance of the class. Draws this instance if it is flatten. Removes the annotation from page. The page. The widget. Adds the annotation to page. The page. The widget. Initializes an instance. Creates the border pen. Creates the back brush. Gets or sets the bounds of the field. The bounds. Gets and sets the rotation angle in the form fields. //create a new PDF document PdfDocument document = new PdfDocument(); //Add a new page to the PDF document. PdfPage page = document.Pages.Add(); //set the page rotation angle. document.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle0; //Create a textbox field and add the properties. PdfTextBoxField textBoxField = new PdfTextBoxField(page, "FirstName"); textBoxField.Bounds = new RectangleF(0, 40, 100, 20); textBoxField.ToolTip = "First Name"; //Gets and sets the rotation angle in the form fields. textBoxField.RotationAngle = 90; //add the field to the collection document.Form.Fields.Add(textBoxField); //enable or disable set appearance document.Form.SetDefaultAppearance(true); //Save the document. document.Save("Output.pdf"); //close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Add a new page to the PDF document. Dim page As PdfPage = document.Pages.Add() 'set the page rotation angle. document.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle0; 'Create a textbox field and add the properties. Dim textBoxField As PdfTextBoxField = New PdfTextBoxField(page, "FirstName") textBoxField.ToolTip = "First Name"; 'Gets and sets the rotation angle in the form fields. textBoxField.RotationAngle = 90; 'add the field to the collection document.Form.Fields.Add(textBoxField) 'enable or disable set appearance document.Form.SetDefaultAppearance(True) 'save the document document.Save("Output.pdf") 'close the document document.Close(True) /// The rotation angle value shall be a multiple of 90. Default value: 0. Gets or sets the location. The location. Gets or sets the size. The size. Gets or sets the color of the border. The color of the border. Gets or sets the color of the background. The color of the background. Gets or sets the width of the border. The width of the border. Gets or sets the highlighting mode. The highlighting mode. Gets the actions of the field.[Read-Only] The actions. Gets or sets the border style. The border style. Gets or sets a value indicating whether this is visible. true if visible; otherwise, false. Gets the right bottom beveled Shadow brush. The right bottom beveled Shadow brush. Gets the widget. The widget. Gets the appearance template. The appearance template. Gets the back brush. The back brush. Gets the border pen. The border pen. Initializes a new instance of the class. Initializes a new instance of the class. page The name. Saves an object. Draws this instance if it is flatten. Draws the appearance. The template. Gets the appearance of the signature field.[Read-Only] The appearance. Represents signature field in the PDF Form. Please refer the UG docuemntation link for more details about signature field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create signature field PdfSignatureField sign = new PdfSignatureField(page, "sign1"); sign.Bounds = new RectangleF(100, 420, 100, 50); document.Form.Fields.Add(sign); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create signature field Dim sign As PdfSignatureField = New PdfSignatureField(page, "sign1") sign.Bounds = New RectangleF(100, 420, 100, 50) document.Form.Fields.Add(sign) document.Save("Form.pdf") document.Close(True) Class Class Class Internal variable to store the signature. Ignore child cerificate in signature dictionary Initializes a new instance of the class with the specific page and name. Page which the field to be placed on. The name of the field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create signature field PdfSignatureField sign = new PdfSignatureField(page, "sign1"); sign.Bounds = new RectangleF(100, 420, 100, 50); document.Form.Fields.Add(sign); document.Save("Form.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create signature field Dim sign As PdfSignatureField = New PdfSignatureField(page, "sign1") sign.Bounds = New RectangleF(100, 420, 100, 50) document.Form.Fields.Add(sign) document.Save("Form.pdf") Class Class Initializes a new instance of the class. Initializes an instance. Saves the signature. Draws the field. Draws the appearance. The template. Gets the visual appearance of this field.[Read-Only] //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create signature field PdfSignatureField sign = new PdfSignatureField(page, "sign1"); sign.Bounds = new RectangleF(100, 420, 100, 50); // Gets the signature appearance PdfAppearance appearance = sign.Appearance; document.Form.Fields.Add(sign); document.Save("Form.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create signature field Dim sign As PdfSignatureField = New PdfSignatureField(page, "sign1") ' Gets the signature appearance Dim appearance As PdfAppearance = sign.Appearance sign.Bounds = New RectangleF(100, 420, 100, 50) document.Form.Fields.Add(sign) document.Save("Form.pdf") Class Class Gets or sets the digital signature for signing the field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create signature field PdfSignatureField sign = new PdfSignatureField(page, "sign1"); sign.Signature = new PdfSignature(page, new PdfCertificate("PDF.pfx", "Syncfusion"), "Signature"); sign.Bounds = new RectangleF(100, 420, 100, 50); // Gets the signature appearance PdfAppearance appearance = sign.Appearance; document.Form.Fields.Add(sign); document.Save("Form.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create signature field Dim sign As PdfSignatureField = New PdfSignatureField(page, "sign1") sign.Signature = New PdfSignature(page, New PdfCertificate("PDF.pfx", "Syncfusion"), "Signature") sign.Bounds = New RectangleF(100, 420, 100, 50) document.Form.Fields.Add(sign) document.Save("Form.pdf") Class Class Represents text box field in the PDF form. This class is used to create the text box field in PDF forms. Please refer the UG docuemntation link for more details. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Class The password chrackter. Internal variable to store value. Internal variable to store default value. Internal variable to store value whether to check spelling. Internal variable to store value whether the field has comb behavior. Internal variable to store value whether the field should be multiline. Internal variable to store value whether it is a password field. Internal variable to store value whether the field is scrollable. Internal variable to store field's maximum length. in characters. Internal variable to store value whether AutoResizeText is enable. Initializes a new instance of the class with the provided page and name. Page which the field to be placed on. The name of the text box field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") Class Class Class Initializes a new instance of the class. Draws this instance if it is flatten. Initializes an instance. Draws the appearance. The template. Sets the fitting font size The PaintParams. The text of the TextBoxField. Gets or sets the complex script language support. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Create a new text box field. PdfTextBoxField textBox = new PdfTextBoxField(page, "textBox"); //Set bounds textBox.Bounds = new RectangleF(0, 0, 300, 20); //Set font. textBox.Font = pdfFont; //Set text. textBox.Text = "สวัสดีชาวโลก"; //Enable complex script. textBox.ComplexScript = true; //Add field to form. document.Form.Fields.Add(textBox); document.Form.SetDefaultAppearance(false) //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Create a new text box field. Dim textBox As New PdfTextBoxField(page, "textBox") 'Set bounds textBox.Bounds = New RectangleF(0, 0, 300, 20) 'Set font. textBox.Font = pdfFont 'Set text. textBox.Text = "สวัสดีชาวโลก" 'Enable complex script. textBox.ComplexScript = True 'Add field to form. document.Form.Fields.Add(textBox) document.Form.SetDefaultAppearance(False) 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or sets the text in the text box. The text of the text box field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Text = "Cris"; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Text = "Cris" firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets the default value. The default value of the text box field. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.DefaultValue = "Cris"; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.DefaultValue = "Cris" firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether to check spelling. true if check spelling; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.SpellCheck = true; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.SpellCheck = True firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Meaningful only if the MaxLength property is set and the Multiline, Password properties are false. If set, the field is automatically divided into as many equally spaced positions, or combs, as the value of MaxLength, and the text is laid out into those combs. true if need to insert spaces; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.InsertSpaces = true; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.InsertSpaces = True firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether this is multiline. true if multiline; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Multiline = true; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Multiline = True firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether this is password field. true if password field; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Password = true; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Password = True firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether this is scrollable. true if scrollable; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.Scrollable = true; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.Scrollable = True firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets the maximum number of characters that can be entered in the text box. An integer value specifying the maximum number of characters that can be entered in the text box. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.MaxLength = 8; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.MaxLength = 8 firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Gets or sets a value indicating whether this is AutoResizeText. true if AutoResizeText field; otherwise, false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a text box PdfTextBoxField textBoxField = new PdfTextBoxField(page, "firstNameTextBox"); textBoxField.AutoResizeText = true; textBoxField.Flatten = false; //Set text. textBoxField.Text = "Syncfusion provides the best third-party UI components for WinForms, WPF, ASP.NET Web Forms, MVC, Core, UWP, WinUI (Preview), Xamarin, JavaScript"; textBoxField.Bounds = new RectangleF(0, 0, 300, 20); textBoxField.ToolTip = "Company Products"; //Add the textbox in document document.Form.Fields.Add(textBoxField); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create a text box Dim firstNameTextBox As textBoxField = New PdfTextBoxField(page, "firstNameTextBox") textBoxField.AutoResizeText = true textBoxField.Flatten = false //Set text. textBoxField.Text = "Syncfusion provides the best third-party UI components for WinForms, WPF, ASP.NET Web Forms, MVC, Core, UWP, WinUI (Preview), Xamarin, JavaScript" textBoxField.Bounds = New RectangleF(100, 20, 200, 20) textBoxField.ToolTip = "Company Products" 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Represents fields flags enum. Default field flag. If set, the user may not change the value of the field. Any associated widget annotations will not interact with the user; that is, they will not respond to mouse clicks or change their appearance in response to mouse motions. This flag is useful for fields whose values are computed or imported from a database. If set, the field must have a value at the time it is exported by a submit-form action. If set, the field must not be exported by a submit-form action If set, the field can contain multiple lines of text; if clear, the field�s text is restricted to a single line. If set, the field is intended for entering a secure password that should not be echoed visibly to the screen. Characters typed from the keyboard should instead be echoed in some unreadable form, such as asterisks or bullet characters. If set, the text entered in the field represents the pathname of a file whose contents are to be submitted as the value of the field. If set, text entered in the field is not spell-checked. If set, the field does not scroll (horizontally for single-line fields, vertically for multiple-line fields) to accommodate more text than fits within its annotation rectangle. Once the field is full, no further text is accepted. Meaningful only if the MaxLen entry is present in the text field dictionary and if the Multiline, Password, and FileSelect flags are clear. If set, the field is automatically divided into as many equally spaced positions, or combs, as the value of MaxLen, and the text is laid out into those combs. If set, the value of this field should be represented as a rich text string. If the field has a value, the RVentry of the field dictionary specifies the rich text string. If set, exactly one radio button must be selected at all times; clicking the currently selected button has no effect. If clear, clicking the selected button reselects it, leaving no button selected. If set, the field is a set of radio buttons; if clear, the field is a check box. This flag is meaningful only if the Pushbutton flag is clear. If set, the field is a pushbutton that does not retain a permanent value. If set, a group of radio buttons within a radio button field that use the same value for the on state will turn on and off in unison; that is if one is checked, they are all checked. If clear, the buttons are mutually exclusive. If set, the field is a combo box; if clear, the field is a list box. If set, the combo box includes an editable text box as well as a drop-down list; if clear, it includes only a drop-down list. This flag is meaningful only if the Combo flag is set. If set, the field�s option items should be sorted alphabetically. This flag is intended for use by form authoring tools, not by PDF viewer applications. If set, more than one of the field�s option items may be selected simultaneously; if clear, no more than one item at a time may be selected. If set, the new value is committed as soon as a selection is made with the pointing device. This option enables applications to perform an action once a selection is made, without requiring the user to exit the field. If clear, the new value is not committed until the user exits the field. Specifies the available styles for a field border. //Create a new PDf document PdfDocument document = new PdfDocument(); // Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create submit button PdfButtonField submitButton = new PdfButtonField(page, "submitButton"); submitButton.Bounds = new RectangleF(100, 500, 90, 20); submitButton.Font = font; submitButton.Text = "Submit"; // Set the border style for the button field submitButton.BorderStyle = PdfBorderStyle.Dashed; document.Form.Fields.Add(submitButton); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() ' Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create submit button Dim submitButton As PdfButtonField = New PdfButtonField(page, "submitButton") submitButton.Bounds = New RectangleF(100, 500, 90, 20) submitButton.Font = font submitButton.Text = "Submit" ' Set the border style for the button field submitButton.BorderStyle = PdfBorderStyle.Dashed document.Form.Fields.Add(submitButton) document.Save("Form.pdf") document.Close(True) Default value is Solid. Class Class Class A solid rectangle surrounding the annotation. A dashed rectangle surrounding the annotation. A simulated embossed rectangle that appears to be raised above the surface of the page. A simulated engraved rectangle that appears to be recessed below the surface of the page. A single line along the bottom of the annotation rectangle. A dotted rectangle surrounding the annotation. Specifies the highlight mode for a field. // Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create the signature field PdfSignatureField sign = new PdfSignatureField(page, "sign1"); sign.Bounds = new RectangleF(100, 420, 100, 50); // Set the high light mode for a signature field sign.HighlightMode = PdfHighlightMode.Push; document.Form.Fields.Add(sign); document.Save("Form.pdf"); document.Close(true); ' Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create the signature field Dim sign As PdfSignatureField = New PdfSignatureField(page, "sign1") sign.Bounds = New RectangleF(100, 420, 100, 50) ' Set the high light mode for a signature field sign.HighlightMode = PdfHighlightMode.Push document.Form.Fields.Add(sign) document.Save("Form.pdf") document.Close(True) Default value is Invert. No highlighting. Invert the contents of the field rectangle. Invert the field's border. Pushed highlighting. Specifies the style for a check box field. The default value is Check. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create a check box PdfCheckBoxField checkBox = new PdfCheckBoxField(page, "C#.NET"); checkBox.Bounds = new RectangleF(100, 290, 20, 20); // Add the check box field in form`s field collection document.Form.Fields.Add(checkBox); checkBox.HighlightMode = PdfHighlightMode.Push; checkBox.BorderStyle = PdfBorderStyle.Beveled; // Set the check style checkBox.Style = PdfCheckBoxStyle.Star; checkBox.Checked = true; document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create a check box Dim checkBox As PdfCheckBoxField = New PdfCheckBoxField(page, "C#.NET") checkBox.Bounds = New RectangleF(100, 290, 20, 20) ' Add the check box field in form`s field collection document.Form.Fields.Add(checkBox) checkBox.HighlightMode = PdfHighlightMode.Push checkBox.BorderStyle = PdfBorderStyle.Beveled ' Set the check style checkBox.Style = PdfCheckBoxStyle.Star checkBox.Checked = True document.Save("Form.pdf") document.Close(True) Class Class Class A check mark is used for the checked state. A circle is used for the checked state. A cross is used for the checked state. A diamond symbol is used for the checked state. A square is used for the checked state. A star is used for the checked state. Specifies Http request method. Data submitted using Http Get method. Data submitted using Http Post method. Specifies the enumeration of submit data formats. //Create a PDF document PdfDocument document = new PdfDocument(); //Add a new page PdfPage page = document.Pages.Add(); // Create a Button field. PdfButtonField submitButton = new PdfButtonField(page, "Submit data"); submitButton.Bounds = new RectangleF(100, 60, 50, 20); submitButton.ToolTip = "Submit"; document.Form.Fields.Add(submitButton); // Create a submit action. It submit the data of the form fields to the mentioned URL PdfSubmitAction submitAction = new PdfSubmitAction("http://www.example.com/Submit.aspx"); submitAction.DataFormat = SubmitDataFormat.Html; submitButton.Actions.GotFocus = submitAction; //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add a new page Dim page As PdfPage = document.Pages.Add() ' Create a Button field. Dim submitButton As New PdfButtonField(page, "Submit data") submitButton.Bounds = New RectangleF(100, 60, 50, 20) submitButton.ToolTip = "Submit" document.Form.Fields.Add(submitButton) ' Create a submit action. It submit the data of the form fields to the mentioned URL Dim submitAction As New PdfSubmitAction("http://www.example.com/Submit.aspx") submitAction.DataFormat = SubmitDataFormat.Html submitButton.Actions.GotFocus = submitAction 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Class Class Data should be transmitted as Html. Data should be transmitted as Pdf. Data should be transmitted as Forms Data Format. Data should be transmitted as XML Forms Data Format . Represents states of the check field. Indicated unchecked/unpressed state. Indicated checked unpressed state. Indicated pressed unchecked state. Indicated pressed checked state. Specifies the form field visibility types //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12f); //Create a text box PdfTextBoxField firstNameTextBox = new PdfTextBoxField(page, "firstNameTextBox"); firstNameTextBox.MaxLength = 8; firstNameTextBox.Bounds = new RectangleF(100, 20, 200, 20); firstNameTextBox.Font = font; //Set the visibility. firstNameTextBox.Visibility = PdfFormFieldVisibility.Visible; page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55); //Add the textbox in document document.Form.Fields.Add(firstNameTextBox); document.Save("Form.pdf"); document.Close(true); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12f) 'Create a text box Dim firstNameTextBox As PdfTextBoxField = New PdfTextBoxField(page, "firstNameTextBox") firstNameTextBox.MaxLength = 8 firstNameTextBox.Bounds = New RectangleF(100, 20, 200, 20) firstNameTextBox.Font = font 'Set the visibility. firstNameTextBox.Visibility = PdfFormFieldVisibility.Visible page.Graphics.DrawString("First Name", font, PdfBrushes.Black, 10, 55) 'Add the textbox in document document.Form.Fields.Add(firstNameTextBox) document.Save("Form.pdf") document.Close(True) Class Class Class Indicate visibility of the form field. Hidden the visibility of the form field. Indicate visibility of the form field and not printable. Indicate hidden the visibility of the form field and not printable. Class which represents embedded file into Pdf document. Internal variable to store file name. Internal variable to store file path. Internal variable to store mime type. Internal variable to store embedded data. Internal variable to store specification of the embedded file. Internal variable to store stream. Name of the file. Name of the file. The data. Name of the file. The stream. Initializes an instance. Saves an object. Handles the BeginSave event of the Stream control. The source of the event. The instance containing the event data. Get attachment's name through names array. Attachment's file name. The name of the file. Gets or sets the path of the file. The path of the file. Gets or sets the data. The data. Gets or sets the type of the MIME. The type of the MIME. Gets the params. The params. Gets the element. Defines additional parameters for the embedded file. Internal variable to store creation date. Internal variable to store modification date. Internal variable to store size of the embedded file. Internal variable to store dictionary. Initializes a new instance of the class. Gets or sets creation date. Creation date. Gets or sets modification date. Modification date. Gets or sets the size of the embedded file. The size. Gets the element. Implements PDF Exponential Interpolation Function. Implements the base class for all functions. Internal variable to store dictionary. Initializes a new instance of the class. The internal dictionary. Gets or sets the domain of the function. Gets or sets the range. Gets the dictionary. The dictionary. Gets the element. Local variable to store the function result when x = 0. Local variable to store the function result when x = 1. Local variable to store the interpolation exponent. Initializes a new instance of the class. init Initializes a new instance of the class. TO calulate the interpolation exponent. singleArray1 Gets or sets the function result when x = 0. Gets or sets the function result when x = 1. Gets or sets the Exponent. Implements PDF PostScript Calculator Function Initializes a new instance of the class. Implements PDF Sampled Function. Initializes a new instance of the class. The domain. The range. The sizes. The samples. Initializes a new instance of the class. The domain, which represents the range of the input values. The range, which represents the range of the output values. The sizes. The number of samples in each dimension. Initializes a new instance of the class. The domain of sampled function. The range of sampled function. The sizes. The samples of sampled function, which should be in the range. The bit-per-sample value. Initializes a new instance of the class. Checks the input parameters. The domain. The range. The sizes. The samples. If one of the parameters is null. If dimentions of the arrays don't agree. Sets the domain and range. The domain. The range. Sets the size and values. The sizes of the sample values. The sample values. Sets the size and values. The sizes of the sample values. The sample values. Implements PDF Stitching Function. Initializes a new instance of the class. Collection of the cached objects. Stores the similar objects. Initializes a new instance of the class. Searches for the similar cached object. If is not found - adds the object to the cache. Object to search for. Cached similar object if found, null otherwise. Checks whether a cache contains a group of such objects. The object. true if contains, False otherwise. Returns number of cached object in a group. The object. Returns number of cached object in a group if found, 0 otherwise. Removes the object from a cache. The object. Cleares cache. Creates a new group. A created group. Searches for a corresponding group. A representative of a group. A group if found, Null otherwise. Remove a group from the storage. A group of the objects. Gets the at the specified index. Gets the font offset table. The font offset table. Gets the font data. The font data. Represents default appearance string. Internal variable to store fore color. Internal variable to store font name. Internal variable to store font size. Initializes a new instance of the class. Returns a that represents the current . A that represents the current . Gets or sets the name of the font. The name of the font. Gets or sets the size of the font. The size of the font. Gets or sets the color of the fore. The color of the fore. Type of the destination. Zoom factor. Location of the destination. Parent page reference. Pdf primitive representing this object. Indicates whether destination is valid. Destination is not valid if it has null location or zoom otherwise it is valid. Initializes a new instance of the class with specified page. The page where the destination should be placed. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Create the destination PdfDestination destination = new PdfDestination(page); //Set the destination page. bookmark.Destination = destination; //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Create the destination Dim destination As PdfDestination = New PdfDestination(page) 'Set the destination page. bookmark.Destination = destination 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Class. Initializes a new instance of the class with specified page base and location. The page where the destination should be placed. The location of the page. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Create the destination. PdfDestination destination = new PdfDestination(page,new PointF(0, 100)); //Set the destination page. bookmark.Destination = destination; //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Create the destination Dim destination As PdfDestination = New PdfDestination(page,new PointF(0, 100)) 'Set the destination page. bookmark.Destination = destination 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Class. Sets the validation. if it is valid, set to true. Translates co-ordinates to PDF co-ordinate system (lower/left). The page. Point in left/top co-ordinate system. Co-ordinates to PDF co-ordinate system (lower/left). Infills array by correct values. Initializes instance. Gets or sets zoom factor. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Create the destination. PdfDestination destination = new PdfDestination(page,new PointF(0, 100)); //Set the zoom factor. destination.Zoom = 100; //Set the destination page. bookmark.Destination = destination; //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Create the destination Dim destination As PdfDestination = New PdfDestination(page,new PointF(0, 100)) 'Set the zoom factor. destination.Zoom = 100 'Set the destination page. bookmark.Destination = destination 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Class. Gets or sets a page where the destination is situated. Gets or sets mode of the destination. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Create the destination. PdfDestination destination = new PdfDestination(page,new PointF(0, 100)); //Set the destination mode. destination.Mode = PdfDestinationMode.FitToPage; //Set the destination page. bookmark.Destination = destination; //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Create the destination. Dim destination As PdfDestination = New PdfDestination(page,new PointF(0, 100)) 'Set the destination mode. destination.Mode = PdfDestinationMode.FitToPage 'Set the destination page. bookmark.Destination = destination 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Class. Gets or sets a location of the destination. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Create the destination PdfDestination destination = new PdfDestination(page); //Set the location of the destination. destination.Location = new PointF(20, 20); //Set the destination page. bookmark.Destination = destination; //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Create the destination Dim destination As PdfDestination = New PdfDestination(page) 'Set the location of the destinatioin. destination.Location = new PointF(20, 20) 'Set the destination page. bookmark.Destination = destination 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Class. Gets a value indicating whether this instance is valid. true if this instance is valid; otherwise, false. //Create a new document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); //Create document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Create the destination PdfDestination destination = new PdfDestination(page); //Gets a value indicating whether this instance is valid. bool isValid = destination.IsValid; //Set the destination page. bookmark.Destination = destination; //Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Save and close the PDF document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() 'Create document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Create the destination Dim destination As PdfDestination = New PdfDestination(page) 'Gets a value indicating whether this instance is valid. bool isValid = destination.IsValid 'Set the destination page. bookmark.Destination = destination 'Set the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Save and close the PDF document. document.Save("Output.pdf") document.Close(True) Class. Class. Gets pdf primitive representing this object. Represents sound embedded into pdf document. Internal variable to store sampling rate. Internal variable to store encoding format. Internal variable to store number of sound channels. Internal variable to store number of bits per sample value per channel. Internal variable to store sound file name. Internal variable to store stream. Name of the file. Initializes a new instance of the class. Name of the file. if set to true [test]. Initializes a new instance of the class. Handles the BeginSave event of the Stream control. The source of the event. The instance containing the event data. Saves an instance. Gets or sets the sampling rate, in samples per second (in Hz). Gets or sets the number of bits per sample value per channel. Gets or sets the encoding format for the sample data. Gets or sets the number of sound channels. The name of the file. Gets the element. Represents specification of the references file in pdf document. Internal variable to store file name. File name. Path Type. Initializes a new instance of the class. Saves object. The name of the file. Optimized version of SortedList collection. Instead of keeping two arrays, one for keys and one for values, the values array on Hashtable collection are changed. Performance of this collection is better than that of SortedList. Default capacity of internal buffers. Array which store keys in sorted order. Collection stores values. Size of collection. Version of collection data. Default comparer for keys. List of keys. List of values. Initializes a new instance of the class. Initializes a new instance of the class. The initial capacity. Initializes a new instance of the class. The comparer. Initializes a new instance of the class. The comparer. The capacity. Initializes a new instance of the class. The d. Initializes a new instance of the class. The d. The comparer. Returns a synchronized (thread-safe) wrapper for the SortedList. The SortedList to synchronize. A synchronized (thread-safe) wrapper for the SortedList. When list is null. Adds an element with the provided key and value to the list. The Object to use as the key of the element to add. The Object to use as the value of the element to add. When key is null. When list already contains specified key. Removes all elements from the collection. Creates a new object that is a copy of the current instance. Copy of the current instance. Clone current instance. Returns clone of current object. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains the specified value. Value of the element to search. True if list contains specified value. Copies all the elements of the SortedListEx to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. If specified array is null. If rank of the array is not 1 or there are not enough elements. If specified arrayIndex is less than zero. Gets the value at the specified index of the SortedListEx. The zero-based index of the value to get. The value at the specified index of the SortedListEx. When index is less than zero or greater than size of the list. Gets the key at the specified index of the SortedListEx. The zero-based index of the key to get. The key at the specified index of the SortedListEx. When index is less than zero or greater than size of the list. Gets the keys in the SortedListEx. An IList containing the keys in the SortedListEx. Gets the values in the SortedListEx. An IList containing the values in the SortedListEx. Returns the zero-based index of the specified key. The key to locate. The zero-based index of key, if key is found; otherwise, -1. If specified key is null. Returns the zero-based index of the first occurrence of the specified value. The value to locate (can be NULL). The zero-based index of the first occurrence of value, if value is found; otherwise, -1. Removes the element at the specified index. The zero-based index of the element to remove. When index is less than zero or greater than size of the list. Removes the element with the specified key from SortedListEx. The key of the element to remove. Replaces the value at the specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. When index is less than zero or greater than size of the list. Sets the capacity to the actual number of elements. Returns an IDictionaryEnumerator that can iterate through the SortedListEx. An IDictionaryEnumerator for the SortedListEx. Returns an IEnumerator that can iterate through the SortedListEx. An IEnumerator for the SortedListEx. Inserts element with specified key and value at specified index. The zero-based index to insert element at. The key of the element to insert. The value of the element to insert. Ensures that the capacity of this instance is at least the specified value. The minimum capacity to ensure. Gets or sets the capacity. The capacity. Gets the number of elements contained in the . The number of elements contained in the . Gets an object containing the keys of the object. An object containing the keys of the object. Gets an object containing the values in the object. An object containing the values in the object. Gets a value indicating whether the object is read-only. true if the object is read-only; otherwise, false. Gets a value indicating whether the object has a fixed size. true if the object has a fixed size; otherwise, false. Gets a value indicating whether access to the is synchronized (thread safe). true if access to the is synchronized (thread safe); otherwise, false. Gets an object that can be used to synchronize access to the . An object that can be used to synchronize access to the . Gets or sets the value associated with the specified key. Wrapped SortedListEx. Sync object. Initializes a new instance of the class. The list. Adds an element with the provided key and value to the list. The Object to use as the key of the element to add. The Object to use as the value of the element to add. Removes all the elements from the collection. Creates a new object that is a copy of the current instance. A new object that is a copy of the current instance. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains the specified value. Value of the element to search. True if list contains specified value. Copies all the elements of the list to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. Gets the value at the specified index of the list. The zero-based index of the value to get. The value at the specified index of the SortedListEx. Returns an IDictionaryEnumerator that can iterate through the list. An IDictionaryEnumerator for the list. Gets the key at the specified index of the list. The zero-based index of the key to get. The key at the specified index of the list. Gets the keys in the list. An IList containing the keys in the list. Gets the values in the list. An IList containing the values in the list. Returns the zero-based index of the specified key. The key to locate. The zero-based index of key, if key is found; otherwise, -1. Returns the zero-based index of the first occurrence of the specified value. The value to locate (can be NULL). The zero-based index of the first occurrence of value, if value is found; otherwise, -1. Removes the element at the specified index. The zero-based index of the element to remove. Removes the element with the specified key from list. The key of the element to remove. Replaces the value at a specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. Sets the capacity to the actual number of elements. Capacity of internal buffers. Size of the collection. Read-only. Returns the object that can be used to synchronize access to the collection. Read-only. Returns True if list is readonly, False otherwise. Read-only. Returns True if collection has fixed size, False otherwise. Returns True if the collection is synchronized, False otherwise. Gets or sets the value associated with the specified key. key If it is assumed to getObjectRetType, Current will return key of the current element. If it is assumed to getObjectRetType, Current will return value of the current element. If it is assumed to getObjectRetType, Current will return both - key and value (as DictionaryEntry). List for which is this enumerator. Key of the current element. Values of the current element. Index of current element. Starting index for the enumerator. Ending index for this enumerator. Version of collection data. True if current element is correct, False otherwise (before beginning or after end). Specifies what should return method Current (Key, Value or both). Creates enumerator for specified list, starting from specified index and with specified count. list for which to create enumerator. Starting index. Number of elements to enumerate. Type of enumerating values (keys, value, DicEntry). Creates a new object that is a copy of the current instance. Copy of the current instance. Advances the enumerator to the next element of the collection. True if the enumerator was successfully advanced to the next element; False if the enumerator has passed the end of the collection. When the current version is not equal to the SortedListEx version. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Gets the key of the current dictionary entry. The key of the current element of the enumeration. The is positioned before the first entry of the dictionary or after the last entry. Gets both the key and the value of the current dictionary entry. A containing both the key and the value of the current dictionary entry. The is positioned before the first entry of the dictionary or after the last entry. Gets The current element in the collection. Read-only. If current is false. Gets the value of the current dictionary entry. The value of the current element of the enumeration. The is positioned before the first entry of the dictionary or after the last entry. List for which this collection was created. Creates KeyList for specified SortedListEx. SortedListEx for which KeyList must be created. Adds an element with the provided key to the list. The Object to use as the key of the element to add. Removes all elements from the collection. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Copies all the elements of the list to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. If array is null or rank of the array is not 1. Insert the value at the specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. Returns an IEnumerator that can iterate through the list. An IEnumerator for the list. Returns the zero-based index of the specified key. The key to locate. The zero-based index of the key, if the key is found; otherwise, -1. Removes the element with the specified key from list. The key of the element to remove. Removes the element at the specified index from the list. The zero-based index of the element to remove. Gets the number of elements contained in the . The number of elements contained in the . Gets a value indicating whether the is read-only. true if the is read-only; otherwise, false. Gets a value indicating whether the has a fixed size. true if the has a fixed size; otherwise, false. Returns True if the collection is synchronized, False otherwise. Returns the object that can be used to synchronize access to the collection. Read-only. Gets or sets the key at the specified index. List for which this collection was created. Array list that contain values. Creates ValueList for specified SortedListEx. SortedListEx for which ValueList must be created. Re-read values from the list. Adds an element with the provided key to the list. The Object to use as the key of the element to add. Removes all elements from the collection. Determines whether the list contains an element with the specified value. Value to search. True if list contains specified value. Copies all the elements of the list to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. Insert the value at the specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. Returns an IEnumerator that can iterate through the list. An IEnumerator for the list. Returns the zero-based index of the specified value. The value to locate. The zero-based index of the value, if the value is found, otherwise -1. Removes the specified value from list. The value to remove. Removes the element at the specified index from the list. The zero-based index of the element to remove. Gets the size of the collection. Read-only. Returns True if list is readonly, False otherwise. Read-only. Returns True if collection has fixed size, False otherwise. Returns True if the collection is synchronized, False otherwise. Returns the object that can be used to synchronize access to the collection. Read-only. Gets or sets the value at the specified index. Optimized version of SortedList collection. Instead of keeping two arrays, one for keys and one for values, the values array on Hashtable collection are changed. Performance of this collection is better than that of SortedList. Default capacity of internal buffers. Array which store keys in sorted order. Collection stores values. Size of collection. Version of collection data. Default comparer for keys. List of keys. List of values. Initializes a new instance of the class. Initializes a new instance of the class. The initial capacity. Initializes a new instance of the class. The comparer. Initializes a new instance of the class. The comparer. The capacity. Initializes a new instance of the class. The d. Initializes a new instance of the class. The d. The comparer. Returns a synchronized (thread-safe) wrapper for the SortedList. The SortedList to synchronize. A synchronized (thread-safe) wrapper for the SortedList. When list is null. Adds an element with the provided key and value to the list. The Object to use as the key of the element to add. The Object to use as the value of the element to add. When key is null. When list already contains specified key. Adds the specified pair. The pair. Removes all elements from the collection. Creates a new object that is a copy of the current instance. Copy of the current instance. Clone current instance. Returns clone of current object. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains the specified value. Value of the element to search. True if list contains specified value. Determines whether [contains] [the specified pair]. The pair. if it contains the specified pair, set to true . Copies all the elements of the SortedListEx to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. If specified array is null. If rank of the array is not 1 or there are not enough elements. If specified arrayIndex is less than zero. Gets the value at the specified index of the SortedListEx. The zero-based index of the value to get. The value at the specified index of the SortedListEx. When index is less than zero or greater than size of the list. Gets the key at the specified index of the SortedListEx. The zero-based index of the key to get. The key at the specified index of the SortedListEx. When index is less than zero or greater than size of the list. Gets the keys in the SortedListEx. An IList containing the keys in the SortedListEx. Gets the values in the SortedListEx. An IList containing the values in the SortedListEx. Returns the zero-based index of the specified key. The key to locate. The zero-based index of key, if key is found; otherwise, -1. If specified key is null. Returns the zero-based index of the first occurrence of the specified value. The value to locate (can be NULL). The zero-based index of the first occurrence of value, if value is found; otherwise, -1. Removes the element at the specified index. The zero-based index of the element to remove. When index is less than zero or greater than size of the list. Removes the element with the specified key from SortedListEx. The key of the element to remove. Removes the specified pair. The pair. Replaces the value at the specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. When index is less than zero or greater than size of the list. Sets the capacity to the actual number of elements. Returns an IDictionaryEnumerator that can iterate through the SortedListEx. An IDictionaryEnumerator for the SortedListEx. Returns an IEnumerator that can iterate through the SortedListEx. An IEnumerator for the SortedListEx. Tries the get value. The key. The value. Inserts element with specified key and value at specified index. The zero-based index to insert element at. The key of the element to insert. The value of the element to insert. Ensures that the capacity of this instance is at least the specified value. The minimum capacity to ensure. Capacity of internal buffers. Size of the collection. Read-only. List of keys. Read-only. List of keys. Read-only. List of values. Read-only. List of values. Read-only. Returns True if list is readonly, False otherwise. Read-only. Returns True if collection has fixed size, False otherwise. Returns True if the collection is synchronized, False otherwise. Returns the object that can be used to synchronize access to the collection. Read-only. Gets or sets the value associated with the specified key. Wrapped SortedListEx. Sync object. Creates SyncSortedListEx for specified SortedListEx. SortedListEx that will be wrapped. Adds an element with the provided key and value to the list. The Object to use as the key of the element to add. The Object to use as the value of the element to add. Removes all the elements from the collection. Creates a new object that is a copy of the current instance. A new object that is a copy of the current instance. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Determines whether the list contains the specified value. Value of the element to search. True if list contains specified value. Copies all the elements of the list to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. Gets the value at the specified index of the list. The zero-based index of the value to get. The value at the specified index of the SortedListEx. Returns an IDictionaryEnumerator that can iterate through the list. An IDictionaryEnumerator for the list. Gets the key at the specified index of the list. The zero-based index of the key to get. The key at the specified index of the list. Gets the keys in the list. An IList containing the keys in the list. Gets the values in the list. An IList containing the values in the list. Returns the zero-based index of the specified key. The key to locate. The zero-based index of key, if key is found; otherwise, -1. Returns the zero-based index of the first occurrence of the specified value. The value to locate (can be NULL). The zero-based index of the first occurrence of value, if value is found; otherwise, -1. Removes the element at the specified index. The zero-based index of the element to remove. Removes the element with the specified key from list. The key of the element to remove. Replaces the value at a specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. Sets the capacity to the actual number of elements. Capacity of internal buffers. Size of the collection. Read-only. Returns the object that can be used to synchronize access to the collection. Read-only. Returns True if list is readonly, False otherwise. Read-only. Returns True if collection has fixed size, False otherwise. Returns True if the collection is synchronized, False otherwise. Gets or sets the value associated with the specified key. List for which is this enumerator. Key of the current element. Values of the current element. Index of current element. Starting index for the enumerator. Ending index for this enumerator. Version of collection data. True if current element is correct, False otherwise (before beginning or after end). Shows if the object was disposed. Creates enumerator for specified list, starting from specified index and with specified count. list for which to create enumerator. Starting index. Number of elements to enumerate. Creates a new object that is a copy of the current instance. Copy of the current instance. Advances the enumerator to the next element of the collection. True if the enumerator was successfully advanced to the next element; False if the enumerator has passed the end of the collection. When the current version is not equal to the SortedListEx version. Sets the enumerator to its initial position, which is before the first element in the collection. When the current version is not equal to the SortedListEx version. Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. Returns key of the current element. Read-only. When the current version is not equal to the SortedListEx version or if current is false. The current element in the collection. Read-only. If current is false. Returns value for the current element. When the current version is not equal to the SortedListEx version or if current is false. Gets the element in the collection at the current position of the enumerator. The element in the collection at the current position of the enumerator. List for which this collection was created. Creates KeyList for specified SortedListEx. The sorted list ex. Adds an element with the provided key to the list. The Object to use as the key of the element to add. Removes all elements from the collection. Determines whether the list contains an element with the specified key. Key of the element to search. True if list contains specified key. Copies all the elements of the list to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. If array is null or rank of the array is not 1. Insert the value at the specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. Returns an IEnumerator that can iterate through the list. An IEnumerator for the list. Returns an IEnumerator that can iterate through the list. An IEnumerator for the list. Returns the zero-based index of the specified key. The key to locate. The zero-based index of the key, if the key is found; otherwise, -1. Removes the element with the specified key from list. The key of the element to remove. Removes the element at the specified index from the list. The zero-based index of the element to remove. Size of the collection. Read-only. Returns True if list is readonly, False otherwise. Read-only. Returns True if collection has fixed size, False otherwise. Returns True if the collection is synchronized, False otherwise. Returns the object that can be used to synchronize access to the collection. Read-only. Gets or sets the key at the specified index. List for which this collection was created. Array list that contain values. Creates ValueList for specified SortedListEx. The sorted list ex. Re-read values from the list. Adds an element with the provided key to the list. The Object to use as the key of the element to add. Removes all elements from the collection. Determines whether the list contains an element with the specified value. Value to search. True if list contains specified value. Copies all the elements of the list to the specified one-dimensional Array starting at the specified destination Array index. The one-dimensional Array that is the destination of the elements copied from the current list. The index in array at which copying begins. Insert the value at the specific index. The zero-based index at which to save value. The Object to save into. Can be NULL. Returns an IEnumerator that can iterate through the list. An IEnumerator for the list. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Returns the zero-based index of the specified value. The value to locate. The zero-based index of the value, if the value is found, otherwise -1. Removes the specified value from list. The value to remove. Removes the element at the specified index from the list. The zero-based index of the element to remove. Size of the collection. Read-only. Returns True if list is readonly, False otherwise. Read-only. Returns True if collection has fixed size, False otherwise. Returns True if the collection is synchronized, False otherwise. Returns the object that can be used to synchronize access to the collection. Read-only. Gets or sets the value at the specified index. Comparer for strings. Compare two strings. String to compare. String to compare. Returns compared results. Compares two objects and returns a value indicating whether one is less than, equal to, or greater than the other. The first object to compare. The second object to compare. Value Condition Less than zero. x is less than y.Zero x equals y.Greater than zero x is greater than y. Represents Uri file specification. Internal variable to store file name. File name. Initializes instance. Saves object. Utility class. Number of decimals in float rounding. Initializes a new instance of the class. Checks the file path. The path. The path if it exist. It's thrown if the file wasn't found. The encoding format for the sample data. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Sets the sound annotation border soundAnnotation.Border.Width = 4; soundAnnotation.Border.HorizontalRadius = 20; soundAnnotation.Border.VerticalRadius = 30; //Set the PDF sound annotation icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Sets the PDF sound. PdfSound sound = new PdfSound("Startup.wav"); soundAnnotation.Sound=sound; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Sets the sound annotation border soundAnnotation.Border.Width = 4 soundAnnotation.Border.HorizontalRadius = 20 soundAnnotation.Border.VerticalRadius = 30 'Set the PDF sound annotation icon. soundAnnotation.Icon = PdfSoundIcon.Speaker Sets the PDF sound. Dim sound As PdfSound = New PdfSound("Startup.wav") sound.Channels = PdfSoundChannels.Mono 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Class Class Class Unspecified or unsigned values in the range 0 to 2^B - 1. Twos-complement values. M-law�encoded samples. A-law�encoded samples. The number of sound channels. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Sets the sound annotation border soundAnnotation.Border.Width = 4; soundAnnotation.Border.HorizontalRadius = 20; soundAnnotation.Border.VerticalRadius = 30; //Set the PDF sound annotation icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Sets the PDF sound. PdfSound sound = new PdfSound("Startup.wav"); soundAnnotation.Sound=sound; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Sets the sound annotation border soundAnnotation.Border.Width = 4 soundAnnotation.Border.HorizontalRadius = 20 soundAnnotation.Border.VerticalRadius = 30 'Set the PDF sound annotation icon. soundAnnotation.Icon = PdfSoundIcon.Speaker Sets the PDF sound. Dim sound As PdfSound = New PdfSound("Startup.wav") sound.Channels = PdfSoundChannels.Mono 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Class Class Class One channel. Two channels. Enumeration that represents fit mode. //Creates a new document. PdfDocument document = new PdfDocument(); //Adds a page. PdfPage page = document.Pages.Add(); //Creates document bookmarks. PdfBookmark bookmark = document.Bookmarks.Add("Page 1"); //Sets the destination page. bookmark.Destination = new PdfDestination(page); //Sets the destination location. bookmark.Destination.Location = new PointF(20, 20); //Sets the text style and color. bookmark.TextStyle = PdfTextStyle.Bold; bookmark.Color = Color.Red; //Set the destination mode. bookmark.Destination.Mode = PdfDestinationMode.FitH; //Saves and closes the PDF document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Creates a new document. Dim document As PdfDocument = New PdfDocument() 'Adds a page. Dim page As PdfPage = document.Pages.Add() 'Creates document bookmarks. Dim bookmark As PdfBookmark = document.Bookmarks.Add("Page 1") 'Sets the destination page. bookmark.Destination = New PdfDestination(page) 'Sets the destination location. bookmark.Destination.Location = New PointF(20, 20) 'Sets the text style and color. bookmark.TextStyle = PdfTextStyle.Bold bookmark.Color = Color.Red 'Set the destination mode. bookmark.Destination.Mode = PdfDestinationMode.FitH 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Display the page designated by page, with the coordinates (left, top) positioned at the top-left corner of the window and the contents of the page magnified by the factor zoom. A NULL value for any of the parameters left, top, or zoom specifies that the current value of that parameter is to be retained unchanged. A zoom value of 0 has the same meaning as a NULL value. Display the page designated by page, with its contents magnified just enough to fit the entire page within the window both horizontally and vertically. If the required horizontal and vertical magnification factors are different, use the smaller of the two, centering the page within the window in the other dimension. Display the page designated by page, with the horizontal coordinate left positioned at the left edge of the window and the contents of the page magnified just enough to fit the entire height of the page within the window. Display the page designated by page, with the vertical coordinate top positioned at the top edge of the window and the contents of the page magnified just enough to fit the entire width of the page within the window. Represents the blend color space //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(); //Set blend to the brush. brush.Blend = blend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend() 'Set blend to the brush. brush.Blend = blend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represents the base class for PdfBlend and PdfColorBlend classes. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(); //Set factors blend.Factors = new float[] {1}; //Set poistions blend.Positions = new float[] {0}; //Set blend to the brush. brush.Blend = blend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend() 'Set factors blend.Factors = New Single() {1} 'Set poistions blend.Positions = New Single() {0} 'Set blend to the brush. brush.Blend = blend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Precision of the GCD calculations. Local variable to store the count. Local variable to store the positions. Initializes a new instance of the class. Initializes a new instance of the class with the specified elements count The number of the elements. Calculate the GCD of the specified values. The values. The calculated GCD value. Determines greatest common divisor of the specified u and v. The u. The v. The GCD value Determines greatest common divisor of the specified u and v. The u. The v. The GCD value Determines if both parameters are even numbers. The first value. The second value. result Determines if the u value is even. The u value. bool Interpolates the specified colours according to the t value. The t value, which show the imagine position on a line from 0 to 1. The minimal colour. The maximal colour. The color space. color Sets the array. The array, which has values. The array if it's passed all tests. Gets or sets the array of positions //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(); //Set factors blend.Factors = new float[] {1}; //Set poistions blend.Positions = new float[] {0}; //Set blend to the brush. brush.Blend = blend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend() 'Set factors blend.Factors = New Single() {1} 'Set poistions blend.Positions = New Single() {0} 'Set blend to the brush. brush.Blend = blend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the number of elements that specify the blend. Local variable to store the factors. Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(); //Set blend to the brush. brush.Blend = blend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend() 'Set blend to the brush. brush.Blend = blend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with the specified factor count The number of elements in the factors and positions arrays. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(1); //Set blend to the brush. brush.Blend = blend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend(1) 'Set blend to the brush. brush.Blend = blend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Generates a correct color blend. The colours. The color space. A well formed colour blend. Clones this instance. The copy of this instance of PdfBlend. Gets or sets the array of factor to the blend. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(); //Set factors blend.Factors = new float[] {1}; //Set poistions blend.Positions = new float[] {0}; //Set blend to the brush. brush.Blend = blend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend() 'Set factors blend.Factors = New Single() {1} 'Set poistions blend.Positions = New Single() {0} 'Set blend to the brush. brush.Blend = blend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Brushes for all the standard colors //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Black, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Black, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Local variable to store the brushes. Initializes a new instance of the class. Creates the default brush. The color. Name of the color. The proper PdfBrush instance. Gets the AliceBlue brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.AliceBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.AliceBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the antique white brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.AntiqueWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.AntiqueWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Aqua default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Aqua, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Aqua, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Aquamarine default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Aquamarine, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Aquamarine, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Azure default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Azure, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Azure, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Beige default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Beige, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Beige, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Bisque default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Bisque, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Bisque, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Black default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Black, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Black, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the BlanchedAlmond default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.BlanchedAlmond, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.BlanchedAlmond, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Blue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Blue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Blue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the BlueViolet default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.BlueViolet, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.BlueViolet, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Brown default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Brown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Brown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the BurlyWood default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the CadetBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.CadetBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.CadetBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Chartreuse default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Chartreuse, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Chartreuse, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Chocolate default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Chocolate, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Chocolate, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Coral default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Coral, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Coral, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the CornflowerBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.CornflowerBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.CornflowerBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Corn silk default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Cornsilk, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Cornsilk, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Crimson default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Crimson, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Crimson, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Cyan default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Cyan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Cyan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkCyan default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkCyan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkCyan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkGoldenrod default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkGoldenrod, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkGoldenrod, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkGray default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkKhaki default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkKhaki, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkKhaki, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkMagenta default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkMagenta, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkMagenta, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkOliveGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkOliveGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkOliveGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkOrange default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkOrange, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkOrange, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkOrchid default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkOrchid, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkOrchid, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkRed default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSalmon default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSalmon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSalmon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSeaGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSlateBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSlateBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSlateBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSlateGray default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSlateGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkSlateGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkTurquoise default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkTurquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkTurquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkViolet default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkViolet, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DarkViolet, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DeepPink default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DeepPink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DeepPink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DeepSkyBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DeepSkyBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DeepSkyBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DimGray default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DimGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DimGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DodgerBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.DodgerBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.DodgerBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Firebrick default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Firebrick, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Firebrick, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the FloralWhite default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.FloralWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.FloralWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the ForestGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.ForestGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.ForestGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Fuchsia default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Fuchsia, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Fuchsia, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Gainsborough default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Gainsboro, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Gainsboro, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the GhostWhite default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.GhostWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.GhostWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Gold default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Gold, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Gold, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Goldenrod default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Goldenrod, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Goldenrod, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Gray default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Gray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Gray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Green default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Green, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Green, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the GreenYellow default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.GreenYellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.GreenYellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Honeydew default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Honeydew, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Honeydew, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the HotPink default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.HotPink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.HotPink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the IndianRed default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.IndianRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.IndianRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Indigo default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Indigo, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Indigo, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Ivory default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Ivory, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Ivory, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Khaki default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Khaki, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Khaki, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Lavender default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Lavender, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Lavender, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LavenderBlush default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LavenderBlush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LavenderBlush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LawnGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LawnGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LawnGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LemonChiffon default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LemonChiffon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LemonChiffon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightCoral default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightCoral, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightCoral, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightCyan default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightCyan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightCyan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightGoldenrodYellow default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightGoldenrodYellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightGoldenrodYellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightGray default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightPink default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightPink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightPink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSalmon default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSalmon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSalmon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSeaGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSkyBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSkyBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSkyBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSlateGray default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSlateGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSlateGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSteelBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSteelBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightSteelBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightYellow default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightYellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LightYellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Lime default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Lime, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Lime, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LimeGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.LimeGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.LimeGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Linen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Linen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Linen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Magenta default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Magenta, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Magenta, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Maroon default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Maroon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Maroon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumAquamarine default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumAquamarine, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumAquamarine, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumOrchid default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumOrchid, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumOrchid, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumPurple default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumPurple, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumPurple, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumSeaGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumSeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumSeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumSlateBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumSlateBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumSlateBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumSpringGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumSpringGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumSpringGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumTurquoise default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumTurquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumTurquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumVioletRed default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumVioletRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MediumVioletRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MidnightBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MidnightBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MidnightBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MintCream default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MintCream, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MintCream, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MistyRose default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.MistyRose, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.MistyRose, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Moccasin default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Moccasin, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Moccasin, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the NavajoWhite default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.NavajoWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.NavajoWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Navy default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Navy, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Navy, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the OldLace default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.OldLace, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.OldLace, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Olive default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Olive, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Olive, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the OliveDrab default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.OliveDrab, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.OliveDrab, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Orange default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Orange, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Orange, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the OrangeRed default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.OrangeRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.OrangeRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Orchid default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Orchid, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Orchid, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleGoldenrod default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleGoldenrod, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleGoldenrod, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleTurquoise default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleTurquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleTurquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleVioletRed default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleVioletRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.PaleVioletRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PapayaWhip default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.PapayaWhip, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.PapayaWhip, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PeachPuff default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.PeachPuff, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.PeachPuff, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Peru default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Peru, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Peru, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Pink default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Pink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Pink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Plum default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Plum, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Plum, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PowderBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.PowderBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.PowderBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Purple default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Purple, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Purple, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Red default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the RosyBrown default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.RosyBrown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.RosyBrown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the RoyalBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.RoyalBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.RoyalBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SaddleBrown default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SaddleBrown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SaddleBrown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Salmon default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Salmon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Salmon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SandyBrown default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SandyBrown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SandyBrown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SeaGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SeaShell default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SeaShell, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SeaShell, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Sienna default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Sienna, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Sienna, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Silver default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Silver, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Silver, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SkyBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SkyBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SkyBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SlateBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SlateBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SlateBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SlateGray default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SlateGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SlateGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Snow default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Snow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Snow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SpringGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SpringGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SpringGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SteelBlue default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.SteelBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.SteelBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Tan default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Tan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Tan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Teal default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Teal, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Teal, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Thistle default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Thistle, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Thistle, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Tomato default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Tomato, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Tomato, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Transparent default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Transparent, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Transparent, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Turquoise default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Turquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Turquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Violet default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Violet, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Violet, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Wheat default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Wheat, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Wheat, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the White default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.White, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.White, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the WhiteSmoke default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.WhiteSmoke, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.WhiteSmoke, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Yellow default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.Yellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.Yellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the YellowGreen default brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfBrushes.YellowGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfBrushes.YellowGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represents the arrays of colors and positions used for interpolating color blending in a multicolor gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF color blend PdfColorBlend cblend = new PdfColorBlend(); //Set colors cblend.Colors = new PdfColor[] { Color.Blue, Color.Red }; //Set poistions cblend.Positions = new float[] { 0, 1 }; //Set internpolation colors to the brush. brush.InterpolationColors = cblend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF color blend Dim cblend As New PdfColorBlend() 'Set colors cblend.Colors = New PdfColor() { Color.Blue, Color.Red} 'Set poistions cblend.Positions = New Single() { 0, 1} 'Set internpolation colors to the brush. brush.InterpolationColors = cblend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Array of colors. Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF color blend PdfColorBlend cblend = new PdfColorBlend(); //Set colors cblend.Colors = new PdfColor[] { Color.Blue, Color.Red }; //Set poistions cblend.Positions = new float[] { 0, 1 }; //Set internpolation colors to the brush. brush.InterpolationColors = cblend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF color blend Dim cblend As New PdfColorBlend() 'Set colors cblend.Colors = New PdfColor() { Color.Blue, Color.Red} 'Set poistions cblend.Positions = New Single() { 0, 1} 'Set internpolation colors to the brush. brush.InterpolationColors = cblend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with the specified elements count The count of the element. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF color blend PdfColorBlend cblend = new PdfColorBlend(2); //Set colors cblend.Colors = new PdfColor[] { Color.Blue, Color.Red }; //Set poistions cblend.Positions = new float[] { 0, 1 }; //Set internpolation colors to the brush. brush.InterpolationColors = cblend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF color blend Dim cblend As New PdfColorBlend(2) 'Set colors cblend.Colors = New PdfColor() { Color.Blue, Color.Red} 'Set poistions cblend.Positions = New Single() { 0, 1} 'Set internpolation colors to the brush. brush.InterpolationColors = cblend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the function. The color space. The properly prepared sampled function. Clones this instance. The copy of this instance of the PdfColorBlend class. Sets the range. The colour components. The max value. The ranges array. Calculates the color components count according to colour space. The color space. The number of colour components. Gets samples values for specified colour space. The color space. The sample count. The max component value. The step. The byte array of the sample values. Gets the grayscale samples. The sample count. The max component value. The step. Gets the CMYK samples. The sample count. The max component value. The step. Gets the RGB samples. The sample count. The max component value. The step. The values of RGB samples. Calculates the color that should be at the specified index. The index. The step. The color space. The colour obtained from the calculation. Gets the indices. The position. The index low. The index hi. Calculates the max component value. The color space. The maximal component value. Gets an intervals array from the positions array. The positions array. The intervals obtained from the positions. Gets or sets the array of colors. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF color blend PdfColorBlend cblend = new PdfColorBlend(); //Set colors cblend.Colors = new PdfColor[] { Color.Blue, Color.Red }; //Set poistions cblend.Positions = new float[] { 0, 1 }; //Set internpolation colors to the brush. brush.InterpolationColors = cblend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF color blend Dim cblend As New PdfColorBlend() 'Set colors cblend.Colors = New PdfColor() { Color.Blue, Color.Red} 'Set poistions cblend.Positions = New Single() { 0, 1} 'Set internpolation colors to the brush. brush.InterpolationColors = cblend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Encapsulates a with a gradient brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Local variable to store the background color. Local variable to store the background color. Local variable to store the dictionary. Local variable to store the shading. Local variable to store the Transformation Matrix. Local variable to store the external state. Local variable to store the colorSpace. Local variable to store the function. Initializes a new instance of the class. The shading. Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. True if the brush was different. Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check True if the brush was different. Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. True if the brush was different. Monitors the changes of the brush and modify PDF state respectfully.. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. Indicates the indexed Color Space. True if the brush was different. Resets the changes, which were made by the brush. In other words resets the state to the initial one. The stream writer. Converts colorspace enum to a PDF name. The color space enum value. The correct string value. Resets the pattern dictionary. A new pattern dictionary. Resets the function. Clones the anti aliasing value. The brush. Clones the background value. The brush. Gets or sets the background color of the brush. This value is optional. If null is assigned to it, the associated entry is removed from the appropriate dictionary. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Set the background. brush.Background = Color.Black; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 300, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Set the background. brush.Background = Color.Black 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 300, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets a value indicating whether use anti aliasing algorithm. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Set anti alias. brush.AntiAlias = true; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Set anti alias. brush.AntiAlias = True 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the function of the brush. Gets or sets the boundary box of the brush. This value is optional. If null is assigned to it, the associated entry is removed from the appropriate dictionary. Gets or sets the color space of the brush. Gets or sets a value indicating whether this is stroking. Gets the pattern dictionary. Gets or sets the shading dictionary. It's obligatory to set this dictionary as soon as deriving class can. Gets or sets the transformation matrix. Gets or sets the external graphics state, which would be set temporary while this brush is active. The external graphics state. Gets the wrapped element. Implements linear gradient brush by using PDF axial shading pattern. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Local variable to store the point start. Local variable to store the point end. Local variable to store the colours. Local variable to store the colour Blend. Local variable to store the blend. Local variable to store the boundaries. Initializes a new instance of the class. The starting point of the gradient. The end point of the gradient. The starting color of the gradient. The end color of the gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. A RectangleF structure that specifies the bounds of the linear gradient. The starting color for the gradient. The ending color for the gradient. The mode specifies the orientation of the linear gradient //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new RectangleF(0, 0,200, 100), new PdfColor(Color.Red), new PdfColor(Color.Blue), PdfLinearGradientMode.Vertical); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New RectangleF(0, 0, 200, 100), New PdfColor(Color.Red), New PdfColor(Color.Blue), PdfLinearGradientMode.Vertical) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. A RectangleF structure that specifies the bounds of the linear gradient. The starting color for the gradient. The ending color for the gradient. The angle, measured in degrees clockwise from the x-axis, of the gradient's orientation line. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new RectangleF(0, 0,200, 100), new PdfColor(Color.Red), new PdfColor(Color.Blue), 90); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New RectangleF(0, 0, 200, 100), New PdfColor(Color.Red), New PdfColor(Color.Blue), 90) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The color of the start point. The color of the end point. Adds two points to each other. The point1. The point2. The resulting point. Subs the second point from the first one. The point1. The point2. The resulting point. Makes scalar multiplication of two points. The point1. The point2. The result of multiplication. Multiplies the point by the value specified. The point. The value. The result in point. Choosts the point according to the angle. The angle. The correct point. Sets the start and end points. The point1. The point2. Initializes the shading dictionary. Creates a new copy of a brush. A new instance of the Brush class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Set the background. brush.Background = Color.Black; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 300, 100)); PdfColor startColor = new PdfColor(Color.Black); PdfColor endColor = new PdfColor(Color.Green); //Clone the existing linear brush. PdfLinearGradientBrush cBrush = brush.Clone() as PdfLinearGradientBrush; //Set linear colors. cBrush.LinearColors = new PdfColor[] { startColor, endColor }; //Draw rectangle. graphics.DrawRectangle(cBrush, new RectangleF(0, 150, 300, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Set the background. brush.Background = Color.Black 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 300, 100)) Dim startColor As New PdfColor(Color.Black) Dim endColor As New PdfColor(Color.Green) 'Clone the existing linear brush. Dim cBrush As PdfLinearGradientBrush = TryCast(brush.Clone(), PdfLinearGradientBrush) 'Set linear colors. cBrush.LinearColors = New PdfColor() { startColor, endColor} 'Draw rectangle. graphics.DrawRectangle(cBrush, New RectangleF(0, 150, 300, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Resets the function. Gets or sets a PdfBlend that specifies positions and factors that define a custom falloff for the gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(); //Set factors blend.Factors = new float[] {1}; //Set poistions blend.Positions = new float[] {0}; //Set blend to the brush. brush.Blend = blend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend() 'Set factors blend.Factors = New Single() {1} 'Set poistions blend.Positions = New Single() {0} 'Set blend to the brush. brush.Blend = blend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets a ColorBlend that defines a multicolor linear gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Create PDF color blend PdfColorBlend cblend = new PdfColorBlend(); //Set colors cblend.Colors = new PdfColor[] { Color.Blue, Color.Red }; //Set poistions cblend.Positions = new float[] { 0, 1 }; //Set internpolation colors to the brush. brush.InterpolationColors = cblend; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Create PDF color blend Dim cblend As New PdfColorBlend() 'Set colors cblend.Colors = New PdfColor() { Color.Blue, Color.Red} 'Set poistions cblend.Positions = New Single() { 0, 1} 'Set internpolation colors to the brush. brush.InterpolationColors = cblend 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the starting and ending colors of the gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); PdfColor startColor = new PdfColor(Color.Black); PdfColor endColor = new PdfColor(Color.Green); //Set linear colors. brush.LinearColors = new PdfColor[] { startColor, endColor }; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) Dim startColor As New PdfColor(Color.Black) Dim endColor As New PdfColor(Color.Green) 'Set linear colors. brush.LinearColors = New PdfColor() { startColor, endColor} 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets a rectangular region that defines the boundaries of the gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Get the linear brush bounds. RectangleF rect = brush.Rectangle; //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Get the linear brush bounds. Dim rect As RectangleF = brush.Rectangle 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the value indicating whether the gradient should extend starting and ending points. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new PointF(0, 0), new PointF(200, 100), Color.Red, Color.Blue); //Set the extend mode. brush.Extend = PdfExtend.Both; //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 300, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New PointF(0, 0), New PointF(200, 100), Color.Red, Color.Blue) 'Set the extend mode. brush.Extend = PdfExtend.Both 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 300, 100)) 'Get the linear brush bounds. Dim rect As RectangleF = brush.Rectangle 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represent radial gradient brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Local varaible to store the point start. Local varaible to store the point start. Local varaible to store the point End. Local varaible to store the radius End. Local varaible to store the colours. Local varaible to store the colour blend. Local varaible to store the blend. Local varaible to store the boundaries. Initializes a new instance of the class. The start centre. The start radius. The end centre. The end radius. The start color. The end color. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The color1. The color2. Sets the points. The point start. The point end. The radius start. The radius end. Initializess the shading dictionary. Creates a new copy of a brush. A new instance of the Brush class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); PdfColor startColor = new PdfColor(Color.Black); PdfColor endColor = new PdfColor(Color.Green); //Clone the existing brush. PdfRadialGradientBrush cBrush = brush.Clone() as PdfRadialGradientBrush; //Set linear colors. cBrush.LinearColors = new PdfColor[] { startColor, endColor }; //Draw ellipse. graphics.DrawEllipse(cBrush, new RectangleF(0, 150, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Clone the existing brush. Dim cBrush As PdfRadialGradientBrush = TryCast(brush.Clone(), PdfRadialGradientBrush) 'Set linear colors. cBrush.LinearColors = New PdfColor() { startColor, endColor} 'Draw rectangle. graphics.DrawEllipse(cBrush, New RectangleF(0, 150, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Resets the function. Gets or sets a PdfBlend that specifies positions and factors that define a custom falloff for the gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Create PDF blend PdfBlend blend = new PdfBlend(); //Set factors blend.Factors = new float[] {1}; //Set poistions blend.Positions = new float[] {0}; //Set blend to the brush. brush.Blend = blend; //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Create PDF blend Dim blend As New PdfBlend() 'Set factors blend.Factors = New Single() {1} 'Set poistions blend.Positions = New Single() {0} 'Set blend to the brush. brush.Blend = blend 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets a ColorBlend that defines a multicolor linear gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Create PDF color blend PdfColorBlend cblend = new PdfColorBlend(); //Set colors cblend.Colors = new PdfColor[] { Color.Blue, Color.Red }; //Set poistions cblend.Positions = new float[] { 0, 1 }; //Set internpolation colors to the brush. brush.InterpolationColors = cblend; //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Create PDF color blend Dim cblend As New PdfColorBlend() 'Set colors cblend.Colors = New PdfColor() { Color.Blue, Color.Red} 'Set poistions cblend.Positions = New Single() { 0, 1} 'Set internpolation colors to the brush. brush.InterpolationColors = cblend 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the starting and ending colors of the gradient. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); PdfColor startColor = new PdfColor(Color.Black); PdfColor endColor = new PdfColor(Color.Green); //Set linear colors. brush.LinearColors = new PdfColor[] { startColor, endColor }; //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) Dim startColor As New PdfColor(Color.Black) Dim endColor As New PdfColor(Color.Green) 'Set linear colors. brush.LinearColors = New PdfColor() { startColor, endColor} 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the rectangle. The rectangle. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Get the radial brush bounds. RectangleF rect = brush.Rectangle; //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Get the radial brush bounds. Dim rect As RectangleF = brush.Rectangle 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the value indicating whether the gradient should extend starting and ending points. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Set the extend mode. brush.Extend = PdfExtend.Both; //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Set the extend mode. brush.Extend = PdfExtend.Both 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represents a brush that fills any object with a solid color. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.Red); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfSolidBrush(Color.Red) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) The colour of the brush. The color space of the brush. Indicates if the brush is immutable. Localvariable to store the Colorspace. Initializes a new instance of the class. The color - that represents the color of this brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.Red); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfSolidBrush(Color.Red) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The PDF extended color //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; // Create Gray ColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; //Create new PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(gray); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create GrayColorSpace Dim calGrayCS As PdfCalGrayColorSpace = New PdfCalGrayColorSpace() 'Create new instance for PdfCalGrayColor Dim gray As PdfCalGrayColor = New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 'Create new PDF gradient brush. Dim brush As New PdfSolidBrush(gray) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) class. Initializes a new instance of the class. The color. if set to true the brush is immutable. Initializes a new instance of the class. Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. True if the brush was different. Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check True if the brush was different. Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. True if the brush was different. Monitors the changes of the brush and modify PDF state respectively. The brush. The stream writer. The get resources delegate. if set to true the changes should be saved anyway. The current color space. check Indicates the IccBased Color Space. Indicates the indexed Color Space. True if the brush was different. Resets the changes, which were made by the brush. In other words resets the state to the initial one. The stream writer. Creates a new copy of a brush. A new instance of the Brush class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.Red); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Clone the existing solid brush. PdfSolidBrush cBrush = brush.Clone() as PdfSolidBrush; cBrush.Color = Color.Black; graphics.DrawRectangle(cBrush, new RectangleF(0, 150, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfSolidBrush(Color.Red) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Clone the existing solid brush. Dim cBrush As PdfSolidBrush = TryCast(brush.Clone(), PdfSolidBrush) cBrush.Color = Color.Black graphics.DrawRectangle(cBrush, New RectangleF(0, 150, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the color of the brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.Red); //Set color. brush.Color = new PdfColor(Color.Green); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfSolidBrush(Color.Red) 'Set color brush.Color = New PdfColor(Color.Green) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the Colorspace. Specifies the gradient direction of the linear gradient brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfLinearGradientBrush brush = new PdfLinearGradientBrush(new RectangleF(0, 0,200, 100), new PdfColor(Color.Red), new PdfColor(Color.Blue), PdfLinearGradientMode.Vertical); //Draw rectangle. graphics.DrawRectangle(brush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfLinearGradientBrush(New RectangleF(0, 0, 200, 100), New PdfColor(Color.Red), New PdfColor(Color.Blue), PdfLinearGradientMode.Vertical) 'Draw rectangle. graphics.DrawRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Specifies a gradient from upper right to lower left. Specifies a gradient from upper left to lower right. Specifies a gradient from left to right. Specifies a gradient from top to bottom. Specifies the constant values specifying whether to extend the shading beyond the starting and ending points of the axis. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF gradient brush. PdfRadialGradientBrush brush = new PdfRadialGradientBrush(new PointF(50, 50), 0, new PointF(50, 50), 50, Color.Red, Color.Blue); //Set the extend mode. brush.Extend = PdfExtend.Both; //Draw the ellipse. graphics.DrawEllipse(brush, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF gradient brush. Dim brush As New PdfRadialGradientBrush(New PointF(50, 50), 0, New PointF(50, 50), 50, Color.Red, Color.Blue) 'Set the extend mode. brush.Extend = PdfExtend.Both 'Draw the ellipse. graphics.DrawEllipse(brush, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Do not extend any point. Extend start point. Extend end point. Extend both start and end points. Shading type constants. Function-based shading. Axial shading. Radial shading. Free-form Gouraud-shaded triangle mesh Lattice-form Gouraud-shaded triangle mesh. Coons patch mesh. Tensor-product patch mesh. Specifies constant values of PdfHatchStyle pattern. Represents an arc shape. It ignores brush setting. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Arc bounds. RectangleF bounds = new RectangleF(0, 0, 200, 100); //Create new instance of PdfArc. PdfArc arc = new PdfArc(bounds, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Arc bounds. Dim bounds As New RectangleF(0, 0, 200, 100) 'Create new instance of PdfArc. Dim arc As New PdfArc(bounds, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Represents a base class of arc and pie shapes. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Arc bounds. RectangleF bounds = new RectangleF(0, 0, 200, 100); //Create new instance of PdfArc. PdfArc arc = new PdfArc(bounds, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Arc bounds. Dim bounds As New RectangleF(0, 0, 200, 100) 'Create new instance of PdfArc. Dim arc As New PdfArc(bounds, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Represents an area bound by a rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Represents an element to fill //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(PdfBrushes.Red, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(PdfBrushes.Red, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Represents a graphics element which can be drawn by a pen. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PdfLine instance. PdfLine line = new PdfLine(pen, new PointF(0, 0), new PointF(100, 0)); //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PdfLine instance. Dim line As New PdfLine(pen, New PointF(0, 0), New PointF(100, 0)) 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Base class for the main shapes. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Gets the bounds. rect //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Get the bounds. RectangleF bounds = rect.GetBounds(); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Get the bounds. Dim bounds As RectangleF = rect.GetBounds() 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Returns a rectangle that bounds this element. Returns a rectangle that bounds this element. This method doesn't take into consideration a rotation of the element. Layouts the element. Lay outing parameters. Returns lay outing results. Layouts the element. Lay outing parameters. Returns lay outing results. A pen object. Initializes a new instance of the class. Initializes a new instance of the class with the specified pen The pen. Gets the pen. If both pen and brush are not explicitly defined, default pen will be used. Gets the pen for drawing. Gets or sets a pen that will be used to draw the element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(new PointF(0, 0), new PointF(100, 0)); //Set pen. line.Pen = new PdfPen(Color.Red); //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(New PointF(0, 0), New PointF(100, 0)) 'Set pen. line.Pen = New PdfPen(Color.Red) 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Internal variable to store brush. Initializes a new instance of the class. Initializes a new instance of the class. The pen. Initializes a new instance of the class. The brush. Initializes a new instance of the class. The pen. The brush. Gets the pen. If both pen and brush are not explicitly defined, default pen will be used. brush Gets or sets the brush of the element //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Set PDF solid brush. rect.Brush = new PdfSolidBrush(Color.Green); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Set PDF solid brush. rect.Brush = New PdfSolidBrush(Color.Green) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Bounds of the element. Initializes a new instance of the class. Initializes a new instance of the class. The x. The y. The width. The height. Initializes a new instance of the class. The rectangle. Initializes a new instance of the class. The pen. The brush. The x. The y. The width. The height. Initializes a new instance of the class. The pen. The brush. The rectangle. Overloaded. Returns a rectangle that bounds this element. Returns a rectangle that bounds this element. Gets or sets the X co-ordinate of the upper-left corner of this the element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0; //Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0; //Set the width of the rectangle. rect.Width = 200; //Set the height of the rectangle. rect.Height = 100; //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0 'Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0 'Set the width of the rectangle. rect.Width = 200 'Set the height of the rectangle. rect.Height = 100 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Gets or sets the Y co-ordinate of the upper-left corner of this the element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0; //Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0; //Set the width of the rectangle. rect.Width = 200; //Set the height of the rectangle. rect.Height = 100; //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0 'Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0 'Set the width of the rectangle. rect.Width = 200 'Set the height of the rectangle. rect.Height = 100 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Gets or sets the width of this element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0; //Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0; //Set the width of the rectangle. rect.Width = 200; //Set the height of the rectangle. rect.Height = 100; //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0 'Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0 'Set the width of the rectangle. rect.Width = 200 'Set the height of the rectangle. rect.Height = 100 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Gets or sets the height of this element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0; //Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0; //Set the width of the rectangle. rect.Width = 200; //Set the height of the rectangle. rect.Height = 100; //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Set the X co-ordinate of the upper-left corner of rectangle. rect.X = 0 'Set the Y co-ordinate of the upper-left corner of rectangle. rect.Y = 0 'Set the width of the rectangle. rect.Width = 200 'Set the height of the rectangle. rect.Height = 100 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Gets or sets the size of this element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Set the size of the element. rect.Size = new SizeF(200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Set the size of the element. rect.Size = New SizeF(200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Gets or sets bounds of this element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Set the bounds of the element. rect.Bounds = new RectangleF(0, 10, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Set the bounds of the element. rect.Bounds = New RectangleF(0, 10, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. Initializes a new instance of the class with the specified pair of coordinates, width, height and sweep angle The x-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. Angle in degrees measured clockwise from the x-axis to the starting point of the ellipse. Angle in degrees measured clockwise from the startAngle parameter to ending point of the ellipse. Initializes a new instance of the class with the specified structure and sweep angle RectangleF structure that defines the boundaries of the ellipse. Angle in degrees measured clockwise from the x-axis to the starting point of the ellipse. Angle in degrees measured clockwise from the startAngle parameter to ending point of the ellipse. Initializes a new instance of the class with the specified pen, brush, pair of coordinates, width and height and sweep angle. Pen that determines the color, width, and style of the ellipse. Brush that determines the color and texture of the ellipse. The x-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. Angle in degrees measured clockwise from the x-axis to the starting point of the ellipse. Angle in degrees measured clockwise from the startAngle parameter to ending point of the ellipse. Initializes a new instance of the class. Pen that determines the color, width, and style of the ellipse. Brush that determines the color and texture of the ellipse. RectangleF structure that defines the boundaries of the ellipse. Angle in degrees measured clockwise from the x-axis to the starting point of the ellipse. Angle in degrees measured clockwise from the startAngle parameter to ending point of the ellipse. Gets or sets the start angle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Arc bounds. RectangleF bounds = new RectangleF(0, 0, 200, 100); //Create new instance of PdfArc. PdfArc arc = new PdfArc(bounds, 0, 180); //Set start angle. arc.StartAngle = 0; //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Arc bounds. Dim bounds As New RectangleF(0, 0, 200, 100) 'Create new instance of PdfArc. Dim arc As New PdfArc(bounds, 0, 180) 'Set start angle. arc.StartAngle = 0 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets or sets the sweep angle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Arc bounds. RectangleF bounds = new RectangleF(0, 0, 200, 100); //Create new instance of PdfArc. PdfArc arc = new PdfArc(bounds, 0, 180); //Set start angle. arc.StartAngle = 0; //Set sweep angle. arc.SweepAngle = 90; //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Arc bounds. Dim bounds As New RectangleF(0, 0, 200, 100) 'Create new instance of PdfArc. Dim arc As New PdfArc(bounds, 0, 180) 'Set start angle. arc.StartAngle = 0 'Set sweep angle. arc.SweepAngle = 90 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pair of coordinates, width, height and sweep angle Width of the rectangle that defines the arc. Height of the rectangle that defines the arc. Angle in degrees measured clockwise from the x-axis to the starting point of the arc. Angle in degrees measured clockwise from the startAngle parameter to ending point of the arc. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new instance of PdfArc. PdfArc arc = new PdfArc(200,100, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new instance of PdfArc. Dim arc As New PdfArc(200,100, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, width, height and sweep angle Pen that determines the color, width, and style of the arc. Width of the rectangle that defines the arc. Height of the rectangle that defines the arc. Angle in degrees measured clockwise from the x-axis to the starting point of the arc. Angle in degrees measured clockwise from the startAngle parameter to ending point of the arc. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Create new instance of PdfArc. PdfArc arc = new PdfArc(pen, 200, 100, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new instance of PdfArc. Dim arc As New PdfArc(pen, 200, 100, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. The x-coordinate of the upper-left corner of the rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the rectangle that defines the ellipse. Width of the rectangle that defines the arc. Height of the rectangle that defines the arc. Angle in degrees measured clockwise from the x-axis to the starting point of the arc. Angle in degrees measured clockwise from the startAngle parameter to ending point of the arc. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new instance of PdfArc. PdfArc arc = new PdfArc(0,0,200,100, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new instance of PdfArc. Dim arc As New PdfArc(0,0,200,100, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified structure and sweep angle RectangleF structure that defines the boundaries of the arc. Angle in degrees measured clockwise from the x-axis to the starting point of the arc. Angle in degrees measured clockwise from the startAngle parameter to ending point of the arc. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Arc bounds. RectangleF bounds = new RectangleF(0, 0, 200, 100); //Create new instance of PdfArc. PdfArc arc = new PdfArc(bounds, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Arc bounds. Dim bounds As New RectangleF(0, 0, 200, 100) 'Create new instance of PdfArc. Dim arc As New PdfArc(bounds, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, pair of coordinates, width, height and sweep angle Pen that determines the color, width, and style of the arc. The x-coordinate of the upper-left corner of the rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the rectangle that defines the ellipse. Width of the rectangle that defines the arc. Height of the rectangle that defines the arc. Angle in degrees measured clockwise from the x-axis to the starting point of the arc. Angle in degrees measured clockwise from the startAngle parameter to ending point of the arc. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Create new instance of PdfArc. PdfArc arc = new PdfArc(pen, 0, 0, 200, 100, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new instance of PdfArc. Dim arc As New PdfArc(pen, 0, 0, 200, 100, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, structure and sweep angle Pen that determines the color, width, and style of the arc. RectangleF structure that defines the boundaries of the arc. Angle in degrees measured clockwise from the x-axis to the starting point of the arc. Angle in degrees measured clockwise from the startAngle parameter to ending point of the arc. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Arc bounds. RectangleF bounds = new RectangleF(0, 0, 200, 100); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Create new instance of PdfArc. PdfArc arc = new PdfArc(pen, bounds, 0, 180); //Draw the arc to PDF page. arc.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Arc bounds. Dim bounds As New RectangleF(0, 0, 200, 100) 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new instance of PdfArc. Dim arc As New PdfArc(pen, bounds, 0, 180) 'Draw the arc to PDF page. arc.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. Draws an element on the Graphics. Graphics context where the element should be printed. Base class for elements lay outing. Layout the element. Initializes a new instance of the class. The element. Layouts the element. Lay outing parameters. Lay outing result. Layouts the element. Lay outing parameters. Lay outing result. Layouts the element. Lay outing parameters. Lay outing result. Layouts the HtmlToPdf element. Lay outing parameters. Lay outing result. Returns the next page. Current page. The next page. The next page is taken from the same section the current one was. If there is not enough pages within the section, the new one is appended. Layouts the element. Lay outing parameters. Lay outing result. Layouts the element. Lay outing parameters. Lay outing result. Gets paginate bounds. Layout parameters. Gets paginate bounds. Gets element`s layout. Represents a layouting format //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Indicates whether PaginateBounds were set and should be used or not. Bounds for the paginating. Layout type of the element. Break type of the element. Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class from the specified layout format The base format. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Create new PDF layout format instance. PdfLayoutFormat newFormat = new PdfLayoutFormat(format); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), newFormat); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Create new PDF layout format instance. Dim newFormat As PdfLayoutFormat = New PdfLayoutFormat(format) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), newFormat) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets layout type of the element. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets break type of the element. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the bounds on the next page. If this property is set, the element will use it for the layouting on the next pages, otherwise, the element will be layout according to the bounds, used on the first page. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets a value indicating whether [use paginate bounds]. true if [use paginate bounds]; otherwise, false. Represents the layouting result format. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Draw grid to the page of PDF document. PdfLayoutResult result = table.Draw(page, new PointF(0, 0)); //Draw grid. table.Draw(result.Page, result.Bounds.X, result.Bounds.Bottom + 10); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Draw grid to the page of PDF document. Dim result As PdfLayoutResult = table.Draw(page, New PointF(0, 0)) 'Draw grid. table.Draw(result.Page, result.Bounds.X, result.Bounds.Bottom + 10) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) The last page where the element was drawn. The bounds of the element on the last page where it was drawn. Holds the total web page layout size Represents the layouting result format including bounds and resultant page. The current page. The current bounds. The page might be null, which means that lay outing was performed on PdfGraphics. Gets the last page where the element was drawn. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Draw grid to the page of PDF document. PdfLayoutResult result = table.Draw(page, new PointF(0, 0)); //Draw grid. table.Draw(result.Page, result.Bounds.X, result.Bounds.Bottom + 10); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Draw grid to the page of PDF document. Dim result As PdfLayoutResult = table.Draw(page, New PointF(0, 0)) 'Draw grid. table.Draw(result.Page, result.Bounds.X, result.Bounds.Bottom + 10) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the bounds of the element on the last page where it was drawn. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Draw grid to the page of PDF document. PdfLayoutResult result = table.Draw(page, new PointF(0, 0)); //Draw grid. table.Draw(result.Page, result.Bounds.X, result.Bounds.Bottom + 10); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Draw grid to the page of PDF document. Dim result As PdfLayoutResult = table.Draw(page, New PointF(0, 0)) 'Draw grid. table.Draw(result.Page, result.Bounds.X, result.Bounds.Bottom + 10) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Holds the total web page layout size Represents the layouting parameters. Start lay outing page. Lay outing bounds. Layout settings. Gets or sets the layouting page for the element. Gets or sets layouting bounds for the element. Gets or sets layouting settings for the element. Layouts the metafiles. ShapeLayouter class. Determines the document link annotation border width. Initializes the object to store older form elements of previous page. Initializes the offset index. Initializes the difference in page height. Determines the end of Vertical offset values. Total Page size of the web page Text region manager to avoid text split between the pages Image region manager to avoid image split between the pages Form region manager to avoid form fields between pages Initializes a new instance of the class. The element. Layouts the element. Lay outing parameters. Lay outing result. Gets paginate bounds. Layout parameters. Gets paginate bounds. Layouts the element. Lay outing parameters. Lay outing result. Layouts the HtmlToPdf element. Lay outing parameters. Lay outing result. Corrects current bounds on the page. Current page. Current lay outing bounds. The current active shape bounds. Layout parameters. Corrected lay outing bounds. Creates layout result. Page layout result. Layout result. Corrects current bounds on the page. Current page. Current lay outing bounds. The current active shape bounds. Layout parameters. Corrected lay outing bounds. Repositions the links. The list. The height. Layouts the element on the current page. The current page. The current bounds. Active shape bounds that aren't layouted. Layout parameters. Page lay outing result. Draws shape for Tagged PDF. Calculates the next active shape bounds. The current active shape bounds. The current page layout result. The next active shape bounds. Checks whether shape rectangle fits to the lay outing bounds. Lay outing bounds. Shape bounds. True - if the shape fits into lay outing bounds, false otherwise. Returns Rectangle for element drawing on the page. Lay outing bounds. Current shape bounds. Returns Rectangle for element drawing on the page. Calculates bounds where the shape was layout on the page. Current lay outing bounds. Shape bounds. Bounds where the shape was layout on the page. Draws the shape. Current graphics. Current page bounds. Draw rectangle. Raises PageLayout event if needed. Page layout result. Event arguments.. Raises BeforePageLayout event. The current page. The current bounds. If true, stop lay outing. Corrects the bounds to avoid blank page. Current lay outing bounds. Shape bounds. Current Page. Corrected bounds. Gets shape element. Text region manager to avoid text split between the pages Image region manager to avoid image split between the pages Form region manager to avoid form field split between the pages Contains lay outing result settings. The last page where the element was drawn. The bounds of the element on the last page where it was drawn. Indicates whether the lay outing has been finished. List of names of the radio button collection. ArrayList for store names, number of elements(i.e. count), selected index of each radio button collection. Initializes a new instance of the class. The element. Repositions the links. The list. The height. Corrects current bounds on the page. Current page. Current lay outing bounds. The current active shape bounds. Lay outing parameters. Corrected lay outing bounds. Corrects current bounds on the page to restrict blank pages. Current page. Current lay outing bounds. The current active shape bounds. Corrected lay outing bounds. Gets shape element. Gets the Text regions manager. Gets the Image regions manager. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Dispose the metafile. metaChart.Dispose(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Dispose the metafile. metaChart.Dispose() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Indicates whether text line can be split among the pages. Indicates whether the images can be split among the pages. Gets or sets a value indicating whether [split text lines]. true if [split text lines]; otherwise, false. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Dispose the metafile. metaChart.Dispose(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Dispose the metafile. metaChart.Dispose() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets a value indicating whether to use the orginal Horizontal and Vertical resolution of the metafile. true if [to use the orginal Horizontal and Vertical resolution of the metafile]; otherwise, false. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Uses the orginal Horizontal and Vertical resolution of the metafile format.UseImageResolution = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Dispose the metafile. metaChart.Dispose(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Uses the orginal Horizontal and Vertical resolution of the metafile format.UseImageResolution = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Dispose the metafile. metaChart.Dispose() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets a value indicating whether [split images]. true if [split images]; otherwise, false. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Dispose the metafile. metaChart.Dispose(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Dispose the metafile. metaChart.Dispose() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or set the HTML page break. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; format.IsHTMLPageBreak = true; //Render the PdfMetafile in the PDF document result.Render(page, format); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False format.IsHTMLPageBreak = True 'Render the PdfMetafile in the PDF document result.Render(page, format) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Class that layouts the text. String format. Initializes a new instance of the class. The element. Layouts the element. Lay outing parameters. Lay outing result. Creates layout result. Page layout result. Layout result. Layouts the text on the page. The text that should be printed. Current page. Current bounds. Layout parameters. Page layout result. Corrects current bounds on the page. Current page. Current lay outing bounds. Corrected lay outing bounds. Returns a rectangle where the text was printed on the page. Current page. Current page text bounds. Layout result. Returns a rectangle where the text was printed on the page. Raises PageLayout event if needed. Page layout result. Event arguments. Raises BeforePageLayout event. The current page. The current bounds. If true, stops the layout. Corrects string format. The last line infor layouted. Gets element`s layout. Contains lay outing result settings. The last page where the text was drawn. The bounds of the element on the last page where it was drawn. Indicates whether the lay outing has been finished. The text that was not printed. Gets or sets a bounds of the last text line that was printed. Represents the text lay outing result settings. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Text Page Layout Event private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.Bounds; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Text Page Layout Event Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.Bounds End Sub The text that was not printed. The bounds of the last line that was printed. Initializes a new instance of the class. The page. The bounds. The remainder. The last line bounds. Gets a value that contains the text that was not printed. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Text Page Layout Event private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; string remText = tlr.Remainder; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Text Page Layout Event Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim remText As String = tlr.Remainder End Sub Gets a value that indicates the bounds of the last line that was printed on the page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Text Page Layout Event private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.LastLineBounds; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Text Page Layout Event Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.LastLineBounds End Sub Represents Bezier curve shape. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(0, 0, 100, 50, 50, 50, 100, 100); //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(0, 0, 100, 50, 50, 50, 100, 100) 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Local variable to store the start Point. Local variable to store the firstC ontrol Point. Local variable to store the second Control Point. Local variable to store the end Point. Initializes a new instance of the class with the specified structure PointF structure that represents the starting point of the curve. PointF structure that represents the first control point for the curve. PointF structure that represents the second control point for the curve. PointF structure that represents the ending point of the curve. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(new PointF(0, 0), new PointF(100, 50), new PointF(50, 50), new PointF(100, 100)); //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(New PointF(0, 0), New PointF(100, 50), New PointF(50, 50), New PointF(100, 100)) 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pair of coordinates and control points The x-coordinate of the starting point of the curve. The y-coordinate of the starting point of the curve. The x-coordinate of the first control point of the curve. The y-coordinate of the first control point of the curve. The x-coordinate of the second control point of the curve. The y-coordinate of the second control point of the curve. The x-coordinate of the ending point of the curve. The y-coordinate of the ending point of the curve. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(0, 0, 100, 50, 50, 50, 100, 100); //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(0, 0, 100, 50, 50, 50, 100, 100) 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen and structure. Pen that determines the color, width, and style of the curve. PointF structure that represents the starting point of the curve. PointF structure that represents the first control point for the curve. PointF structure that represents the second control point for the curve. PointF structure that represents the ending point of the curve. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(pen, new PointF(0, 0), new PointF(100, 50), new PointF(50, 50), new PointF(100, 100)); //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(pen, New PointF(0, 0), New PointF(100, 50), New PointF(50, 50), New PointF(100, 100)) 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pair of coordinates and control points Pen that determines the color, width, and style of the curve. The x-coordinate of the starting point of the curve. The y-coordinate of the starting point of the curve. The x-coordinate of the first control point of the curve. The y-coordinate of the first control point of the curve. The x-coordinate of the second control point of the curve. The y-coordinate of the second control point of the curve. The x-coordinate of the ending point of the curve. The y-coordinate of the ending point of the curve. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(pen, 0, 0, 100, 50, 50, 50, 100, 100); //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(pen, 0, 0, 100, 50, 50, 50, 100, 100) 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. Overloaded. Returns a rectangle that bounds this element. Returns a rectangle that bounds this element. Draws an element on the Graphics. Graphics context where the element should be printed. Gets or sets the starting point of the curve //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); PointF startPoint = new PointF(0, 0); PointF firstControlPoint = new PointF(100, 50); PointF secondControlPoint = new PointF(50, 50); PointF endPoint = new PointF(100, 100); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint); //Set start point. bezier.StartPoint = startPoint; //Set first control point. bezier.FirstControlPoint = firstControlPoint; //Set second control point. bezier.SecondControlPoint = secondControlPoint; //Set end point. bezier.EndPoint = endPoint; //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) Dim startPoint As New PointF(0, 0) Dim firstControlPoint As New PointF(100, 50) Dim secondControlPoint As New PointF(50, 50) Dim endPoint As New PointF(100, 100) 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint) 'Set start point. bezier.StartPoint = startPoint 'Set first control point. bezier.FirstControlPoint = firstControlPoint 'Set second control point. bezier.SecondControlPoint = secondControlPoint 'Set end point. bezier.EndPoint = endPoint 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets or sets the first control point of the curve. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); PointF startPoint = new PointF(0, 0); PointF firstControlPoint = new PointF(100, 50); PointF secondControlPoint = new PointF(50, 50); PointF endPoint = new PointF(100, 100); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint); //Set start point. bezier.StartPoint = startPoint; //Set first control point. bezier.FirstControlPoint = firstControlPoint; //Set second control point. bezier.SecondControlPoint = secondControlPoint; //Set end point. bezier.EndPoint = endPoint; //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) Dim startPoint As New PointF(0, 0) Dim firstControlPoint As New PointF(100, 50) Dim secondControlPoint As New PointF(50, 50) Dim endPoint As New PointF(100, 100) 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint) 'Set start point. bezier.StartPoint = startPoint 'Set first control point. bezier.FirstControlPoint = firstControlPoint 'Set second control point. bezier.SecondControlPoint = secondControlPoint 'Set end point. bezier.EndPoint = endPoint 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets or sets the second control point of the curve //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); PointF startPoint = new PointF(0, 0); PointF firstControlPoint = new PointF(100, 50); PointF secondControlPoint = new PointF(50, 50); PointF endPoint = new PointF(100, 100); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint); //Set start point. bezier.StartPoint = startPoint; //Set first control point. bezier.FirstControlPoint = firstControlPoint; //Set second control point. bezier.SecondControlPoint = secondControlPoint; //Set end point. bezier.EndPoint = endPoint; //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) Dim startPoint As New PointF(0, 0) Dim firstControlPoint As New PointF(100, 50) Dim secondControlPoint As New PointF(50, 50) Dim endPoint As New PointF(100, 100) 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint) 'Set start point. bezier.StartPoint = startPoint 'Set first control point. bezier.FirstControlPoint = firstControlPoint 'Set second control point. bezier.SecondControlPoint = secondControlPoint 'Set end point. bezier.EndPoint = endPoint 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets or sets the ending point of the curve. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); PointF startPoint = new PointF(0, 0); PointF firstControlPoint = new PointF(100, 50); PointF secondControlPoint = new PointF(50, 50); PointF endPoint = new PointF(100, 100); //Create new instance of PdfBezierCurve. PdfBezierCurve bezier = new PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint); //Set start point. bezier.StartPoint = startPoint; //Set first control point. bezier.FirstControlPoint = firstControlPoint; //Set second control point. bezier.SecondControlPoint = secondControlPoint; //Set end point. bezier.EndPoint = endPoint; //Draw the bezier curve to PDF page. bezier.Draw(page, new PointF(300, 200)); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) Dim startPoint As New PointF(0, 0) Dim firstControlPoint As New PointF(100, 50) Dim secondControlPoint As New PointF(50, 50) Dim endPoint As New PointF(100, 100) 'Create new instance of PdfBezierCurve. Dim bezier As New PdfBezierCurve(pen, startPoint, firstControlPoint, secondControlPoint, endPoint) 'Set start point. bezier.StartPoint = startPoint 'Set first control point. bezier.FirstControlPoint = firstControlPoint 'Set second control point. bezier.SecondControlPoint = secondControlPoint 'Set end point. bezier.EndPoint = endPoint 'Draw the bezier curve to PDF page. bezier.Draw(page, New PointF(300, 200)) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Represents an ellipse shape. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Bounds RectangleF bounds = new RectangleF(0, 0, 200, 100); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(bounds); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Bounds Dim bounds As New RectangleF(0, 0, 200, 100) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(bounds) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified width and height Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, width and height. Pen that determines the color, width, and style of the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(pen, 200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(pen, 200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified brush, width and height. Brush that determines the color and texture of the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Red); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(brush, 200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(brush, 200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, brush, width and height Pen that determines the color, width, and style of the ellipse. Brush that determines the color and texture of the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Red); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(pen, brush, 200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(pen, brush, 200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pair of coordinates, width and height The x-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(0, 0, 200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(0, 0, 200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the rectangle. RectangleF structure that defines the boundaries of the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Bounds RectangleF bounds = new RectangleF(0, 0, 200, 100); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(bounds); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Bounds Dim bounds As New RectangleF(0, 0, 200, 100) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(bounds) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, pair of coordinates, width and height Pen that determines the color, width, and style of the ellipse. The x-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(pen, 0, 0, 200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(pen, 0, 0, 200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen and structure Pen that determines the color, width, and style of the ellipse. RectangleF structure that defines the boundaries of the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Bounds RectangleF bounds = new RectangleF(0, 0, 200, 100); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(pen, bounds); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Bounds Dim bounds As New RectangleF(0, 0, 200, 100) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(pen, bounds) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified brush, pair of coordinates, width and height Brush that determines the color and texture of the ellipse. The x-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); PdfBrush brush = new PdfSolidBrush(Color.Red); //Creat new PdfEllipse instance. //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(brush, 0, 0, 200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(brush, 0, 0, 200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified brush and structure Brush that determines the color and texture of the ellipse. RectangleF structure that defines the boundaries of the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); PdfBrush brush = new PdfSolidBrush(Color.Red); //Creat new PdfEllipse instance. //Bounds RectangleF bounds = new RectangleF(0, 0, 200, 100); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(brush, bounds); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Bounds Dim bounds As New RectangleF(0, 0, 200, 100) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(brush, bounds) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, brush, pair of coordinates, width and height Pen that determines the color, width, and style of the ellipse. Brush that determines the color and texture of the ellipse. The x-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. The y-coordinate of the upper-left corner of the bounding rectangle that defines the ellipse. Width of the bounding rectangle that defines the ellipse. Height of the bounding rectangle that defines the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); PdfBrush brush = new PdfSolidBrush(Color.Red); //Creat new PdfEllipse instance. //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(pen, brush, 0, 0, 200, 100); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(pen, brush, 0, 0, 200, 100) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class with the specified pen, brush and structure Pen that determines the color, width, and style of the ellipse. Brush that determines the color and texture of the ellipse. RectangleF structure that defines the boundaries of the ellipse. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF Pen. PdfPen pen = new PdfPen(Color.Red); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Red); //Bounds RectangleF bounds = new RectangleF(0, 0, 200, 100); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(pen, brush, bounds); //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF Pen. Dim pen As New PdfPen(Color.Red) 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Red) 'Bounds Dim bounds As New RectangleF(0, 0, 200, 100) 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(pen, brush, bounds) 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. Draws an element on the Graphics. Graphics context where the element should be printed. Gets the radius X. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(200, 100); //Get the radius X. float radiusX = ellipse.RadiusX; //Get the radius Y. float radiusY = ellipse.RadiusY; //Get the center radius. PointF center = ellipse.Center; //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(200, 100) 'Get the radius X. Dim radiusX As Single = ellipse.RadiusX 'Get the radius Y. Dim radiusY As Single = ellipse.RadiusY 'Get the center radius. Dim center As PointF = ellipse.Center 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets the radius Y. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(200, 100); //Get the radius X. float radiusX = ellipse.RadiusX; //Get the radius Y. float radiusY = ellipse.RadiusY; //Get the center radius. PointF center = ellipse.Center; //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(200, 100) 'Get the radius X. Dim radiusX As Single = ellipse.RadiusX 'Get the radius Y. Dim radiusY As Single = ellipse.RadiusY 'Get the center radius. Dim center As PointF = ellipse.Center 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets the center point. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Creat new PdfEllipse instance. PdfEllipse ellipse = new PdfEllipse(200, 100); //Get the radius X. float radiusX = ellipse.RadiusX; //Get the radius Y. float radiusY = ellipse.RadiusY; //Get the center radius. PointF center = ellipse.Center; //Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Creat new PdfEllipse instance. Dim ellipse As New PdfEllipse(200, 100) 'Get the radius X. Dim radiusX As Single = ellipse.RadiusX 'Get the radius Y. Dim radiusY As Single = ellipse.RadiusY 'Get the center radius. Dim center As PointF = ellipse.Center 'Draw the ellipse to PDF page. ellipse.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Represents a line shape. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(new PointF(0, 0), new PointF(100, 0)); //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(New PointF(0, 0), New PointF(100, 0)) 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Local variable to store x2. Local variable to store Y1. Local variable to store x1. Local variable to store Y2. Initializes a new instance of the class from the specified two pair fo coordinates. The x-coordinate of the first point. The y-coordinate of the first point. The x-coordinate of the end pint. The y-coordinate of the end pint. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(0, 0, 100, 0); //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(0, 0, 100, 0) 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. The line start point. The line end point. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(new PointF(0, 0), new PointF(100, 0)); //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(New PointF(0, 0), New PointF(100, 0)) 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The x-coordinate of the first point. The y-coordinate of the first point. The x-coordinate of the end pint. The y-coordinate of the end pint. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PdfLine instance. PdfLine line = new PdfLine(pen, 0, 0, 100, 0); //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PdfLine instance. Dim line As New PdfLine(pen, 0, 0, 100, 0) 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The line start point. The line end point. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PdfLine instance. PdfLine line = new PdfLine(pen, new PointF(0, 0), new PointF(100, 0)); //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PdfLine instance. Dim line As New PdfLine(pen, New PointF(0, 0), New PointF(100, 0)) 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class. Overloaded. Returns a rectangle that bounds this element. Returns a rectangle that bounds this element. Draws an element on the Graphics. Graphics context where the element should be printed. Gets or sets the x coordinate of the start point. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(new PointF(0, 0), new PointF(100, 0)); //Set the x coordinate of the start point. line.X1 = 0; //Set the y coordinate of the start point. line.Y1 = 0; //Set the x coordinate of the end point. line.X2 = 100; //Set the y coordinate of the end point. line.Y2 = 0; //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(New PointF(0, 0), New PointF(100, 0)) 'Set the x coordinate of the start point. line.X1 = 0 'Set the y coordinate of the start point. line.Y1 = 0 'Set the x coordinate of the end point. line.X2 = 100 'Set the y coordinate of the end point. line.Y2 = 0 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets or sets the y coordinate of the start point. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(new PointF(0, 0), new PointF(100, 0)); //Set the x coordinate of the start point. line.X1 = 0; //Set the y coordinate of the start point. line.Y1 = 0; //Set the x coordinate of the end point. line.X2 = 100; //Set the y coordinate of the end point. line.Y2 = 0; //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(New PointF(0, 0), New PointF(100, 0)) 'Set the x coordinate of the start point. line.X1 = 0 'Set the y coordinate of the start point. line.Y1 = 0 'Set the x coordinate of the end point. line.X2 = 100 'Set the y coordinate of the end point. line.Y2 = 0 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets or sets the x coordinate of the end point. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(new PointF(0, 0), new PointF(100, 0)); //Set the x coordinate of the start point. line.X1 = 0; //Set the y coordinate of the start point. line.Y1 = 0; //Set the x coordinate of the end point. line.X2 = 100; //Set the y coordinate of the end point. line.Y2 = 0; //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(New PointF(0, 0), New PointF(100, 0)) 'Set the x coordinate of the start point. line.X1 = 0 'Set the y coordinate of the start point. line.Y1 = 0 'Set the x coordinate of the end point. line.X2 = 100 'Set the y coordinate of the end point. line.Y2 = 0 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Gets or sets the y coordinate of the end point. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfLine instance. PdfLine line = new PdfLine(new PointF(0, 0), new PointF(100, 0)); //Set the x coordinate of the start point. line.X1 = 0; //Set the y coordinate of the start point. line.Y1 = 0; //Set the x coordinate of the end point. line.X2 = 100; //Set the y coordinate of the end point. line.Y2 = 0; //Draw the line to PDF page. line.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfLine instance. Dim line As New PdfLine(New PointF(0, 0), New PointF(100, 0)) 'Set the x coordinate of the start point. line.X1 = 0 'Set the y coordinate of the start point. line.Y1 = 0 'Set the x coordinate of the end point. line.X2 = 100 'Set the y coordinate of the end point. line.Y2 = 0 'Draw the line to PDF page. line.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Implements graphics path, which is a sequence of primitive graphics elements. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Local varaible to store the points. Local varaible to store the path Types. Local varaible to store the Start Figure. Local varaible to store the fill Mode. Initializes a new instance of the class. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initializes a new instance of the class. The array of points that represents the points to define the path. The path types specifies the types of the corresponding points in the path. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); // Create an array of points. PointF[] pathPoints = { new PointF(0, 0), new PointF(100, 0), new PointF(100, 100), new PointF(0, 100), new PointF(0, 0), new PointF(100, 100), new PointF(0, 100), new PointF(100, 0) }; //Create path types. byte[] pathTypes = { 0, 1, 1, 129, 0, 1, 1, 1 }; //Create new PDF path. PdfPath path = new PdfPath(pathPoints, pathTypes); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() ' Create an array of points. Dim pathPoints As PointF() = {New PointF(0, 0), New PointF(100, 0), New PointF(100, 100), New PointF(0, 100), New PointF(0, 0), New PointF(100, 100), New PointF(0, 100), New PointF(100, 0)} 'Create path types. Dim pathTypes As Byte() = {0, 1, 1, 129, 0, 1, 1, 1} 'Create new PDF path. Dim path As New PdfPath(pathPoints, pathTypes) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initializes a new instance of the class. The pen. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(PdfPens.Red); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath(PdfPens.Red) 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initializes a new instance of the class. The brush. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(PdfBrushes.Red); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath(PdfBrushes.Red) 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initializes a new instance of the class. The brush. The fill mode specifies how the interiors of shapes in this path are filled. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(PdfBrushes.Red, PdfFillMode.Alternate); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath(PdfBrushes.Red, PdfFillMode.Alternate) 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initializes a new instance of the class. The pen. The array of points that represents the points to define the path. The path types specifies the types of the corresponding points in the path. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); // Create an array of points. PointF[] pathPoints = { new PointF(0, 0), new PointF(100, 0), new PointF(100, 100), new PointF(0, 100), new PointF(0, 0), new PointF(100, 100), new PointF(0, 100), new PointF(100, 0) }; //Create path types. byte[] pathTypes = { 0, 1, 1, 129, 0, 1, 1, 1 }; //Create new PDF path. PdfPath path = new PdfPath(PdfPens.Red, pathPoints, pathTypes); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() ' Create an array of points. Dim pathPoints As PointF() = {New PointF(0, 0), New PointF(100, 0), New PointF(100, 100), New PointF(0, 100), New PointF(0, 0), New PointF(100, 100), New PointF(0, 100), New PointF(100, 0)} 'Create path types. Dim pathTypes As Byte() = {0, 1, 1, 129, 0, 1, 1, 1} 'Create new PDF path. Dim path As New PdfPath(PdfPens.Red, pathPoints, pathTypes) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initializes a new instance of the class. The brush. The fill mode specifies how the interiors of shapes in this path are filled. The array of points that represents the points to define the path. The path types specifies the types of the corresponding points in the path. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); // Create an array of points. PointF[] pathPoints = { new PointF(0, 0), new PointF(100, 0), new PointF(100, 100), new PointF(0, 100), new PointF(0, 0), new PointF(100, 100), new PointF(0, 100), new PointF(100, 0) }; //Create path types. byte[] pathTypes = { 0, 1, 1, 129, 0, 1, 1, 1 }; //Create new PDF path. PdfPath path = new PdfPath(PdfBrushes.Red, PdfFillMode.Alternate, pathPoints, pathTypes); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() ' Create an array of points. Dim pathPoints As PointF() = {New PointF(0, 0), New PointF(100, 0), New PointF(100, 100), New PointF(0, 100), New PointF(0, 0), New PointF(100, 100), New PointF(0, 100), New PointF(100, 0)} 'Create path types. Dim pathTypes As Byte() = {0, 1, 1, 129, 0, 1, 1, 1} 'Create new PDF path. Dim path As New PdfPath(PdfBrushes.Red, PdfFillMode.Alternate, pathPoints, pathTypes) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initializes a new instance of the class. The pen. The brush. The fill mode specifies how the interiors of shapes in this path are filled. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(PdfPens.Green, PdfBrushes.Red, PdfFillMode.Alternate); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath(PdfPens.Green, PdfBrushes.Red, PdfFillMode.Alternate) 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds an arc. The boundaries of the arc. The start angle of the arc. The angle between startAngle and the end of the arc. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add arc. path.AddArc(new RectangleF(0, 0, 100, 100), 0, -90); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add arc. path.AddArc(New RectangleF(0, 0, 100, 100), 0, -90) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds an arc. The x-coordinate of the upper-left corner of the rectangular region. The y-coordinate of the upper-left corner of the rectangular region. The width of the rectangular region. The height of the rectangular region. The start angle of the arc. The angle between startAngle and the end of the arc. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add arc. path.AddArc(0, 0, 100, 100, 0, -90); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add arc. path.AddArc(0, 0, 100, 100, 0, -90) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds a bezier curve. The start point - represents the starting point of the curve. The first control point - represents the first control point of the curve. The second control point - repesents the second control point of the curve. The end point - represents the end point of the curve. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Start figure. path.StartFigure(); //Add bezier. path.AddBezier(new PointF(30, 30), new PointF(90, 0), new PointF(60, 90), new PointF(120, 30)); //Close figure. path.CloseFigure(); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Start figure. path.StartFigure() 'Add bezier. path.AddBezier(New PointF(30, 30), New PointF(90, 0), New PointF(60, 90), New PointF(120, 30)) 'Close figure. path.CloseFigure() 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds a bezier curve. The start point X. The start point Y. The first control point X. The first control point Y. The second control point X. The second control point Y. The end point X. The end point Y. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Start figure. path.StartFigure(); //Add bezier. path.AddBezier(30, 30, 90, 0, 60, 90, 120, 30); //Close figure. path.CloseFigure(); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Start figure. path.StartFigure() 'Add bezier. path.AddBezier(30, 30, 90, 0, 60, 90, 120, 30) 'Close figure. path.CloseFigure() 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds an ellipse. The boundaries of the ellipse. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add ellipse. path.AddEllipse(new RectangleF(0, 0, 200, 100)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add ellipse. path.AddEllipse(New RectangleF(0, 0, 200, 100)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds an ellipse. The x-coordinate of the upper-left corner of the rectangular region. The y-coordinate of the upper-left corner of the rectangular region. The width of the rectangular region. The height of the rectangular region. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add ellipse. path.AddEllipse(0, 0, 200, 100); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add ellipse. path.AddEllipse(0, 0, 200, 100) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds a line. The start point of the line. The end point of the line. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Adds a line. The x-coordinate of the starting point of the line. The y-coordinate of the starting point of the line. The x-coordinate of the end point of the line. The y-coordinate of the end point of the line. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add line path points. path.AddLine(10, 100, 10, 200); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add line path points. path.AddLine(10, 100, 10, 200) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Appends the path specified to this one. The path, which should be appended. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); // Create an array of points. PointF[] pathPoints = { new PointF(0, 0), new PointF(100, 0), new PointF(100, 100), new PointF(0, 100), new PointF(0, 0), new PointF(100, 100), new PointF(0, 100), new PointF(100, 0) }; //Create path types. byte[] pathTypes = { 0, 1, 1, 129, 0, 1, 1, 1 }; //Create PDF path. PdfPath pPath = new PdfPath(pathPoints, pathTypes); //Add PDF path. path.AddPath(pPath); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() ' Create an array of points. Dim pathPoints As PointF() = {New PointF(0, 0), New PointF(100, 0), New PointF(100, 100), New PointF(0, 100), New PointF(0, 0), New PointF(100, 100), New PointF(0, 100), New PointF(100, 0)} 'Create path types. Dim pathTypes As Byte() = {0, 1, 1, 129, 0, 1, 1, 1} 'Create PDF path. Dim pPath As New PdfPath(pathPoints, pathTypes) 'Add PDF path. path.AddPath(pPath) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Appends the path specified by the points and their types to this one. The array of points that represents the points to define the path. The path types specifies the types of the corresponding points in the path. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); // Create an array of points. PointF[] pathPoints = { new PointF(0, 0), new PointF(100, 0), new PointF(100, 100), new PointF(0, 100), new PointF(0, 0), new PointF(100, 100), new PointF(0, 100), new PointF(100, 0) }; //Create path types. byte[] pathTypes = { 0, 1, 1, 129, 0, 1, 1, 1 }; //Add path. path.AddPath(pathPoints, pathTypes); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() ' Create an array of points. Dim pathPoints As PointF() = {New PointF(0, 0), New PointF(100, 0), New PointF(100, 100), New PointF(0, 100), New PointF(0, 0), New PointF(100, 100), New PointF(0, 100), New PointF(100, 0)} 'Create path types. Dim pathTypes As Byte() = {0, 1, 1, 129, 0, 1, 1, 1} 'Add path. path.AddPath(pathPoints, pathTypes) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Appends the pie to this path. The bounding rectangle of the pie. The start angle of the pie. The sweep angle of the pie. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add Pie. path.AddPie(new RectangleF(20, 20, 70, 70), -45, 90); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add Pie. path.AddPie(New RectangleF(20, 20, 70, 70), -45, 90) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Appends the pie to this path. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-left corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. The start angle of the pie. The sweep angle of the pie. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add Pie. path.AddPie(20, 20, 70, 70, -45, 90); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add Pie. path.AddPie(20, 20, 70, 70, -45, 90) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Append the closed polygon to this path. The points of the polygon. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Create polygon points. PointF[] polygonPoints = { new PointF(23, 20), new PointF(40, 10), new PointF(57, 20), new PointF(50, 40), new PointF(30, 40) }; //Add polygon. path.AddPolygon(polygonPoints); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Create polygon points. Dim polygonPoints As PointF() = {New PointF(23, 20), New PointF(40, 10), New PointF(57, 20), New PointF(50, 40), New PointF(30, 40)} 'Add polygon. path.AddPolygon(polygonPoints) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Appends the rectangle to this path. The rectangle. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add rectangle path.AddRectangle(new RectangleF(0, 0, 200, 100)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add rectangle path.AddRectangle(New RectangleF(0, 0, 200, 100)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Appends the rectangle to this path. The x-coordinate of the upper-left corner of the rectangular region. The y-coordinate of the upper-left corner of the rectangular region. The width of the rectangular region. The height of the rectangular region. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add rectangle path.AddRectangle(0, 0, 200, 100); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add rectangle path.AddRectangle(0, 0, 200, 100) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Starts a new figure. The next added primitive will start a new figure. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Start first figure. path.StartFigure(); path.AddArc(10, 10, 50, 50, 0, 270); path.CloseFigure(); //Start second figure. path.StartFigure(); path.AddRectangle(10, 70, 50, 100); path.CloseFigure(); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Start first figure. path.StartFigure() path.AddArc(10, 10, 50, 50, 0, 270) path.CloseFigure() 'Start second figure. path.StartFigure() path.AddRectangle(10, 70, 50, 100) path.CloseFigure() 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Closes the last figure. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Start first figure. path.StartFigure(); path.AddArc(10, 10, 50, 50, 0, 270); path.CloseFigure(); //Start second figure. path.StartFigure(); path.AddRectangle(10, 70, 50, 100); path.CloseFigure(); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Start first figure. path.StartFigure() path.AddArc(10, 10, 50, 50, 0, 270) path.CloseFigure() 'Start second figure. path.StartFigure() path.AddRectangle(10, 70, 50, 100) path.CloseFigure() 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Closes all non-closed figures. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); path.StartFigure(); path.AddLine(new Point(10, 100), new Point(150, 100)); path.AddLine(new Point(150, 100), new Point(10, 200)); path.StartFigure(); path.AddArc(200, 200, 100, 100, 0, 90); path.StartFigure(); PointF point1 = new PointF(300, 300); PointF point2 = new PointF(400, 325); PointF point3 = new PointF(400, 375); PointF point4 = new PointF(300, 400); PointF[] points = { point1, point2, point3, point4 }; path.AddPolygon(points); //Close all the figures. path.CloseAllFigures(); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() path.StartFigure() path.AddLine(New Point(10, 100), New Point(150, 100)) path.AddLine(New Point(150, 100), New Point(10, 200)) path.StartFigure() path.AddArc(200, 200, 100, 100, 0, 90) path.StartFigure() Dim point1 As New PointF(300, 300) Dim point2 As New PointF(400, 325) Dim point3 As New PointF(400, 375) Dim point4 As New PointF(300, 400) Dim points As PointF() = {point1, point2, point3, point4} path.AddPolygon(points) 'Close all the figures. path.CloseAllFigures() 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the last point. The last point. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add rectangle path.AddRectangle(new RectangleF(0, 0, 200, 100)); //Get last point. PointF lastPoint = path.GetLastPoint(); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add rectangle path.AddRectangle(New RectangleF(0, 0, 200, 100)) 'Get last point. Dim lastPoint As PointF = path.GetLastPoint() 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Overloaded. Returns a rectangle that bounds this element. Returns a rectangle that bounds this element. Draws an element on the Graphics. Graphics context where the element should be printed. Adds the points along with their type to the path. The points. Type of the points. Adds the points along with their type to the path. The points. Type of the points. The start index. The end index. Adds a point and its type. The point. Type of the point. Closes the figure. The index of the last figure point. Gets or sets the fill mode. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Set the path fill mode. path.FillMode = PdfFillMode.Winding; //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Set the path fill mode. path.FillMode = PdfFillMode.Winding; 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the path points. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Set the path fill mode. path.FillMode = PdfFillMode.Winding; //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Get path Points. PointF[] pathPoints = path.PathPoints; //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Set the path fill mode. path.FillMode = PdfFillMode.Winding; 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Get path Points. Dim pathPoints As PointF() = path.PathPoints 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the path point types. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Set the path fill mode. path.FillMode = PdfFillMode.Winding; //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Get path Types. byte[] pathTypes = path.PathTypes; //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Set the path fill mode. path.FillMode = PdfFillMode.Winding; 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Get path Types. Dim pathTypes As Byte() = path.PathTypes 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the point count. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Get path point count. int count = path.PointCount; //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Get path point count. Dim count As Integer = path.PointCount 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the last point. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Set the path fill mode. path.FillMode = PdfFillMode.Winding; //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Get last point. PointF lastPoint = path.LastPoint; //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Set the path fill mode. path.FillMode = PdfFillMode.Winding; 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Get last point. Dim lastPoint As PointF = path.LastPoint 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the points list. The points. Gets the types. The types. Represents a HTML text area with the ability to span several pages. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. To know more about refer this link . //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(htmlText, font, PdfBrushes.Black); htmlTextElement.TextAlign = TextAlign.Left; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement(htmlText, font, PdfBrushes.Black) htmlTextElement.TextAlign = TextAlign.Left 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) The font. The brush. The HTML text. The Text Alignment. Initializes a new instance of the class. This Constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with the specified HTML text, font and brush This Constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The HTML text to be rendered in PDF. The font. The brush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(htmlText, font, PdfBrushes.Black); htmlTextElement.TextAlign = TextAlign.Left; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement(htmlText, font, PdfBrushes.Black) htmlTextElement.TextAlign = TextAlign.Left 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Draws the text on the graphics. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Graphics context where the text should be drawn RectangleF structure that specifies the bounds of the text. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Set text align. htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(graphics, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Set text align htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(graphics, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Draws the text on the graphics. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Graphics context where the text should be drawn. Start location on the page. Width of the text bounds. Height of the text bounds. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Set text align. htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(graphics, new PointF(0, 0), page.GetClientSize().Width, page.GetClientSize().Height); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Set text align htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(graphics, New PointF(0, 0), page.GetClientSize().Width, page.GetClientSize().Height) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Draws the text on the page. Current page where the text should be drawn. Start location on the page. Width of the text bounds. Height of the text bounds. Layouting format. Layouting result. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET library with the capability to produce Adobe PDF files" //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. PdfLayoutResult result = htmlTextElement.Draw(page, new PointF(0, 0), page.GetClientSize().Width, page.GetClientSize().Height, format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET library with the capability to produce Adobe PDF files" 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. Dim result As PdfLayoutResult = htmlTextElement.Draw(page, New PointF(0, 0), page.GetClientSize().Width, page.GetClientSize().Height, format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Draws the text on the page. Current page where the text should be drawn. Start location on the page. Width of the text bounds. Layout format. Layouting result. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET library with the capability to produce Adobe PDF files"; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. PdfLayoutResult result = htmlTextElement.Draw(page, new PointF(0, 0), page.GetClientSize().Width, format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET library with the capability to produce Adobe PDF files" 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. Dim result As PdfLayoutResult = htmlTextElement.Draw(page, New PointF(0, 0), page.GetClientSize().Width, format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Draws the text on the page. Current page where the text should be drawn. RectangleF structure that specifies the bounds of the text. layout format. Layout result. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET library with the capability to produce Adobe PDF files"; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. PdfLayoutResult result = htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET library with the capability to produce Adobe PDF files" 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. Dim result As PdfLayoutResult = htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Parsing the HTML text Pick style from HTML node Get color values Get Color from RGB Raises EndPageLayout event. Event arguments. Raises BeginPageLayout event. Event arguments. Gets or sets the base font for the text element. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the brush for the text element. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Set PDF brush. htmlTextElement.Brush = new PdfSolidBrush(Color.Red); //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Set PDF brush. htmlTextElement.Brush = New PdfSolidBrush(Color.Red) 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the HTML Text. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the text alignment. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Set text align. htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Set text align htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets value that indicates whether to use native or managed code rendering. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Disable native rendering to avoid GDI+ error in Windows azure htmlTextElement.IsNativeRenderingEnabled= false; htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Set PDF brush. htmlTextElement.Brush = new PdfSolidBrush(Color.Red); //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Disable native rendering to avoid GDI+ error in Windows azure. htmlTextElement.IsNativeRenderingEnabled=false; htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Set PDF brush. htmlTextElement.Brush = New PdfSolidBrush(Color.Red) 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Default value is true. Gets a value indicating whether EndPageLayout is not null. Gets a value indicating whether BeginPageLayout is not null. Event. Raises after the element was printed on the page. Event. Raises before the element should be printed on the page. Represents Pdf Template object. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty); //Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty) 'Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Graphics context of the template. Content of the object. Resources of the template. Size of the template. Indicates if the template is read-only. To create custom pdftemplate name and set signature validation appearance Indicates template contains appearance of annotation Indicates annotation template needs scaling Initializes a new instance of the class. The size of the PDF template //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty); //Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty) 'Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The rect - represents the rectangle bounds of the PDF template. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new RectangleF(0, 0, 200, 100)); //Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty); //Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New RectangleF(0, 0, 200, 100)) 'Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty) 'Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The width of the template. The height of the template. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(200, 100); //Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty); //Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(200, 100) 'Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty) 'Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The X-coordinate of the template start point. The Y-coordinate of the template start point. The width of the template. The height of the template. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(0, 0, 200, 100); //Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty); //Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(0, 0, 200, 100) 'Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty) 'Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The origin points of the Pdf Page The size of the new template. The data stream of the new template. The resources of the new template. The resulting template is read-only in order to avoid unexpected side effects caused by non-restored graphics state. Initializes a new instance of the class. The size of the new template. The data stream of the new template. The resources of the new template. The resulting template is read-only in order to avoid unexpected side effects caused by non-restored graphics state. Initializes a new instance of the class. The template. Initializes a new instance of the class. Default Constructor Resets the template and sets the specified size. The size. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty); //Reset the template. template.Reset(new SizeF(300, 200)); //Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 150)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty) 'Reset the template. template.Reset(New SizeF(300, 200)) 'Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 150)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Resets an instance. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty); //Reset the template. template.Reset(); //Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 150)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Draw the text to the template graphics. template.Graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, PointF.Empty) 'Reset the template. template.Reset() 'Draw a rectangle on the template graphics template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 150)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Returns a rectangle that bounds this element. Returns a rectangle that bounds this element. This method doesn't take into consideration a rotation of the element. Draws an element on the Graphics. Graphics context where the element should be printed. Initializes object. Gets the resources and modifies the template dictionary. Pdf resources. Adds type key. Adds SubType key. Sets the size of the template. The size. Sets the bounds of the template. The bounds. Sets the size of the template. The size. Copies the resources from the template. create new BBOX based minimum(x,y) and maximum(x,y) coordinate pairs from 3-by-3 transformation matrix Obtain maximum value from collection Obtain minimum value from collection Transformation matrix values Gets graphics context of the template. It will return null, if the template is read-only. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Get the template graphics. PdfGraphics graphics = template.Graphics; //Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, new PointF(0,0)); //Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Get the template graphics. Dim graphics As PdfGraphics = template.Graphics 'Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, New PointF(0, 0)) 'Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the size of the template. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Get the template graphics. PdfGraphics graphics = template.Graphics; //Get the template size. SizeF templateSize = template.Size; Console.Write("Template size: " + templateSize.Width + ", " + templateSize.Height); //Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, new PointF(0,0)); //Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Get the template graphics. Dim graphics As PdfGraphics = template.Graphics 'Get the template size. Dim templateSize As SizeF = template.Size Console.Write("Template size: " + templateSize.Width + ", " + templateSize.Height) 'Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, New PointF(0, 0)) 'Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the width of the template. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Get the template graphics. PdfGraphics graphics = template.Graphics; //Get the template width. float width = template.Width; Console.Write("Template width: " + width); //Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, new PointF(0,0)); //Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Get the template graphics. Dim graphics As PdfGraphics = template.Graphics 'Get the template width. Dim width As Single = template.Width Console.Write("Template width: " + width) 'Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, New PointF(0, 0)) 'Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the height of the template. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create new PdfTemplate object. PdfTemplate template = new PdfTemplate(new SizeF(200, 100)); //Get the template graphics. PdfGraphics graphics = template.Graphics; //Get the template height. float height = template.Height; Console.Write("Template height: " + height); //Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, new PointF(0,0)); //Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, new RectangleF(0, 20, 200, 50)); //Draw the template to PDF page. template.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create new PdfTemplate object. Dim template As New PdfTemplate(New SizeF(200, 100)) 'Get the template graphics. Dim graphics As PdfGraphics = template.Graphics 'Get the template height. Dim height As Single = template.Height Console.Write("Template height: " + height) 'Draw the text to the template graphics. graphics.DrawString("This is PDF template.", font, PdfBrushes.Black, New PointF(0, 0)) 'Draw a rectangle on the template graphics graphics.DrawRectangle(PdfBrushes.BurlyWood, New RectangleF(0, 20, 200, 50)) 'Draw the template to PDF page. template.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets a value indicating whether the template is read-only. true if the template is read-only; otherwise, false. Read-only templates does not expose graphics. They just return null. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF standard font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Create PdfTemplate object. PdfTemplate template = page.CreateTemplate(); //Get read-only bool readOnlyTemplate = template.ReadOnly; Console.Write("Read-Only template: " + readOnlyTemplate.ToString()); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF standard font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Create PdfTemplate object. Dim template As PdfTemplate = page.CreateTemplate() 'Get read-only Dim readOnlyTemplate As Boolean = template.ReadOnly Console.Write("Read-Only template: " + readOnlyTemplate.ToString()) 'Close the document. doc.Close(True) Gets the wrapped element. Gets or sets a value, indicating the annotation graphics. Gets or sets a value, indicating the annotation template need scaling. Represents a pie shape. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(new RectangleF(0, 0, 200, 100), 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(New RectangleF(0, 0, 200, 100), 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the pie shape. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfPens.Red, 200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfPens.Red, 200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The brush of the pie shape. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfBrushes.Red, 200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfBrushes.Red, 200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the pie shape. The brush of the pie shape. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfPens.Black, PdfBrushes.Red, 200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfPens.Black, PdfBrushes.Red, 200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-left corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(0, 0, 200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(0, 0, 200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The rectangle region of the pie shape. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(new RectangleF(0, 0, 200, 100), 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(New RectangleF(0, 0, 200, 100), 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the pie shape. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-left corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfPens.Red, 0, 0, 200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfPens.Red, 0, 0, 200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the pie. The rectangle region of the pie shape. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfPens.Red, new RectangleF(0, 0, 200, 100), 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfPens.Red,New RectangleF(0, 0, 200, 100), 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The brush of the pie shape. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-left corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfBrushes.Red, 0, 0, 200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfBrushes.Red, 0, 0, 200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The brush of the pie shape. The rectangle region of the pie shape. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfBrushes.Red, new RectangleF(0, 0, 200, 100), 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfBrushes.Red, New RectangleF(0, 0, 200, 100), 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the pie shape. The brush of the pie shape. The x-coordinate of the upper-left corner of the bounding rectangle. The y-coordinate of the upper-left corner of the bounding rectangle. The width of the bounding rectangle. The height of the bounding rectangle. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfPens.Black, PdfBrushes.Red, 0, 0, 200, 100, 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfPens.Black, PdfBrushes.Red, 0, 0, 200, 100, 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the pie shape. The brush of the pie shape. The rectangle region of the pie shape. Angle in degrees measured clockwise from the x-axis to the starting point of the pie. Angle in degrees measured clockwise from the startAngle parameter to ending point of the pie. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create a new PDF pie instance. PdfPie pie = new PdfPie(PdfPens.Black, PdfBrushes.Red, new RectangleF(0, 0, 200, 100), 0, 180); //Draw the pie to PDF page. pie.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF pie instance. Dim pie As New PdfPie(PdfPens.Black, PdfBrushes.Red, New RectangleF(0, 0, 200, 100), 0, 180) 'Draw the pie to PDF page. pie.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. Draws an element on the Graphics. Graphics context where the element should be printed. Represents a set of points connected with lines, could be drawn and filled. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(50, 50); PointF point2 = new PointF(100, 50); PointF point3 = new PointF(150, 100); PointF point4 = new PointF(150, 150); PointF point5 = new PointF(100, 200); PointF point6 = new PointF(50, 200); PointF point7 = new PointF(0, 150); PointF point8 = new PointF(0, 100); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(points); //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(50, 50) Dim point2 As New PointF(100, 50) Dim point3 As New PointF(150, 100) Dim point4 As New PointF(150, 150) Dim point5 As New PointF(100, 200) Dim point6 As New PointF(50, 200) Dim point7 As New PointF(0, 150) Dim point8 As New PointF(0, 100) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(points) 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Array of the points. Initializes a new instance of the class. The points that represents the vertices of the polygon. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(50, 50); PointF point2 = new PointF(100, 50); PointF point3 = new PointF(150, 100); PointF point4 = new PointF(150, 150); PointF point5 = new PointF(100, 200); PointF point6 = new PointF(50, 200); PointF point7 = new PointF(0, 150); PointF point8 = new PointF(0, 100); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(points); //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(50, 50) Dim point2 As New PointF(100, 50) Dim point3 As New PointF(150, 100) Dim point4 As New PointF(150, 150) Dim point5 As New PointF(100, 200) Dim point6 As New PointF(50, 200) Dim point7 As New PointF(0, 150) Dim point8 As New PointF(0, 100) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(points) 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the polygon shape. The points that represents the vertices of the polygon. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(100, 100); PointF point2 = new PointF(150, 100); PointF point3 = new PointF(200, 150); PointF point4 = new PointF(200, 200); PointF point5 = new PointF(150, 250); PointF point6 = new PointF(100, 250); PointF point7 = new PointF(50, 200); PointF point8 = new PointF(50, 150); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(PdfPens.Red, points); //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(100, 100) Dim point2 As New PointF(150, 100) Dim point3 As New PointF(200, 150) Dim point4 As New PointF(200, 200) Dim point5 As New PointF(150, 250) Dim point6 As New PointF(100, 250) Dim point7 As New PointF(50, 200) Dim point8 As New PointF(50, 150) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(PdfPens.Red, points) 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The brush of the polygon shape. The points that represents the vertices of the polygon. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(100, 100); PointF point2 = new PointF(150, 100); PointF point3 = new PointF(200, 150); PointF point4 = new PointF(200, 200); PointF point5 = new PointF(150, 250); PointF point6 = new PointF(100, 250); PointF point7 = new PointF(50, 200); PointF point8 = new PointF(50, 150); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(PdfBrushes.Red, points); //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(100, 100) Dim point2 As New PointF(150, 100) Dim point3 As New PointF(200, 150) Dim point4 As New PointF(200, 200) Dim point5 As New PointF(150, 250) Dim point6 As New PointF(100, 250) Dim point7 As New PointF(50, 200) Dim point8 As New PointF(50, 150) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(PdfBrushes.Red, points) 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The pen of the polygon shape. The brush of the polygon shape. The points that represents the vertices of the polygon. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(100, 100); PointF point2 = new PointF(150, 100); PointF point3 = new PointF(200, 150); PointF point4 = new PointF(200, 200); PointF point5 = new PointF(150, 250); PointF point6 = new PointF(100, 250); PointF point7 = new PointF(50, 200); PointF point8 = new PointF(50, 150); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(PdfPens.Black, PdfBrushes.Red, points); //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(100, 100) Dim point2 As New PointF(150, 100) Dim point3 As New PointF(200, 150) Dim point4 As New PointF(200, 200) Dim point5 As New PointF(150, 250) Dim point6 As New PointF(100, 250) Dim point7 As New PointF(50, 200) Dim point8 As New PointF(50, 150) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(PdfPens.Black, PdfBrushes.Red, points) 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. Adds a point to the polygon. The last point of the polygon. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(100, 100); PointF point2 = new PointF(150, 100); PointF point3 = new PointF(200, 150); PointF point4 = new PointF(200, 200); PointF point5 = new PointF(150, 250); PointF point6 = new PointF(100, 250); PointF point7 = new PointF(50, 200); PointF point8 = new PointF(50, 150); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(PdfPens.Red, points); //Add points. polygon.AddPoint(new PointF(50, 50)); //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(100, 100) Dim point2 As New PointF(150, 100) Dim point3 As New PointF(200, 150) Dim point4 As New PointF(200, 200) Dim point5 As New PointF(150, 250) Dim point6 As New PointF(100, 250) Dim point7 As New PointF(50, 200) Dim point8 As New PointF(50, 150) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(PdfPens.Red, points) 'Add points. polygon.AddPoint(New PointF(50, 50)) 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Overloaded. Returns a rectangle that bounds this element. Returns a rectangle that bounds this element. Draws an element on the Graphics. Graphics context where the element should be printed. Gets or sets the points of the polygon. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(100, 100); PointF point2 = new PointF(150, 100); PointF point3 = new PointF(200, 150); PointF point4 = new PointF(200, 200); PointF point5 = new PointF(150, 250); PointF point6 = new PointF(100, 250); PointF point7 = new PointF(50, 200); PointF point8 = new PointF(50, 150); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(PdfPens.Black, new PointF[] { new PointF(0,100) }); //Set the polygon points. polygon.Points = points; //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(100, 100) Dim point2 As New PointF(150, 100) Dim point3 As New PointF(200, 150) Dim point4 As New PointF(200, 200) Dim point5 As New PointF(150, 250) Dim point6 As New PointF(100, 250) Dim point7 As New PointF(50, 200) Dim point8 As New PointF(50, 150) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(PdfPens.Black, New PointF() {New PointF(0, 100)}) 'Set the polygon points. polygon.Points = points 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets a number of the points in the polygon. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Polygon points. PointF point1 = new PointF(100, 100); PointF point2 = new PointF(150, 100); PointF point3 = new PointF(200, 150); PointF point4 = new PointF(200, 200); PointF point5 = new PointF(150, 250); PointF point6 = new PointF(100, 250); PointF point7 = new PointF(50, 200); PointF point8 = new PointF(50, 150); PointF[] points = { point1, point2, point3, point4, point5, point6, point7, point8 }; //Create a new PDF polygon instance. PdfPolygon polygon = new PdfPolygon(PdfPens.Red, points); //Get the polygon points count. int count = polygon.Count; Console.WriteLine("Polygon points count: " + count); //Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Polygon points. Dim point1 As New PointF(100, 100) Dim point2 As New PointF(150, 100) Dim point3 As New PointF(200, 150) Dim point4 As New PointF(200, 200) Dim point5 As New PointF(150, 250) Dim point6 As New PointF(100, 250) Dim point7 As New PointF(50, 200) Dim point8 As New PointF(50, 150) Dim points As PointF() = {point1, point2, point3, point4, point5, point6, point7, point8} 'Create a new PDF polygon instance. Dim polygon As New PdfPolygon(PdfPens.Red, points) 'Get the polygon points count. Dim count As Integer = polygon.Count Console.WriteLine("Polygon points count: " + count) 'Draw the polygon to PDF page. polygon.Draw(page, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represents a simple rectangle that could be drawn and/or filled. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(pen, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(pen, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The brush. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Green); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(brush, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Green) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(brush, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The brush. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Green); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(pen, brush, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Green) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(pen, brush, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The x-coordinate of the upper-left corner of this Rectangle. The y-coordinate of the upper-left corner of this Rectangle. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(0, 0, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(0, 0, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(new RectangleF(0, 0, 200, 100)); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(New RectangleF(0, 0, 200, 100)) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The x-coordinate of the upper-left corner of this Rectangle. The y-coordinate of the upper-left corner of this Rectangle. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(pen, 0, 0, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(pen, 0, 0, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(pen, new RectangleF(0, 0, 200, 100)); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(pen, New RectangleF(0, 0, 200, 100)) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The brush. The x-coordinate of the upper-left corner of this Rectangle. The y-coordinate of the upper-left corner of this Rectangle. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Green); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(brush, 0, 0, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Green) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(brush, 0, 0, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The brush. The rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Green); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(brush, new RectangleF(0, 0, 200, 100)); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Green) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(brush, New RectangleF(0, 0, 200, 100)) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The brush. The x-coordinate of the upper-left corner of this Rectangle. The y-coordinate of the upper-left corner of this Rectangle. The width of the rectangle. The height of the rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Green); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(pen, brush, 0, 0, 200, 100); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Green) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(pen, brush, 0, 0, 200, 100) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. The pen. The brush. The rectangle. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a new PDF page. PdfPage page = document.Pages.Add(); //Create new PDF pen. PdfPen pen = new PdfPen(Color.Red); //Create new PDF solid brush. PdfBrush brush = new PdfSolidBrush(Color.Green); //Create new PdfRectangle instance. PdfRectangle rect = new PdfRectangle(pen, brush, new RectangleF(0, 0, 200, 100)); //Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty); //Save the PDF docment. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a new PDF page. Dim page As PdfPage = document.Pages.Add() 'Create new PDF pen. Dim pen As New PdfPen(Color.Red) 'Create new PDF solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Green) 'Create new PdfRectangle instance. Dim rect As New PdfRectangle(pen, brush, New RectangleF(0, 0, 200, 100)) 'Draw the rectangle to PDF page. rect.Draw(page, PointF.Empty) 'Save the PDF docment. document.Save("output.pdf") Close the PDF document. document.Close(True) Initializes a new instance of the class. Draws an element on the Graphics. Graphics context where the element should be printed. Internal class which is used converts the html string in to Rich Text. Internal variable to store the status of the RichTextBox control. Internal variable. Internal variable used while parsing the html text. Internal variable to check for nested tag. Dictionary containg list of support html tags. Internal variable to specify font. Internal varible to specify the color. Internal variable to store copy of m_color. Internal variable to store the PDF font size; Internal variable to store the Html font size. Method for maintaining the performance of RTF control while updating. Method invoked once the RTF control is updated. Invoked once the handle has been created. The Eventargs. Converts the the given colorref to Color The Color. The RGB coded color. Initializes the dictionary. Converts the the given color to colorref Red Green Blue The ColorRef equivalent for color. Converts the the given color to colorref The color. The ColorRef Renders the given html text in to the RTF Control. strHTML font color Parses the HtmlString. The HtmlString. Parses the each Html Elements (Xml node) and apply the formatting. The htmltag The Character format. The Paragraph format. Converts the the given text to safe text The text. The safe text Gets or sets the text alignment. Gets or sets the paragraph format. Gets or sets the default paragraph format. Gets or sets the character format. Gets or sets the default character format. Gets a value indicating whether [internal updating]. true if [internal updating]; otherwise, false. Specifies how text in a is horizontally aligned. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 14); //Simple HTML content string htmlText = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files "; //Create new PDF HTML text element. PdfHTMLTextElement htmlTextElement = new PdfHTMLTextElement(); //Set text align. htmlTextElement.TextAlign = TextAlign.Left; //Set html text. htmlTextElement.HTMLText = htmlText; //Set font. htmlTextElement.Font = font; //Format Layout. PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitPage; //Draw htmlString to PDF page. htmlTextElement.Draw(page, new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 14) 'Simple HTML content Dim htmlText As String = "Essential PDF is a .NET " + "library with the capability to produce Adobe PDF files " 'Create new PDF HTML text element. Dim htmlTextElement As New PdfHTMLTextElement() 'Set text align htmlTextElement.TextAlign = TextAlign.Left 'Set html text. htmlTextElement.HTMLText = htmlText 'Set font. htmlTextElement.Font = font 'Format Layout. Dim format As New PdfMetafileLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitPage 'Draw htmlString to PDF page. htmlTextElement.Draw(page, New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height), format) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) The text is aligned to the left. The text is aligned to the right. The text is aligned in the center. The text is justified. internal variable to store Size. internal variable to store Mask. internal variable to store Numbering. internal variable to store Reserved. internal variable to store Start Indent. internal variable to store Right Indent. internal variable to store Offset. internal variable to store Alignment. internal variable to store Tab Count. internal variable to store rgxTabs. internal variable to store Space Before. internal variable to store Space After. internal variable to store Line Spacing. internal variable to store Style. internal variable to store Line Spacing Rule. internal variable to store Out line Level. internal variable to store Shading Weight. internal variable to store Shading Style. internal variable to store Numbering Start. internal variable to store Numbering Style. internal variable to store Numbering Tab. internal variable to store Border Space. internal variable to store Border Width. internal variable to store Borders. internal variable to store size. internal variable to store Mask. internal variable to store Effects. internal variable to store Height. internal variable to store Offset. internal variable to store Text Color. internal variable to store CharSet. internal variable to store Pitch And Family. internal variable to store Weight. internal variable to store Spacing. internal variable to store BackColor. internal variable to store lcid. internal variable to store Reserved. internal variable to store Style. internal variable to store Kerning. internal variable to store Under line Type. internal variable to store Animation. internal variable to store RevAuthor. internal variable to store Reserved. Provides the data for a cancelable event. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //Begin Page Layout Event Handler private void BeginPageLayout2(object sender, BeginPageLayoutEventArgs e) { e.Cancel=true; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") End Sub 'Begin Page Layout Event Handler Private Sub BeginPageLayout2(ByVal sender As object, ByVal e As BeginPageLayoutEventArgs) e.Cancel=True End Sub Indicates whether lay outing should be stopped. Gets or sets a value indicating whether this is cancel. true if cancel; otherwise, false. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); bounds = column; //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //Begin Page Layout Event Handler private void BeginPageLayout2(object sender, BeginPageLayoutEventArgs e) { e.Cancel=true; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim rect As New RectangleF(0, 0, page.GetClientSize().Width, 50) Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") End Sub 'Begin Page Layout Event Handler Private Sub BeginPageLayout2(ByVal sender As object, ByVal e As BeginPageLayoutEventArgs) e.Cancel=True End Sub Provides data for event before lay outing the new page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //Begin Page Layout Event Handler private void BeginPageLayout2(object sender, BeginPageLayoutEventArgs e) { RectangleF bounds = e.Bounds; // First column. if (!m_paginateStart) { bounds.X = bounds.Width + 20f; bounds.Y = 10f; } e.Bounds = bounds; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'Begin Page Layout Event Handler Private Sub BeginPageLayout2(ByVal sender As object, ByVal e As BeginPageLayoutEventArgs) Dim bounds As RectangleF = e.Bounds ' First column. If (Not m_paginateStart) Then bounds.X = bounds.Width + 20f bounds.Y = 10f End If e.Bounds = bounds End Sub The bounds of the lay outing on the page. Page where the lay outing should start. Initializes a new instance of the class with the specified rectangle and page The bounds. The page. Gets or sets value that indicates the lay outing bounds on the page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //Begin Page Layout Event Handler private void BeginPageLayout2(object sender, BeginPageLayoutEventArgs e) { RectangleF bounds = e.Bounds; // First column. if (!m_paginateStart) { bounds.X = bounds.Width + 20f; bounds.Y = 10f; } e.Bounds = bounds; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'Begin Page Layout Event Handler Private Sub BeginPageLayout2(ByVal sender As object, ByVal e As BeginPageLayoutEventArgs) Dim bounds As RectangleF = e.Bounds ' First column. If (Not m_paginateStart) Then bounds.X = bounds.Width + 20f bounds.Y = 10f End If e.Bounds = bounds End Sub Gets the page where the lay outing should start. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //Begin Page Layout Event Handler private void BeginPageLayout2(object sender, BeginPageLayoutEventArgs e) { PdfPage page = e.pAGE; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'Begin Page Layout Event Handler Private Sub BeginPageLayout2(ByVal sender As object, ByVal e As BeginPageLayoutEventArgs) Dim page As PdfPage = e.Page End Sub Provides data for event once lay outing completed on the new page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); m_columnBounds = column; //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Page Layout Event Handler private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.Bounds; args.NextPage = tlr.Page; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Page Layout Event Handler Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.Bounds args.NextPage = tlr.Page End Sub Layout result. The next page for lay outing. Initializes a new instance of the class. with the specified The result. Gets the lay outing result of the page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Page Layout Event Handler private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.Bounds; args.NextPage = tlr.Page; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Page Layout Event Handler Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.Bounds args.NextPage = tlr.Page End Sub Gets or sets a value indicating the next page where the element should be layout The default value is null. In this case the element will be layout on the next page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Page Layout Event Handler private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; args.NextPage = tlr.Page; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Page Layout Event Handler. Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result args.NextPage = tlr.Page End Sub Represents the base class for classes that contain event data, and provides a value to use for events, once completed the text lay outing on the page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Text Page Layout Event private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.Bounds; args.NextPage = tlr.Page; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Text Page Layout Event Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.Bounds args.NextPage = tlr.Page End Sub Initializes a new instance of the class with the specified The result. Gets the lay outing result of the page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Text Page Layout Event private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.Bounds; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Text Page Layout Event Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.Bounds End Sub Represents the method that will handle an event that before lay outing on the page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //Begin Page Layout Event Handler private void BeginPageLayout2(object sender, BeginPageLayoutEventArgs e) { RectangleF bounds = e.Bounds; // First column. if (!m_paginateStart) { bounds.X = bounds.Width + 20f; bounds.Y = 10f; } e.Bounds = bounds; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'Begin Page Layout Event Handler Private Sub BeginPageLayout2(ByVal sender As object, ByVal e As BeginPageLayoutEventArgs) Dim bounds As RectangleF = e.Bounds ' First column. If (Not m_paginateStart) Then bounds.X = bounds.Width + 20f bounds.Y = 10f End If e.Bounds = bounds End Sub // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Page Layout Event Handler private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.Bounds; args.NextPage = tlr.Page; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Page Layout Event Handler Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.Bounds args.NextPage = tlr.Page End Sub Represents the method that will handle an event, once completed the text lay outing on the page. // Create a PDF document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); private bool m_paginateStart = true; PdfSolidBrush brush = new PdfSolidBrush(Color.Black); PdfPen pen = new PdfPen(Color.Black, 1f); //Creates a new pdf font PdfStandardFont pdfFont = new PdfStandardFont(PdfFontFamily.Helvetica, 11.5f); Font font = new Font("Calibri", 14f, FontStyle.Bold); PdfTrueTypeFont trueTypeFont = new PdfTrueTypeFont(font, true); string path = @"..\..\Data\Essential studio.txt"; StreamReader reader = new StreamReader(path, Encoding.ASCII); string text = reader.ReadToEnd(); reader.Close(); RectangleF column = new RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height); //Create text element PdfTextElement element = new PdfTextElement(text, pdfFont); element.Brush = new PdfSolidBrush(Color.Black); PdfLayoutFormat layoutFormat = new PdfLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Raise the event when the text flows to next page. element.BeginPageLayout += new BeginPageLayoutEventHandler(BeginPageLayout2); //Get the remaining text that flows beyond the boundary. PdfTextLayoutResult result = element.Draw(page, column, layoutFormat); //Saves the document. doc.Save("Sample.pdf"); //End Text Page Layout Event Handler private void EndPageLayout2(object sender, EndPageLayoutEventArgs e) { EndTextPageLayoutEventArgs args = (EndTextPageLayoutEventArgs)e; PdfTextLayoutResult tlr = args.Result; RectangleF bounds = tlr.Bounds; args.NextPage = tlr.Page; } 'Create a PDF document Dim doc As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim m_paginateStart As Bool= True Dim brush As New PdfSolidBrush(Color.Black) Dim pen As New PdfPen(Color.Black, 1f) 'Creates a new pdf font Dim pdfFont As New PdfStandardFont(PdfFontFamily.Helvetica, 11.5f) Dim font As New Font("Calibri", 14f, FontStyle.Bold) Dim trueTypeFont As New PdfTrueTypeFont(font, True) Dim path As string = "..\..\..\..\..\..\..\..\..\Common\Data\PDF\Essential studio.txt" Dim reader As New StreamReader(path, Encoding.ASCII) Dim text As string = reader.ReadToEnd() reader.Close() Dim column As New RectangleF(0, 20, page.Graphics.ClientSize.Width / 2f - 10f, page.Graphics.ClientSize.Height) 'Create text element Dim element As New PdfTextElement(text, pdfFont) element.Brush = New PdfSolidBrush(Color.Black) Dim layoutFormat As New PdfLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Raise the event when the text flows to next page. element.BeginPageLayout += New BeginPageLayoutEventHandler(BeginPageLayout2) 'Get the remaining text that flows beyond the boundary. Dim result As PdfTextLayoutResult = element.Draw(page, column, layoutFormat) 'Saves the document. doc.Save("Sample.pdf") 'End Text Page Layout Event Handler Private Sub EndPageLayout2(ByVal sender As object, ByVal e As EndPageLayoutEventArgs) Dim args As EndTextPageLayoutEventArgs = CType(e, EndTextPageLayoutEventArgs) Dim tlr As PdfTextLayoutResult = args.Result Dim bounds As RectangleF = tlr.Bounds args.NextPage = tlr.Page End Sub Specifies type of paginating. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) If the element exceeds the page, proceed it on the next page. Draw the element on the one page only. Specifies how the element should be contained on the page. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. for (int i = 20; i>0; i--) { dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); } //Assign data source. table.DataSource = dataTable; //Create new PDF layout format instance. PdfLayoutFormat format = new PdfLayoutFormat(); //Set page break. format.Break = PdfLayoutBreakType.FitPage; //Set layout type. format.Layout = PdfLayoutType.Paginate; //Set paginate bounds. format.PaginateBounds = new RectangleF(0, 0, 500, 350); //Draw grid to the page of PDF document. table.Draw(page, new RectangleF(0,0, 500, 700), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. For i As Integer = 20 To 1 Step -1 dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) Next 'Assign data source. table.DataSource = dataTable 'Create new PDF layout format instance. Dim format As New PdfLayoutFormat() 'Set page break. format.Break = PdfLayoutBreakType.FitPage 'Set layout type. format.Layout = PdfLayoutType.Paginate 'Set paginate bounds. format.PaginateBounds = New RectangleF(0, 0, 500, 350) 'Draw grid to the page of PDF document. table.Draw(page, New RectangleF(0, 0, 500, 700), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Fit the element according to the bounds specified or the page bounds. If the element doesn't fit at the first page, don't draw it on this page. Fit the columns withtin the page. A Class representing Pdf document which is used for Cid Font Descryptor Factory. Initializes a new instance of the class. The font family. The font style. The font metrics. Gets the system info. The font family. The properly formed dictionary. A Class representing Pdf document which is used for Cjk Font Descryptor Factory. Gets the font descryptor. The font family. The font style. The font metrics. font Descryptor Fills the monotype sung light font descryptor. The font descryptor. The font family. The font metrics. Fills the heisei kaku gothic w5 font descryptor. The font descryptor. The font style. The font family. The font metrics. Fills the hanyang systems shin myeong jo medium font descryptor. The font descryptor. The font family. The font metrics. Fills the heisei mincho w3 font descryptor. The font descryptor. The font family. The font metrics. Fills the sino type song light font descryptor. The font descryptor. The font family. The font metrics. Fills the monotype hei medium font descryptor. The font descryptor. The font family. The font metrics. Fills the hanyang systems gothic medium font descryptor. The font descryptor. The font family. The font metrics. Fills the known info. The font descryptor. The font family. The font metrics. Fills the flags. The font descryptor. The font family. Fills the font BBox. The font descryptor. The font BBox. Represents the standard CJK fonts. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the standard font. PdfFont font = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20); //Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the standard font. Dim font As PdfFont = New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20) 'Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Defines a particular format for text, including font face, size, and style attributes. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Multiplier of the symbol width. Synchronization object. Size of the font. Style of the font. Metrics of the font. PDf primitive of the font. Ascent value of the Font Initializes a new instance of the class. The size. Initializes a new instance of the class. The size. The style. Measures a string by using this font. String to measure. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); string text = "Hello World!"; //Measure the text. SizeF size = font.MeasureString(text); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim text As String = "Hello World!" 'Measure the text. Dim size As SizeF = font.MeasureString(text) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. PdfStringFormat that represents formatting information, such as line spacing, for the string. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; //Measure the text. SizeF size = font.MeasureString(text, format); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" 'Measure the text. Dim size As SizeF = font.MeasureString(text, format) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. PdfStringFormat that represents formatting information, such as line spacing, for the string. Number of characters in the string. Number of text lines in the string. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; int charactersFilled, linesFilled; //Measure the text. SizeF size = font.MeasureString(text, format , out charactersFilled, linesFilled); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" Dim charactersFilled As Integer, linesFilled As Integer 'Measure the text. Dim size As SizeF = font.MeasureString(text, format, charactersFilled, linesFilled) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. Maximum width of the string in points. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; //Measure the text. SizeF size = font.MeasureString(text, 100); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" 'Measure the text. Dim size As SizeF = font.MeasureString(text, 100) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. Maximum width of the string in points. PdfStringFormat that represents formatting information, such as line spacing, for the string. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; //Measure the text. SizeF size = font.MeasureString(text, 100, format); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" 'Measure the text. Dim size As SizeF = font.MeasureString(text, 100, format) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. Maximum width of the string in points. PdfStringFormat that represents formatting information, such as line spacing, for the string. Number of characters in the string. Number of text lines in the string. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; int charactersFilled, linesFilled; //Measure the text. SizeF size = font.MeasureString(text, format, 100, out charactersFilled, linesFilled); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" Dim charactersFilled As Integer, linesFilled As Integer 'Measure the text. Dim size As SizeF = font.MeasureString(text, 100, format, charactersFilled, linesFilled) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. SizeF structure that specifies the maximum layout area for the text in points. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; //Measure the text. SizeF size = font.MeasureString(text, new SizeF(100,100)); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" 'Measure the text. Dim size As SizeF = font.MeasureString(text, New SizeF(100,100)) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. SizeF structure that specifies the maximum layout area for the text in points. PdfStringFormat that represents formatting information, such as line spacing, for the string. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; //Measure the text. SizeF size = font.MeasureString(text, new SizeF(100,100) , format); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" 'Measure the text. Dim size As SizeF = font.MeasureString(text, New SizeF(100,100), format) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font. String to measure. SizeF structure that specifies the maximum layout area for the text in points. PdfStringFormat that represents formatting information, such as line spacing, for the string. Number of characters in the string. Number of text lines in the string. Size of the text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); PdfStringFormat format = new Syncfusion.Pdf.Graphics.PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; format.LineAlignment = PdfVerticalAlignment.Middle; string text = "Hello World!"; int charactersFilled, linesFilled; //Measure the text. SizeF size = font.MeasureString(text, new SizeF(100, 100), format , out charactersFilled, linesFilled); //Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, new RectangleF(PointF.Empty, size), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) Dim format As PdfStringFormat = New Syncfusion.Pdf.Graphics.PdfStringFormat() format.Alignment = PdfTextAlignment.Center format.LineAlignment = PdfVerticalAlignment.Middle Dim text As String = "Hello World!" Dim charactersFilled As Integer, linesFilled As Integer 'Measure the text. Dim size As SizeF = font.MeasureString(text, New SizeF(100,100), format, charactersFilled, linesFilled) 'Draw string to PDF page. graphics.DrawString(text, font, PdfBrushes.Black, New RectangleF(PointF.Empty, size), format) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Measures a string by using this font and it returns layout result. Checks whether the object is similar to another object. The object to compare with the current object. True - if the objects have equal internals and can share them, False otherwise. Returns internals of the object. Returns internals of the object. Sets internals to the object. Internals of the object. Checks whether fonts are equals. Font to compare. True if fonts are equal, False otherwise. Returns width of the char. Char symbol. String format. Width of the symbol. Returns width of the line. Text line. String format. Width of the line. Sets the style. The style. Applies settings to the default line width. Text line. String format. Default line width. Line width with settings applied. Gets the face name of this Font. A string representation of the face name of this . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets the size of this font. The em-size of this Font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets the height of the font in points. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets the style information for this font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets a value indicating whether this is bold. true if bold; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); builder.AppendLine("Bold: " + font.Bold.ToString()); builder.AppendLine("Italic: " + font.Italic.ToString()); builder.AppendLine("Underline: " + font.Underline.ToString()); builder.AppendLine("Strikeout: " + font.Strikeout.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) builder.AppendLine("Bold: " + font.Bold.ToString()) builder.AppendLine("Italic: " + font.Italic.ToString()) builder.AppendLine("Underline: " + font.Underline.ToString()) builder.AppendLine("Strikeout: " + font.Strikeout.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets a value indicating whether this has the italic style applied. true if italic; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); builder.AppendLine("Bold: " + font.Bold.ToString()); builder.AppendLine("Italic: " + font.Italic.ToString()); builder.AppendLine("Underline: " + font.Underline.ToString()); builder.AppendLine("Strikeout: " + font.Strikeout.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) builder.AppendLine("Bold: " + font.Bold.ToString()) builder.AppendLine("Italic: " + font.Italic.ToString()) builder.AppendLine("Underline: " + font.Underline.ToString()) builder.AppendLine("Strikeout: " + font.Strikeout.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets a value indicating whether this is strikeout. true if strikeout; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); builder.AppendLine("Bold: " + font.Bold.ToString()); builder.AppendLine("Italic: " + font.Italic.ToString()); builder.AppendLine("Underline: " + font.Underline.ToString()); builder.AppendLine("Strikeout: " + font.Strikeout.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) builder.AppendLine("Bold: " + font.Bold.ToString()) builder.AppendLine("Italic: " + font.Italic.ToString()) builder.AppendLine("Underline: " + font.Underline.ToString()) builder.AppendLine("Strikeout: " + font.Strikeout.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets a value indicating whether this is underline. true if underline; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Get font Name. string fontName = font.Name; //Get font size. float fontSize = font.Size; //Get font height. float fontHeight = font.Height; //Get the font style. PdfFontStyle style = font.Style; StringBuilder builder = new StringBuilder(); builder.AppendLine("Font Name: " + fontName); builder.AppendLine("Font Size: " + fontSize); builder.AppendLine("Font Height: " + FontHeight); builder.AppendLine("Font Style: " + style.ToString()); builder.AppendLine("Bold: " + font.Bold.ToString()); builder.AppendLine("Italic: " + font.Italic.ToString()); builder.AppendLine("Underline: " + font.Underline.ToString()); builder.AppendLine("Strikeout: " + font.Strikeout.ToString()); //Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Get font Name. Dim fontName As String = font.Name 'Get font size. Dim fontSize As Single = font.Size 'Get font height. Dim fontHeight As Single = font.Height 'Get the font style. Dim style As PdfFontStyle = font.Style Dim builder As New StringBuilder() builder.AppendLine("Font Name: " + fontName) builder.AppendLine("Font Size: " + fontSize) builder.AppendLine("Font Height: " + fontHeight) builder.AppendLine("Font Style: " + style.ToString()) builder.AppendLine("Bold: " + font.Bold.ToString()) builder.AppendLine("Italic: " + font.Italic.ToString()) builder.AppendLine("Underline: " + font.Underline.ToString()) builder.AppendLine("Strikeout: " + font.Strikeout.ToString()) 'Draw string to PDF page. graphics.DrawString(builder.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the metrics for this font. Gets or sets the ascent value Gets Pdf primitive representing the font. First character position. Font family Initializes a new instance of the class with the specified , size and style The font family. The size. The style. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the standard font. PdfFont font = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20, PdfFontStyle.Bold); //Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the standard font. Dim font As PdfFont = New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20, PdfFontStyle.Bold) 'Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with the specified and size The font family. The size. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the standard font. PdfFont font = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20); //Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the standard font. Dim font As PdfFont = New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20) 'Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with the specified and size The prototype. The size. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the standard font. PdfCjkStandardFont cjkFont = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20); //Create PDF cjk font. PdfFont font = new PdfCjkStandardFont(cjkFont, 20); //Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the standard font. Dim cjkFont As New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20) 'Create PDF cjk font. Dim font As PdfFont = New PdfCjkStandardFont(cjkFont, 20) 'Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with the specified , size and style The prototype. The size. The style. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the standard font. PdfCjkStandardFont cjkFont = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20, PdfFontStyle.Bold); //Create PDF cjk font. PdfFont font = new PdfCjkStandardFont(cjkFont, 20); //Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the standard font. Dim cjkFont As New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20, PdfFontStyle.Bold) 'Create PDF cjk font. Dim font As PdfFont = New PdfCjkStandardFont(cjkFont, 20) 'Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Checks whether fonts are equals. Font to compare. True if fonts are equal, False otherwise. Returns width of the char. Char symbol. String format. Width of the symbol. Returns width of the line. Text line. String format. Width of the line. Initializes the internals. Creates font's dictionary. font's dictionary. Returns descendant font. Returns descendant font. Gets the prope CJK encoding. The font family. Proper PDF name for the encoding. Checks the style. Gets the char width internal. The character code. The format. The width of the character. Gets the CJK font family. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create new PDF cjk font. PdfCjkStandardFont font = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20, PdfFontStyle.Bold); //Draw the text. graphics.DrawString("The CJK font family name is " + font.FontFamily.ToString(), font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create new PDF cjk font. Dim font As New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20, PdfFontStyle.Bold) 'Draw the text. graphics.DrawString("The CJK font family name is " + font.FontFamily.ToString(), font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) A Class representing Pdf document which is used for Cjk Font Metrics Factory. Multiplier of subscript superscript. Initializes a new instance of the class. Returns font metrics depending on the font settings. Font family. Font style. Size of the font. Returns font metrics depending on the font settings. Gets the hanyang systems gothic medium font metrix. The font family. The font style. The size. The filled font metrix. Gets the monotype hei medium metrix. The font family. The font style. The size. The proper PdfFontMetrics class instance. Gets the monotype sung light metrix. The font family. The font style. The size. The proper PdfFontMetrics class instance. Gets the sino type song light font metrics. The font family. The font style. The size. PdfFontMetrics instance. Gets the heisei mincho w3. The font family. The font style. The size. The proper PdfFontMetrics class instance. Gets the heisei kaku gothic w5 metrix. The font family. The font style. The size. The proper PdfFontMetrics class instance. Gets the hanyang systems shin myeong jo medium metrix. The font family. The font style. The size. The proper PdfFontMetrics class instance. Metrics of the font. Gets ascent of the font. Gets descent of the font. Name of the font. Gets PostScript Name of the font. Gets size of the font. Gets height of the font. First char of the font. Last char of the font. Line gap. Subscript size factor. Superscript size factor. Gets table of glyphs' width. Indicate whether the ttfreader font has bold style. Returns ascent taking into consideration font's size. Text format settings. Returns ascent taking into consideration font's size. Returns descent taking into consideration font's size. Text format settings. Returns descent taking into consideration font's size. Returns Line gap taking into consideration font's size. Text format settings. Returns line gap taking into consideration font's size. Returns height taking into consideration font's size. Text format settings. Returns height taking into consideration font's size. Calculates size of the font depending on the subscript/superscript value. Text format settings. Size of the font depending on the subscript/superscript value. Clones the metrics. Cloned metrics. Gets or sets the width table. The base class for a width table. Clones this instance of the WidthTable class. A copy of this WidthTable instance. Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. Toes the array. Gets the at the specified index. index Implements a width table for standard fonts. The widths of the supported characters. Initializes a new instance of the class. The widths table. Clones this instance of the WidthTable class. A copy of this WidthTable instance. Converts width table to a PDF array. The properly formed pdf array. Gets the at the specified index. index Gets the length of the internal array. Implements CJK width table, which is quite complex. Local variable to store the width. Local variable to store the default width. Initializes a new instance of the class. The default width of the CJK characters. This value will be returned if there is no width information for a character. Adds the specified widths. The CJK widths. Clones this instance of the WidthTable class. A copy of this WidthTable instance. Converts width table to a PDF array. A well formed PDF array. Gets the default character width. Gets the at the specified index. index The base class of CJK widths types. Appends internal data to a PDF array. The pdf array. Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. Clones this instance. The proper copy of this instance. Gets the starting character. Gets the ending character. Gets the width of the specified character. Implements capabilities to control a range of character with the same width. The Form The to The Width Initializes a new instance of the class. From. To. The width. Appends internal data to a PDF array. The pdf array. Clones this instance. The proper copy of this instance. Gets the starting character. Gets the ending character. Gets the width of the specified character. Implements capabilities to control a sequent range of characters with different width. The form The width Initializes a new instance of the class. From. The widths. Appends internal data to a PDF array. The pdf array. Clones this instance. The proper copy of this instance. Gets the starting character. Gets the ending character. Gets the width of the specified character. Represents one of the 14 standard PDF fonts. It's used to create a standard PDF font to draw the text in to the PDF //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) First character position. FontFamily of the font. Initializes a new instance of the class with font family and it's size The font family. The size of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with font family, size and font style The font family. The size of the font. The style of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with as prototype and font size The using as prototype. The size of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(new PdfStandardFont(PdfFontFamily.Helvetica,12), 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(New PdfStandardFont(PdfFontFamily.Helvetica,12), 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with as prototype,font size and font style The using as prototype.. The size of the font. The style of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(new PdfStandardFont(PdfFontFamily.Helvetica,12), 12, PdfFontStyle.Bold); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(New PdfStandardFont(PdfFontFamily.Helvetica,12), 12, PdfFontStyle.Bold) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection. Sets the text encoding in PdfFont Supported text encoding code page numbers 37, 437, 500, 708, 720,737,775,850, 852,855,857,858,860,861,862, 863,864,865, 866,869,870, 875,1026,1047, 1140,1141,1142,1143,1144,1145, 1146,1147, 1148,1149,1250,1251,1252,1253,1254,1255,1256,1257,1258,20280,20420,20273,20277,20278,20280,20284,20285,20297,20420,20423,20424,20866, 20871,20880,20905,20924 //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Set the text encoding font.SetTextEncoding(Encoding.GetEncoding("Windows-1250")); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Set the text encoding font.SetTextEncoding(Encoding.GetEncoding("Windows-1250")) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Returns the width of the char. Char symbol. String format. Width of the symbol. Returns width of the line. Text line. String format. Width of the line. Checks whether fonts are equals. Font to compare. True if fonts are equal, False otherwise. Initializes font internals. Initializes font internals. Creates font's dictionary. font's dictionary. Update Standrad Font Width Table Save custom encoding differences Checks font style of the font. Returns width of the char. This methods doesn't takes into consideration font's size. Char symbol. String format. Width of the symbol. Converts the specified text. The unicode text. The ANSI string. Converts the specified text. The unicode text. The encoded string. Gets the FontFamily. The //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draw string to PDF page. graphics.DrawString(font.FontFamily.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draw string to PDF page. graphics.DrawString(font.FontFamily.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Adobe Glyph list Get Width Table Factory of the standard fonts metrics. Multiplier os subscript superscript. Ascender value for the font. Ascender value for the font. Font type Ascender value for the font. Ascender value for the font. Font type Ascender value for the font. Ascender value for the font. Font type Ascender value for the font. Ascender value for the font. Font type Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Ascender value for the font. Ascender value for the font. Font type. Arial widths table. Arial bold widths table. Fixed widths table. Times widths table. Times bold widths table. Times italic widths table. Times bold italic widths table. Symbol widths table. Zip dingbats widths table. Initializes a new instance of the class. Returns metrics of the font. Family of the font. Style of the font. Size of the font. Returns metrics of the font. Creates Helvetica font metrics. FontFamily of the font. Style of the font. Size of the font. Helvetica font metrics. Creates Courier font metrics. FontFamily of the font. Style of the font. Size of the font. Helvetica font metrics. Creates Times font metrics. FontFamily of the font. Style of the font. Size of the font. Helvetica font metrics. Creates Symbol font metrics. FontFamily of the font. Style of the font. Size of the font. Helvetica font metrics. Creates ZapfDingbats font metrics. FontFamily of the font. Style of the font. Size of the font. Helvetica font metrics. Represents the text layout information on PDF //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Horizontal text alignment. Vertical text alignment. Indicates whether RTL should be checked. Character spacing value. Word spacing value. Text leading. Shows if the text should be a part of the current clipping path. Indicates whether the text is in subscript or superscript mode. The scaling factor of the text being drawn. Indent of the first line in the text. Indent of the first line in the paragraph. Indicates whether entire lines are laid out in the formatting rectangle only or not. Indicates whether spaces at the end of the line should be left or removed. Indicates whether the text region should be clipped or not. Indicates text wrapping type. Indicates whether the text layout is complex script. Indicates line baseline Initializes a new instance of the class. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with horizontal alignment of a text The represents the horizontal alignment of a text in PDF . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(PdfTextAlignment.Center); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat(PdfTextAlignment.Center) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with column format The column format. Initializes a new instance of the class with horizontal and vertical alignment The represents the horizontal alignment of a text in PDF . The represents the vertical alignment of a text in PDF //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(PdfTextAlignment.Center, PdfVerticalAlignment.Middle); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat(PdfTextAlignment.Center, PdfVerticalAlignment.Middle) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Clones the object. The new created object. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Clone the string format. PdfStringFormat format1 = format.Clone() as PdfStringFormat; 'Create a new PDF string format instance. Dim format As New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle 'Clone the string format. Dim format1 As PdfStringFormat = TryCast(format.Clone(), PdfStringFormat) Gets or sets the value that indicates text direction. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; format.TextDirection = PdfTextDirection.RightToLeft; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set right to left. format.TextDirection = PdfTextDirection.RightToLeft 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the complex text layout rendering. Gets or sets the horizontal text alignment The represents the horizontal alignment of a text in PDF Default value: PdfTextAlignment.Left //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the vertical text alignment. The represents the vertical alignment of a text in PDF Default Value: PdfVerticalAlignment.Top //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the baseline for line alignment. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfTrueTypeFont(new Font("Tahoma",8), 8); PdfFont font1 = new PdfTrueTypeFont(new Font("Calibri",20), 20); PdfFont font2 = new PdfStandardFont(PdfFontFamily.Helvetica,16); PdfFont font3 = new PdfTrueTypeFont(new Font("Arial",25), 25); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Bottom; //Set baseline for line alignment format.EnableBaseline = true; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new PointF(0, 50), format); graphics.DrawString("Hello World!", font1, PdfBrushes.Black, new PointF(65, 50), format); graphics.DrawString("Hello World!", font2, PdfBrushes.Black, new PointF(220, 50), format); graphics.DrawString("Hello World!", font3, PdfBrushes.Black, new PointF(320, 50), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfTrueTypeFont(new Font("Tahoma",8), 8); Dim font1 As PdfFont = New PdfTrueTypeFont(new Font("Calibri",20), 20); Dim font2 As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica,16); Dim font3 As PdfFont = New PdfTrueTypeFont(new Font("Arial",25), 25); 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Bottom; 'Set baseline for line alignment format.EnableBaseline = true; 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New PointF(0, 50), format); graphics.DrawString("Hello World!", font1, PdfBrushes.Black, New PointF(65, 50), format); graphics.DrawString("Hello World!", font2, PdfBrushes.Black, New PointF(220, 50), format); graphics.DrawString("Hello World!", font3, PdfBrushes.Black, New PointF(320, 50), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the value that indicates text direction mode. true if RightToLeft; otherwise, false. Note, that this property doesn't change any alignment of the text. property should be set manually to align the text. This property just enables or disables support of right to left approach. If the value is False, the text won't be checked for right to left symbols occurrence. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; format.RightToLeft = false; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set right to left. format.RightToLeft = False 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets value that indicates a size among the characters in the text. When the glyph for each character in the string is rendered, this value is added to the glyph�s displacement. Default value is 0. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets value that indicates a size among the words in the text. Word spacing works the same way as character spacing but applies only to the space character, code 32. Default value is 0. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set word spacing. format.WordSpacing = 1.5f; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set word spacing. format.WordSpacing = 1.5F 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets value that indicates the vertical distance between the baselines of adjacent lines of text. Default value is 0. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set line spacing. format.LineSpacing = 1.1f; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set line spacing. format.LineSpacing = 1.1F 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets a value indicating whether the text should be a part of the clipping path. true if ClipPath; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Set clip path. format.ClipPath = true; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Set clip path. format.ClipPath = True 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets value indicating whether the text is in subscript or superscript mode. The indicating whether the text is in subscript or superscript mode //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the indent of the first line in the paragraph. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set paragraph indent. format.ParagraphIndent = 2.1f; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set paragraph indent. format.ParagraphIndent = 2.1F 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets a value indicating whether [line limit]. true if [line limit]; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Set clip path. format.ClipPath = true; //Set line limit. format.LineLimit = true; //Set line spacing. format.LineSpacing = 1.1f; //Set measure trailing spaces. format.MeasureTrailingSpaces = true; //Set no clip format.NoClip = true; //Set paragraph indent. format.ParagraphIndent = 2.1f; //Set right to left. format.RightToLeft = false; //Set word spacing. format.WordSpacing = 1.5f; //Set word wrap type. format.WordWrap = PdfWordWrapType.Word; //Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Set clip path. format.ClipPath = True 'Set line limit. format.LineLimit = True 'Set line spacing. format.LineSpacing = 1.1F 'Set measure trailing spaces. format.MeasureTrailingSpaces = True 'Set no clip format.NoClip = True 'Set paragraph indent. format.ParagraphIndent = 2.1F 'Set right to left. format.RightToLeft = False 'Set word spacing. format.WordSpacing = 1.5F 'Set word wrap type. format.WordWrap = PdfWordWrapType.Word 'Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets a value indicating whether [measure trailing spaces]. true if [measure trailing spaces]; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Set clip path. format.ClipPath = true; //Set line limit. format.LineLimit = true; //Set line spacing. format.LineSpacing = 1.1f; //Set measure trailing spaces. format.MeasureTrailingSpaces = true; //Set no clip format.NoClip = true; //Set paragraph indent. format.ParagraphIndent = 2.1f; //Set right to left. format.RightToLeft = false; //Set word spacing. format.WordSpacing = 1.5f; //Set word wrap type. format.WordWrap = PdfWordWrapType.Word; //Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Set clip path. format.ClipPath = True 'Set line limit. format.LineLimit = True 'Set line spacing. format.LineSpacing = 1.1F 'Set measure trailing spaces. format.MeasureTrailingSpaces = True 'Set no clip format.NoClip = True 'Set paragraph indent. format.ParagraphIndent = 2.1F 'Set right to left. format.RightToLeft = False 'Set word spacing. format.WordSpacing = 1.5F 'Set word wrap type. format.WordWrap = PdfWordWrapType.Word 'Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets a value indicating whether [no clip]. true if [no clip]; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Set clip path. format.ClipPath = true; //Set line limit. format.LineLimit = true; //Set line spacing. format.LineSpacing = 1.1f; //Set measure trailing spaces. format.MeasureTrailingSpaces = true; //Set no clip format.NoClip = true; //Set paragraph indent. format.ParagraphIndent = 2.1f; //Set right to left. format.RightToLeft = false; //Set word spacing. format.WordSpacing = 1.5f; //Set word wrap type. format.WordWrap = PdfWordWrapType.Word; //Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Set clip path. format.ClipPath = True 'Set line limit. format.LineLimit = True 'Set line spacing. format.LineSpacing = 1.1F 'Set measure trailing spaces. format.MeasureTrailingSpaces = True 'Set no clip format.NoClip = True 'Set paragraph indent. format.ParagraphIndent = 2.1F 'Set right to left. format.RightToLeft = False 'Set word spacing. format.WordSpacing = 1.5F 'Set word wrap type. format.WordWrap = PdfWordWrapType.Word 'Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets value indicating type of the text wrapping. The indicating type of the text wrapping //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Set clip path. format.ClipPath = true; //Set line limit. format.LineLimit = true; //Set line spacing. format.LineSpacing = 1.1f; //Set measure trailing spaces. format.MeasureTrailingSpaces = true; //Set no clip format.NoClip = true; //Set paragraph indent. format.ParagraphIndent = 2.1f; //Set right to left. format.RightToLeft = false; //Set word spacing. format.WordSpacing = 1.5f; //Set word wrap type. format.WordWrap = PdfWordWrapType.Word; //Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Set clip path. format.ClipPath = True 'Set line limit. format.LineLimit = True 'Set line spacing. format.LineSpacing = 1.1F 'Set measure trailing spaces. format.MeasureTrailingSpaces = True 'Set no clip format.NoClip = True 'Set paragraph indent. format.ParagraphIndent = 2.1F 'Set right to left. format.RightToLeft = False 'Set word spacing. format.WordSpacing = 1.5F 'Set word wrap type. format.WordWrap = PdfWordWrapType.Word 'Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets or sets the scaling factor. The default scaling factor is 100, which means 100% and original size. It's used to make PDF font looking smaller when metafile is rendered into PDF. Gets or sets the indent of the first line in the text. Represents TrueType font. [System.Security.Permissions.PermissionSet( System.Security.Permissions.SecurityAction.Assert, Name = "FullTrust" )] //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create new system font. Font sFont = new Font("Arial", 12, FontStyle.Regular); //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(sFont); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create new system font. Dim sFont As New Font("Arial", 12, FontStyle.Regular) 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(sFont) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Code page for the encoding. Encoding for the font. Create Instance of the rtl render lock. Indicates whether the font should be embeded. Indicates whether the font should use unicode symbols. Internal font object. used to store style of the font Indicates whether the font embeding is enabled or disabled . Initializes a new instance of the class with specified Font The system font that defines the text format of the string This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create new system font. Font sFont = new Font("Arial", 12, FontStyle.Regular); //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(sFont); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create new system font. Dim sFont As New Font("Arial", 12, FontStyle.Regular) 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(sFont) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with font and Boolean flag to set the Unicode of the PDF font This Constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The system font that defines the text format of the string The boolean flag represents the support of unicode text //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a truetype font PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14),true); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a truetype font Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14), True) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The system font that defines the text format of the string The boolean flag represents the support of unicode text Initializes a new instance of the class with font and it's size This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The system font that defines the text format of the string The size of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create new system font. Font sFont = new Font("Arial", 12, FontStyle.Regular); //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(sFont, 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create new system font. Dim sFont As New Font("Arial", 12, FontStyle.Regular) 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(sFont, 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with font, size and Boolean flag to set Unicode. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The system font that defines the text format of the string The size of the font. The boolean flag represents the support of unicode text //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a truetype font PdfFont font = new PdfTrueTypeFont(new Font("Arial", 14),12,true); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a truetype font Dim font As PdfFont = New PdfTrueTypeFont(New Font("Arial", 14), 12, True) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) This constructor is specific for removing font from cach collection. This constructor is specific for removing font from cach collection. Initializes a new instance of the class with font,font style,size,Boolean flag to set Unicode and Boolean flag to embed the font into the PDF This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The system font that defines the text format of the string The style of the font. The size of the font. The boolean flag represents the support of unicode text The boolean flag represents to embed the font into the pdf //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create new system font. Font sFont = new Font("Arial", 12, FontStyle.Regular); //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(sFont, FontStyle.Regular, 12, true, true); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create new system font. Dim sFont As New Font("Arial", 12, FontStyle.Regular) 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(sFont, FontStyle.Regular, 12, True, True) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class with the path of the font file which has the extension of .ttf and it's size This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The font file path which has the extension of .ttf. The size of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont("arial.ttf", 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont("arial.ttf", 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The font file path which has the extension of .ttf The size of the font. Type of the is true. Initializes a new instance of the class with the path of the font file which has the extension of .ttf, size and font style This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The font file path. The size of the font. The style of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont("arial.ttf", 12, PdfFontStyle.Regular); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont("arial.ttf", 12, PdfFontStyle.Regular) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The font file. The size. The style. Initializes a new instance of the class. The font file. The size. The style. Initializes a new instance of the class. Font Stream. Size of the font. Initializes a new instance of the class. The font stream. The size of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Read a font file stream. Stream fontStream = new MemoryStream(File.ReadAllBytes("arial.ttf")); //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(fontStream, 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Read a font file stream. Dim fontStream As Stream = New MemoryStream(File.ReadAllBytes("arial.ttf")) 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(fontStream, 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The font file. The size. The style. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Read a font file stream. Stream fontStream = new MemoryStream(File.ReadAllBytes("arial.ttf")); //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(fontStream, 12, PdfFontStyle.Regular); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Read a font file stream. Dim fontStream As Stream = New MemoryStream(File.ReadAllBytes("arial.ttf")) 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(fontStream, 12, PdfFontStyle.Regular) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The font file. Embedded. The style. The size. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Read a font file stream. Stream fontStream = new MemoryStream(File.ReadAllBytes("arial.ttf")); //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(fontStream, false, PdfFontStyle.Regular, 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Read a font file stream. Dim fontStream As Stream = New MemoryStream(File.ReadAllBytes("arial.ttf")) 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(fontStream, false, PdfFontStyle.Regular, 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The font file. The size. The style. Embedding. Initialize this constructor to avoid embedding fonts. Initializes a new instance of the class. Font Stream. Size of the font. Style of the font. Embedding. Initializes a new instance of the class with prototype and it's size The PdfTrutypeFont using as a prototype. The size of the font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF true type font instance. PdfFont font = new PdfTrueTypeFont(new PdfTrueTypeFont(new Font("Arial",12,FontStyle.Regular)), 12); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF true type font instance. Dim font As PdfFont = New PdfTrueTypeFont(New PdfTrueTypeFont(New Font("Arial",12,FontStyle.Regular)), 12) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The prototype. The size. Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection. Releases all resources of the font. Don't dispose the font until the corresponding document is closed. Returns width of the char. Char symbol. String format. Width of the symbol. Returns width of the line. Text line. String format. Width of the line. Checks whether fonts are equals. Font to compare. True if fonts are equal, False otherwise. Stores used symbols. String text. Stores used symbols. Glyphs, used by the line of the text. Creates internal font object. System font. Creates internal font object. Font file. Suggested style of the font. Creates a new font from a prototype font. Prototype object. Creates internal font object. Font file. Suggested style of the font. Initializes font internals. Sets the style of the font. Suggested style of the font. Calculates size of the symbol. Symbol. String format. Symbol size. Calcuates width of the unicode line. String text. Width of the line. True if success, false otherwise. Gets a value indicating whether this is Unicode enabled (Read only). true if Unicode; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create new system font. Font sFont = new Font("Arial", 12, FontStyle.Regular); //Create a new PDF true type font instance. PdfTrueTypeFont font = new PdfTrueTypeFont(sFont, 12, true); //Check unicode support. bool isUnicode = font.Unicode; //Draw string to PDF page. graphics.DrawString("Unicode Font = " + isUnicode, font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create new system font. Dim sFont As New Font("Arial", 12, FontStyle.Regular) 'Create a new PDF true type font instance. Dim font As PdfTrueTypeFont = New PdfTrueTypeFont(sFont, 12, True) 'Check unicode support. Dim isUnicode As Boolean = font.Unicode 'Draw string to PDF page. graphics.DrawString("Unicode Font = " + isUnicode, font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Gets a value indicating whether this is embeded it to the PDF document true if embeded; otherwise, false. Gets internals of the font. Gets font object of this font. Gets path to the font file if the font was created from a file. The Syncfusion.Pdf.Graphics.Fonts namespace contains classes for retrieving used fonts in existing PDF documents. Initializes a new instance of the class. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The font. The existing PDF page //Load the existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Create a new PDF font object. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create new PDF used font object. PdfUsedFont usedFont = new PdfUsedFont(font, ldoc.Pages[0] as PdfLoadedPage); //Get the used font name. string name = usedFont.Name; //Get the used font type. PdfFontType fontType = usedFont.Type; //Close the document. ldoc.Close(true); 'Load the existing PDF document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Create a new PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create a new PDF used font object. Dim usedFont As PdfUsedFont = New PdfUsedFont(font, CType(ldoc.Pages(0), PdfLoadedPage)) 'Get the used font name. Dim name As String = usedFont.Name 'Get the used font style. Dim fontType As PdfFontType = usedFont.Type 'Close the document. ldoc.Close(True) Replaces the specified new font. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The newFont to be replaced the existing font. //Load the existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Load the existing used fonts. PdfUsedFont[] usedFonts = ldoc.UsedFonts; //Get the used font to be replaced. PdfUsedFont usedFont = usedFonts[0]; //Create a new font to be replace. PdfFont newFont = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Repace the existing font. usedFont.Replace(newFont); //Save the document. ldoc.Save("output.pdf"); //Close the document. ldoc.Close(true); 'Load the existing PDF document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Load the existing used fonts. Dim usedFonts() As PdfUsedFont = ldoc.UsedFonts 'Get the used font to be replaced. Dim usedFont As PdfUsedFont = usedFonts(0) 'Create a new font to be replace. Dim newFont As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Repace the existing font. usedFont.Replace(newFont) 'Save the document. ldoc.Save("output.pdf") 'Close the document. ldoc.Close(True) Initializes the internals. The font. Gets the actual name of the font. Checks the preambula. Gets the internal font. The internal font. Gets the name. The name. //Load the existing PDF document PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Get the use fonts. PdfUsedFont[] fonts = ldoc.UsedFonts; //Get the used font name string fontName = fonts[0].Name; //Close the document. ldoc.Close(true); 'Load the existing PDF document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the use fonts. Dim fonts() As PdfUsedFont = ldoc.UsedFonts 'Get the used font name Dim fontName As String = fonts(0).Name 'Close the document. ldoc.Close(True) Gets the size. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The size. //Load the existing PDF document PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Get the use fonts. PdfUsedFont[] fonts = ldoc.UsedFonts; //Get the used font size float fontSize = fonts[0].Size; //Close the document. ldoc.Close(true); 'Load the existing PDF document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the use fonts. Dim fonts() As PdfUsedFont = ldoc.UsedFonts 'Get the used font size Dim fontSize As Single = fonts(0).Size 'Close the document. ldoc.Close(True) Gets the style. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The style. //Load the existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Get the use fonts. PdfUsedFont[] fonts = ldoc.UsedFonts; //Get the used font style. PdfFontStyle fontStyle = fonts[0].Style; //Close the document. ldoc.Close(true); 'Load the existing PDF document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the use fonts. Dim fonts() As PdfUsedFont = ldoc.UsedFonts 'Get the used font style Dim fontStyle As PdfFontStyle = fonts(0).Style 'Close the document. ldoc.Close(True) Gets the type. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The type. //Load the existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Get the use fonts. PdfUsedFont[] fonts = ldoc.UsedFonts; //Get the used font type. PdfFontType fontType = fonts[0].Type; //Close the document. ldoc.Close(true); 'Load the existing PDF document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the use fonts. Dim fonts() As PdfUsedFont = ldoc.UsedFonts 'Get the used font type Dim fontType As PdfFontType = fonts(0).Type 'Close the document. ldoc.Close(True) Gets the actual name of the font. The actual name of the font. Renderers text and layouts it for RTL support. Open bracket symbol. Close bracket symbol. Bitmap used for text shaping. Initializes a new instance of the class. Layouts text. Changes blocks position in the RTL text. Ligates the text if needed. Line of the text. Font to be used for string printing. Font alignment. Indicates whether Word Spacing used or not. Layout string. Layouts a string and splits it by the words and using correct lay outing. Text line. Font object. Indicates whether RTL should be applied. Indicates whether word spacing is used. Array of words if converted, null otherwise. Determines whether the specified word is english. The word. true if the specified word is english; otherwise, false. Copies words remaining their order. The words. The start index. The number of the words. The resulting array. Index of the result. Uses system API to layout the text. Line of the text to be layouted. Font which is used for text printing. Indicates whether we use RTL or RTL lay outing of the text container. If true - word spacing is used. Layout string. Uses system API to layout the text. Line of the text to be layouted. Font which is used for text printing. Indicates whether we use RTL or RTL lay outing of the text container. Layout string. Uses manual algorithm for text lay outing. Line of the text to be layouted. Font which is used for text printing. Indicates whether we use RTL or RTL lay outing of the text container. If true - word spacing is used. layout string array. Trim LRM characters Uses manual algorithm for text lay outing. Line of the text to be layouted. Indicates whether we use RTL or LTR layouting of the text container. layout string. Reverses the words if they're RTL. The words. The reversed words. Keep English words in original order. Retrieves array of glyph indices. Line of the text. Current font. Indicates whether we use RTL or RTL lay outing of the text container. Array of glyph indices. True - if succeed, False otherwise. Breaks string to the blocks of the runs. String to be itemized. Indicates whether text container is in RTL form or not. Array describing each run. Count of the runs in the string. True - if operation succeed, False otherwise. Renders each run from the string. Input string text. Run descriptors. Font to be used for text printing. Count of the significant runs in the array. Visual to logical order of the runs. Resulting glyphs for the specified font. True - if operation succeed, False otherwise. Layouts the runs in the visual form. Bidi array of the runs. Count of the runs. Pointer to an array that receives the run levels reordered to visual order. Pointer to an array that receives the visual run positions. True - if succeed, False otherwise. Adds glyphs to the array. Array of the glyphs. Contains glyphs. Count of the glyphs. Gets bidi level for the runs. Runs desciprtors. Count of the runs Bidi level array. Add information about used glyphs to the font. Font used for text rendering. Array of used glyphs. String in the form to be written to the file. Add information about used glyphs to the font. Font used for text rendering. Line of the text. String in the form to be written to the file. Layouts a string and splits it by the words by using system lay outing. Text line. Font object. Indicates whether RTL should be applied. Indicates whether word spacing is used. Array of words if converted, null otherwise. Converts string data to RtL format if data contain any RtL symbols. Text data being converted. Converted data. Converts string data to LtR format if data contain any RtL symbols. Text data being converted. Converted data. Checks if current symbol is euro number. Array of elements types. Index of current symbol. True - if current symbol is euro number, False otherwise. Checks if current symbol is euro number. Array of elements types. Index of current symbol. True - if current symbol is euro number, False otherwise. Presevres symbol fro source string data and saves it to new string data. Array of new resulting data. Current processing symbol. Indicates if we process text in RTL or not. Index of current symbol. Length of symbols group. Checks if array of flags contains at least on RTL symbol. Array of flags. True if array of flags contains at least on RTL symbol, False otherwise. Formats text which is writing from left to right. Array of symbols. Current symbol. Indicates if we process text in RTL or not. Index of current symbol. Length of symbols group. Reverses brackets in the text. Array of symbols. Current symbol. Index of current symbol. Length of symbols group. Checks if symbol code is LTR text. Symbol code. True - if symbol code is LTR text, False othervise. Checks if symbol code is RTL text or number. Symbol code. True - if symbol code is RTL text or number, False othervise. Checks if symbol code is RTL text. Symbol code. True - if symbol code is RTL text, False othervise. Checks if symbol code is euro number with separators. Symbol code. True - if symbol code is euro number with separators, False othervise. Checks if symbol code is euro number. Symbol code. True - if symbol code is euro number, False othervise. Checks if symbol code has euro terminator format. Symbol code. True - if symbol code has euro terminator format, False othervise. Checks if symbol code is whitespace. Symbol code. True - if symbol code is whitespace, False othervise. Checks if symbol is bracket. Symbol code. True - if symbol is bracket, False othervise. Layouts a string and splits it by the words by using custom lay outing. Text line. Font object. Indicates whether RTL should be applied. Indicates whether word spacing is used. Array of words if converted, null otherwise. Class lay outing the text. Text data. Pdf font. String format. Bounds of the text. String tokenizer. Initializes a new instance of the class. Layouts the text. String text. Font for the text. String format. Bounds of the text. Page height of the text. Layout result. Layouts the text. String text. Font for the text. String format. Bounds of the text. Layout result. Initializes internal data. String text. Font for the text. String format. Bounds of the text. Layouts the text. Lay outing data. Copies layout result from line result to entire result. Checks whether we can proceed lay outing or not. Final result. Line result. Lines array. Number of symbols inserted. True if we can proceed, False - to stop lay outing. Finalizes final result. Final result. Lines array. Cleares all resources. Calculates height of the line. Height of the line. Layouts line. Text line. Line indent. Layout result. Adds line to line result. Line resut. Array of the lines. Text line. Line width. Line break type. Trims whitespaces at the line. Line info. Indicates whether the line is the first in the text. Trimed line info. Calculates width of the line. String line. Width of the line. Returns line indent for the line. If true - the line is the first in the text. Line indent for the line. Returns wrap type. Returns wrap type. Layouter result. Layouted lines. The text wasn't lay outed. Actual layouted text bounds. Height of the line. Gets the text which is not lay outed Gets the actual layouted text bounds Gets layouted lines information. Gets the height of the line. Gets value that indicates whether any text was layouted. Gets number of the lines layouted. Provides a line information Line text. Width of the text. Breaking type of the line. Gets the width of the line text. Gets the line text. Gets width of the line text. Break type of the line. Unknown type line. The line has new line symbol. layout break. The line is the first in the paragraph. The line is the last in the paragraph. Utility class for working with strings. Whitespace symbol. Whitespace symbol. Default RegEx checks object's options. Pattern for WhiteSpace. Array of spaces. Whitespace regex. Text data. Current position. Initializes a new instance of the class. The text. Returns number of symbols occurred in the text. Text data. Symbol to be searched. Number of symbols occurred in the text. Returns number of symbols occurred in the text. Text data. Array of symbols to be searched. Number of symbols occurred in the text. Reads line of the text. Text line. Reads line of the text. Text line. reads a word from the text. A word from the data. Peeks a word from the text. A word from the data. Reads char form the data. Char symbol. Reads count of the symbols. Number of symbols. String text. Reads data till the symbol. Specified symbol. If true - to read the symbol. The data read. Peeks char form the data. Char symbol. Closes a reader. Reads text to the end. Reads text to the end. Indicates whether user specified token is whitespace symbols or not. Token to check. True if token is whitespace; False otherwise. Indicates whether user specified token is whitespace symbols or not. Token to check. True if token is whitespace; False otherwise. Indicates whether user specified token is tab symbols or not. Token to check. True if token is whitespace; False otherwise. Calculates number of the whitespace symbols at the start or at the end of the line. String line. If true - check start of the line, end of the line otherwise. Number of the whitespace symbols at the start or at the end of the line. Checks whether array contains a symbol. Array of symbols. Char symbol. True - if comtains, False otherwise. Gets a value indicating whether this is EOF. true if EOF; otherwise, false. Gets text length. Gets or sets the position. The position. Creator of TrueType type font. Base interface for true type internal fonts. Gets the pdf primitive. Checks whether fonts are equals. Font to compare. True if fonts are equal, False ofhtrwise. Creates font internals. Returns width of the char symbol. Char symbol. Width of the char symbol in universal units. Returns width of the text line. String line. Width of the char symbol in universal units. Releases all resources. Gets system font. Gets size of the font. Gets font metrics. Suffix for bold font name. Suffix for bold italic font name. Suffix for italic font name. Coefficient for calculating font size. Display driver name. String for generating font name. Indicates whether truetypefont has to be emdeded ttf reader object. Ttf metrics structure. System font. Size of the font. Array of used chars. Pdf primitive describing the font. Font program. Holds font-specific info such as first char/last char, etc. Font metrics. Indicates the azure rendering Initializes a new instance of the class. The font. The size. Initializes a new instance of the class. The font. The size. if set to true [embed]. Creates font program. Font program. Returns binary reader of the font's data. Returns binary reader of the font's data. Gets binary data of font. Font object. Bimary data from font file. Gets Pdf primitive reprsenting font. Checks whether fonts are equals. Font to compare. True if fonts are equal, False otherwise. Creates font internals. Runs before font program stream save. Sender of the event. Event arguments. Generates font program. Stores used symbols. String text. Returns width of the char symbol. Char symbol. Width of the char symbol in universal units. Returns width of the text line. String line. Width of the char symbol in universal units. All resources are being to be closed. Creates font dictionary. Font descriptor. Creates font descriptor. Font descriptor object. Retrieves data from the font. Calculates BoundBox of the descriptor. BoundBox of the descriptor. Calculates flags for the font descriptor. Flags for the font descriptor. Infills font metrics. Graphics DC. Creates width table. Graphics DC. Width table. Returns error message. Returns error message. Gets the name of the font. string Formats name Indicates whether byte of font name needs special formatting. Indicates whether byte of font name needs special formatting. Gets a value indicating whether font is symbolic Gets a value indicating whether font is fixed pitch Gets a value indicating whether font is script Gets a value indicating whether font is serif Gets size of the font. Gets system font. Gets font metrics. Gets ttf reader. Reader of the TTF data. Width multiplier. Version of Ttf file. Version of Ttf file. Version of Mac Ttf file FP. Encoding class. Aray of table names. Array of table names. Integer's table. One of this integer would be used as a key for writing some info in the header of the font program. Binary reader object. The whole list of tables loaded from Ttf. Ttf metrics. Width table. Glyphs for Macintosh or Symbol fonts (char - key, glyph - value). Glyphs for Microsoft Unicode fonts (char - key, glyph - value).. Glyphs for Macintosh or Symbol fonts (glyph index - key, glyph - value). Glyphs for Microsoft Unicode fonts (glyph index - key, glyph - value). Indicates whether loca table is short. Indicates whether font is truetype subset Indicates the azure rendering Indicates whether the font is opentype or not. Indicated whether the Encoding with Ansi or not Indicates the current font which is currently under processing. Indicates the number of glyphs missed during measure string Static constructor. Creates a new object. The reader. Creates a new object. The reader. Closes all the resources. Gets glyph's info by char code. Char symbol. Gets glyph's info by glyph index.. Glyph index. Creates fonts internals. Reads a font's program. Array of used chars. Binary font data. Reconverts string to be in proper format saved into PDF file. Return value would be in string. String to be reconverted. Reconverted string. Gets char width. Char for which to measure the width. Char width. Gets hashtable with chars indexed by glyph index. Chars that are used in destination output. Hashtable with chars indexed by glyph index. Provides basic parsing required for font comparing (FontFamily and MacStyle). Reads font directory. Fixes the offsets of the font tables. Reads font metrics. Initializes metrics. Name table. Head table. Horizontal head table. OS/2 table. Post table. Cmap subtables. Reads name table. Name table. Reads head table. Head table. Reads horizontal header table. Horizontal header table. Reads OS2 table. Reads post table. Reads Width of the glyphs. Number of glyphs. Power of 2. Width of the glyphs. Reads cmap table. Array of subtables. Reads cmap subtables. Cmap subtable. Reads Symbol cmap table. Cmap subtable. Encoding ID. Reads Symbol cmap table. Cmap subtable. Encoding ID. Reads Trimed cmap table. Cmap subtable. Encoding ID. Reads loca table. If True - table is int16, int32 otherwise. Loca table. Reads ushort array. Length of the array. Ushort array. Reads uint array. Length of the array. Uint array. Adds glyph to the collection. Glyph info. Encoding ID. Returns width of the glyph. Code of the glyph. Returns width of the glyph. Updates chars structure which is used in the case of ansi encoding (256 bytes). Indicates whether code is right Ttf preambula code: Gets CMAP encoding based on platform ID and encoding ID. Returns table. Name of the table. Returns table. Updates hashtable of used glyphs. Dictionary of used glyphs. Loca table. Checks if glyph is composite or not. If True, it provides additional work. Dictionary of glyphs. Glyph index. Loca table. Creates new glyph tables based on chars that are used for output. dictionary of glyphs. Loca table. The updated table that stores the offsets to the locations of the glyphs in the font. The updated glyph table that holds only the glyphs that are used for destination output. Glyph table size. Updates new Loca table. New Loca table. Indicates whether loca is short. Updated new loca table. Updated loca table size. Returns font program data. New updated loca table. New glyph table. Size of glyph table. Size of loca table. Font program data. Calculate size of the font program. Updated new loca table. New glyph table. Number of tables used. Size of the font program. Gets checksum from source buffer. Byte array. Writing to destination buffer - checksums and sizes of used tables. Writer object. Number of tables. New updated loca table. New glyph table. Size of glyph table. Size of loca table. // Writing to destination buffer - used glyphs. Writer object. New updated loca table. New glyph table. Initializes font name. Name table. Reads structure from the binary reader. Binary reader class. Type of teh structure. Structure object. Aligns number to be divisible on 4. Returns default glyph. Returns default glyph. Gets the font data. The font. Name of the table. Checks for the additional offset of the tables. TTF table. Name of the table. Additional ofset of the tables. Reader of the data. Checks whether two arrays are equal. The first array. The second array. True if arrays are equal. Formats name of the table to int value. Name of the table. Code of the table name. Gets or sets binary reader. Gets BigEndian internal reader. Gets metrics of the font. The whole list of tables loaded from Ttf. Gets glyphs for Macintosh or Symbol fonts (char - key, glyph - value). Gets glyphs for Microsoft Unicode fonts (char - key, glyph - value).. Gets glyphs for Macintosh or Symbol fonts (glyph index - key, glyph - value). Gets glyphs for Microsoft Unicode fonts (glyph index - key, glyph - value). /// Array of table names. Table names Gets the font. The font. Indicates the truetypefont is subet true if embeded subset; otherwise, false. Creator of Unicode TrueType type font. Display driver name. String for generating font name. Cmap table's start prefix. Cmap table's start suffix. Cmap table's end Cmap's begin range marker. Cmap's end range marker. Cmap's next range default value Default registry's value Index of the default symbol. Length of Cid Stream System font. Path to ttf file. Size of the font. Font metrics. Pdf primitive describing the font. Descendant font. font descripter Font program. Cmap stream. Cid set stream ttf reader object. Array of used chars. Name of the font subset. Ttf metrics structure. Specifies the composite font types. Indicates the azure rendering creates a new object. Font object. Font size. creates a new object. Path to ttf file. Font size. creates a new object. Font object. Font size. Creates a new object from a prototype object. Prototype object. Stores used symbols. String text. Stores used symbols. Glyphs, used by the line of the text. Gets Pdf primitive reprsenting font. Checks whether fonts are equals. Font to compare. True if fonts are equal, False otherwise. Compare font stream and return true when it's have same font stream Creates font internals. Returns width of the char symbol. Char symbol. Width of the char symbol in universal units. Returns width of the text line. String line. Width of the char symbol in universal units. All resources are being to be closed. Initializes the object. Returns binary reader of the font's data. Returns binary reader of the font's data. Gets binary data of font. Font object. Bimary data from font file. Initializes the object. Initializes metrics. Creates font program. Font program. Generates font program. Generates font dictionary. Creates descendant font. Creates cmap. Creates CidSet. Creates cmap. Creates system info dictionary for CID font. Pdf primitive. Creates font descriptor. Pdf primitive. Generates name of the font. Gets random string. Gets width description pad array for cid font. Width description pad array for cid font. Converts integer of decimal system to hex integer. Integer to be converted. Hex string. Calculates flags for the font descriptor. Flags for the font descriptor. Calculates BoundBox of the descriptor. BoundBox of the descriptor. Runs before font Dictionary will be saved. Sender of the event. Event arguments. Runs before font Dictionary will be saved. Sender of the event. Event arguments. Runs before font program stream save. Sender of the event. Event arguments. Runs before cmap will be saved. Sender of the event. Event arguments. Runs before Cid will be saved. Sender of the event. Event arguments. Runs before font Dictionary will be saved. Sender of the event. Event arguments. This is important for PDF/A conformance validation Gets size of the font. Gets system font. Gets or set Embed font. Gets font metrics. Gets ttf reader. Gets path to the font file if the font was created from a file. Gets TtfMetrics structure. Gets the type. The type. Get or set the font embed type. Specifies style information applied to text. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Normal text. Bold text. Italic text. Represents the underline text. Strikeout text. Indicates type of standard PDF fonts. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold); //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Represents the Helvetica font. Represents the Courier font. Represents the Times Roman font. Represents the Symbol font. Represents the ZapfDingbats font. Specifies the type of CJK font. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the standard font. PdfFont font = new PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20); //Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the standard font. Dim font As PdfFont = New PdfCjkStandardFont(PdfCjkFontFamily.HeiseiMinchoW3, 20) 'Draw the text. graphics.DrawString("こんにちは世界", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Represents the Hanyang Systems Gothic Medium font. Represents the Hanyang Systems shin myeong Jo Medium font. Represents the Heisei kaku GothicW5 font. Represents the Heisei MinchoW3 font. Represents the Monotype Hei Medium font. Represents the monotype sung Light font. Represents the sinotype song light font. Specifies the type of the font. //Load the existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Get the use fonts. PdfUsedFont[] fonts = ldoc.UsedFonts; //Get the used font type. PdfFontType fontType = fonts[0].Type; //Close the document. ldoc.Close(true); 'Load the existing PDF document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the use fonts. Dim fonts() As PdfUsedFont = ldoc.UsedFonts 'Get the used font type Dim fontType As PdfFontType = fonts(0).Type 'Close the document. ldoc.Close(True) Indicates the standard Adobe fonts. Indicates the non-embedded TrueType fonts. Indicates the Embedded TrueType fonts. Specifies the types of text wrapping. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Set clip path. format.ClipPath = true; //Set line limit. format.LineLimit = true; //Set line spacing. format.LineSpacing = 1.1f; //Set measure trailing spaces. format.MeasureTrailingSpaces = true; //Set no clip format.NoClip = true; //Set paragraph indent. format.ParagraphIndent = 2.1f; //Set right to left. format.RightToLeft = false; //Set word spacing. format.WordSpacing = 1.5f; //Set word wrap type. format.WordWrap = PdfWordWrapType.Word; //Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Set clip path. format.ClipPath = True 'Set line limit. format.LineLimit = True 'Set line spacing. format.LineSpacing = 1.1F 'Set measure trailing spaces. format.MeasureTrailingSpaces = True 'Set no clip format.NoClip = True 'Set paragraph indent. format.ParagraphIndent = 2.1F 'Set right to left. format.RightToLeft = False 'Set word spacing. format.WordSpacing = 1.5F 'Set word wrap type. format.WordWrap = PdfWordWrapType.Word 'Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Text wrapping between lines when formatting within a rectangle is disabled. Text is wrapped by words. If there is a word that is longer than bounds' width, this word is wrapped by characters. Text is wrapped by words. If there is a word that is longer than bounds' width, it won't be wrapped at all and the process will be finished. Text is wrapped by characters. In this case the word at the end of the text line can be split. Specifies type of the SubSuperScript. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Set character spacing. format.CharacterSpacing = 1; //Set clip path. format.ClipPath = true; //Set line limit. format.LineLimit = true; //Set line spacing. format.LineSpacing = 1.1f; //Set measure trailing spaces. format.MeasureTrailingSpaces = true; //Set no clip format.NoClip = true; //Set paragraph indent. format.ParagraphIndent = 2.1f; //Set right to left. format.RightToLeft = false; //Set word spacing. format.WordSpacing = 1.5f; //Set word wrap type. format.WordWrap = PdfWordWrapType.Word; //Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Set character spacing. format.CharacterSpacing = 1 'Set clip path. format.ClipPath = True 'Set line limit. format.LineLimit = True 'Set line spacing. format.LineSpacing = 1.1F 'Set measure trailing spaces. format.MeasureTrailingSpaces = True 'Set no clip format.NoClip = True 'Set paragraph indent. format.ParagraphIndent = 2.1F 'Set right to left. format.RightToLeft = False 'Set word spacing. format.WordSpacing = 1.5F 'Set word wrap type. format.WordWrap = PdfWordWrapType.Word 'Set sub/super script type. format.SubSuperScript = PdfSubSuperScript.SubScript 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Specifies no subscript or superscript. Specifies superscript format. Specifies subscript format. Ttf platform ID. Apple platform. Macintosh platform. Iso platform. Microsoft platform. Ttf Name ID. The Copyright The Font Family The Font Sub Family The Font Identifier The Font Name The Version The PostScriptName The Trademark Enumerator that implements CMAP encodings. Unknown encoding. When building a symbol font for Windows. When building a Unicode font for Windows. For font that will be used on a Macintosh. When building a Unicode font for Windows (plane characters). Microsoft encoding ID Undefined encoding. Unicode encoding. Unicode UCS 4 encoding. Macintosh encoding ID. Roman encoding. Japanese encoding. Chinese encoding. Enumerator that implements CMAP formats. This is the Apple standard character to glyph index mapping table. This is the Microsoft standard character to glyph index mapping table. Format 6: Trimmed table mapping. This is the Microsoft standard character-to-glyph-index mapping table for fonts supporting Unicode supplementary-plane characters (U+10000 to U+10FFFF). ttf composite glyph flags. The ARG_1_AND_2_ARE_WORDS. The ARGS_ARE_XY_VALUES. The ROUND_XY_TO_GRID. The WE_HAVE_A_SCALE. The RESERVED. The MORE_COMPONENTS. The WE_HAVE_AN_X_AND_Y_SCALE. The WE_HAVE_A_TWO_BY_TWO. The WE_HAVE_INSTRUCTIONS. The USE_MY_METRICS. Character set encoding type of the font. Unknown encoding Adobe standard Latin-text encoding Mac OS standard encoding An encoding for use with expert fonts Windows Code Page 1252 Encoding for text strings in a PDF document outside the document's content streams. The horizontal identity mapping for 2-byte CIDs; may be used with CIDFonts using any Registry, Ordering, and Supplement values. It maps 2-byte character codes ranging from 0 to 65,535 to the same 2-byte CID value, interpreted high-order byte first. Enumerator that implements font descriptor flags. All glyphs have the same width (as opposed to proportional or variable-pitch fonts, which have different widths). Glyphs have serifs, which are short strokes drawn at an angle on the top and bottom of glyph stems (as opposed to sans serif fonts, which do not). Font contains glyphs outside the Adobe standard Latin character set. The flag and the nonsymbolic flag cannot both be set or both be clear. Glyphs resemble cursive handwriting. Font uses the Adobe standard Latin character set or a subset of it. Glyphs have dominant vertical strokes that are slanted. Bold font. Specifies the composite font types. Holds offset for TTF table from beginning of TrueType font file. Gets or sets ofset from beginning of TrueType font file. Gets or sets length of this table. Gets or sets table checksum. Gets a value indicating whether this is empty. true if empty; otherwise, false. ttf metrics. Typographic line gap. Negative LineGap values are treated as DEF_TABLE_CHECKSUM. Gets or sets contains CFF. Gets or sets value indicating if Symbol font is used. Gets or sets description font item. Gets or sets description font item. Gets or sets description font item. Gets or sets post-script font name. Gets or sets font family name. Gets or sets description font item. Gets or sets description font item. Gets or sets description font item. Gets or sets description font item. Gets or sets description font item. Gets or sets description font item. Gets or sets description font item. Gets or sets widths table for the font. Regular: 0 Bold: 1 Italic: 2 Bold Italic: 3 Bit 0- bold (if set to 1) Bit 1- italic (if set to 1) Bits 2-15- reserved (set to 0). NOTE: Note that macStyle bits must agree with the 'OS/2' table fsSelection bits. The fsSelection bits are used over the macStyle bits in Microsoft Windows. The PANOSE values and 'post' table values are ignored for determining bold or italic fonts. Subscript size factor. Superscript size factor. Gets a value indicating whether this instance is italic. true if this instance is italic; otherwise, false. Gets a value indicating whether this instance is bold. true if this instance is bold; otherwise, false. name ttf table. Local variable to store Format Selector. Local variable to store Records Count. Local variable to store Offset. Local variable to store Name Records. Name record. The PlatformID. The EncodingID. The PlatformIDLanguageID The NameID. The Length. The Offset. The Name. Names of the tables. The cmap. The glyf. The head. The hhea. The cmap. The loca. The maxp. The cmap. The post. The OS2. The CFF. The cvt. The fpgm. The prep. Head table. Modified: International date (8-byte field). Created: International date (8-byte field). MagicNumber: Set to 0x5F0F3CF5. CheckSumAdjustment: To compute: set it to 0, sum the entire font as ULONG, then store 0xB1B0AFBA - sum. FontRevision: Set by font manufacturer. Table version number: 0x00010000 for version 1.0. Minimum x for all glyph bounding boxes. Minimum y for all glyph bounding boxes. Valid range is from 16 to 16384. Maximum y for all glyph bounding boxes. Maximum x for all glyph bounding boxes. Regular: 0 Bold: 1 Italic: 2 Bold Italic: 3 Bit 0 - bold (if set to 1) Bit 1 - italic (if set to 1) Bits 2-15 - reserved (set to 0) NOTE: Note that macStyle bits must agree with the 'OS/2' table fsSelection bits. The fsSelection bits are used over the macStyle bits in Microsoft Windows. The PANOSE values and 'post' table values are ignored for determining bold or italic fonts. Bit 0 - baseline for font at y=0 Bit 1 - left SideBearing at x=0 Bit 2 - instructions may depend on point size Bit 3 - force ppem to integer values for all private scaler math; may use fractional ppem sizes if this bit is clear Bit 4 - instructions may alter advance width (the advance widths might not scale linearly) Note: All other bits must be zero. LowestRecPPEM: Smallest readable size in pixels. FontDirectionHint: 0 Fully mixed directional glyphs 1 Only strongly left to right 2 Like 1 but also contains neutrals -1 Only strongly right to left -2 Like -1 but also contains neutrals. 0 for short offsets, 1 for long. 0 for current format. This table contains information for horizontal layout. The values in the minRightSidebearing, minLeftSideBearing, and xMaxExtent should be computed using only glyphs that have contours. Glyphs with no contours should be ignored for the purpose of these calculations. All reserved areas must be set to 0. Version. Typographic ascent. Maximum advance width value in HTML table. Typographic descent. Number of hMetric entries in HTML table; may be smaller than the total number of glyphs in the font. Typographic line gap. Negative LineGap values are treated as DEF_TABLE_CHECKSUM in Windows 3.1, System 6, and System 7. Minimum left SideBearing value in HTML table. Minimum right SideBearing value; calculated as Min(aw - lsb - (xMax - xMin)). Max(lsb + (xMax - xMin)). Used to calculate the slope of the cursor (rise/run); 1 for vertical. 0 for vertical. 0 for current format. The OS/2 table consists of a set of metrics that are required by Windows and OS/2. Struct field. The Average Character Width parameter specifies the arithmetic average of the escapement (width) of all of the 26 lowercase letters a through z of the Latin alphabet and the space character. If any of the 26 lowercase letters are not present, this parameter should equal the weighted average of all glyphs in the font. For non-UGL (platform 3, encoding 0) fonts, use the unweighted average. Indicates the visual weight (degree of blackness or thickness of strokes) of the characters in the font. Indicates a relative change from the normal aspect ratio (width to height ratio) as specified by a font designer for the glyphs in a font. Indicates font embedding licensing rights for the font. Embeddable fonts may be stored in a document. When a document with embedded fonts is opened on a system that does not have the font installed (the remote system), the embedded font may be loaded for temporary (and in some cases, permanent) use on that system by an embedding-aware application. Embedding licensing rights are granted by the vendor of the font. The recommended horizontal size in font design units for subscripts for this font. The recommended vertical size in font design units for subscripts for this font. The recommended horizontal offset in font design units for subscripts for this font. The recommended vertical offset in font design units from the baseline for subscripts for this font. The recommended horizontal size in font design units for superscripts for this font. The recommended vertical size in font design units for superscripts for this font. The recommended horizontal offset in font design units for superscripts for this font. The recommended vertical offset in font design units from the baseline for superscripts for this font. Width of the strikeout stroke in font design units. The position of the strikeout stroke relative to the baseline in font design units. This parameter is a classification of font-family design. This 10 byte series of numbers are used to describe the visual characteristics of a given typeface. These characteristics are then used to associate the font with other fonts of similar appearance having different names. The variables for each digit are listed below. The specifications for each variable can be obtained in the specification PANOSE v2.0 Numerical Evaluation from Microsoft or Elseware Corporation. Struct field. Struct field. Struct field. Struct field. The four character identifier for the vendor of the given type face. Information concerning the nature of the font patterns. The minimum Unicode index (character code) in this font, according to the cmap subtable for platform ID 3 and encoding ID 0 or 1. For most fonts supporting Win-ANSI or other character sets, this value would be 0x0020. usLastCharIndex: The maximum Unicode index (character code) in this font, according to the cmap subtable for platform ID 3 and encoding ID 0 or 1. This value depends on which character sets the font supports. The typographic ascender for this font. Remember that this is not the same as the Ascender value in the 'hhea' table, which Apple defines in a far different manner. DEF_TABLE_OFFSET good source for usTypoAscender is the Ascender value from an AFM file. The typographic descender for this font. Remember that this is not the same as the Descender value in the 'hhea' table, which Apple defines in a far different manner. DEF_TABLE_OFFSET good source for usTypoDescender is the Descender value from an AFM file. The typographic line gap for this font. Remember that this is not the same as the LineGap value in the 'hhea' table, which Apple defines in a far different manner. The ascender metric for Windows. This too is distinct from Apple's Ascender value and from the usTypoAscender values. usWinAscent is computed as the yMax for all characters in the Windows ANSI character set. usTypoAscent is used to compute the Windows font height and default line spacing. For platform 3 encoding 0 fonts, it is the same as yMax. The descender metric for Windows. This too is distinct from Apple's Descender value and from the usTypoDescender values. usWinDescent is computed as the -yMin for all characters in the Windows ANSI character set. usTypoAscent is used to compute the Windows font height and default line spacing. For platform 3 encoding 0 fonts, it is the same as -yMin. This field is used to specify the code pages encompassed by the font file in the 'cmap' subtable for platform 3, encoding ID 1 (Microsoft platform). If the font file is encoding ID 0, then the Symbol Character Set bit should be set. If the bit is set (1) then the code page is considered functional. If the bit is clear (0) then the code page is not considered functional. Each of the bits is treated as an independent flag and the bits can be set in any combination. The determination of "functional" is left up to the font designer, although character set selection should attempt to be functional by code pages if at all possible. This field is used to specify the code pages encompassed by the font file in the 'cmap' subtable for platform 3, encoding ID 1 (Microsoft platform). If the font file is encoding ID 0, then the Symbol Character Set bit should be set. If the bit is set (1) then the code page is considered functional. If the bit is clear (0) then the code page is not considered functional. Each of the bits is treated as an independent flag and the bits can be set in any combination. The determination of "functional" is left up to the font designer, although character set selection should attempt to be functional by code pages if at all possible. Struct field. Struct field. Struct field. Struct field. Struct field. Ttf structure. Struct field. Struct field. Struct field. Struct field. Struct field. Struct field. Struct field. Struct field. Struct field. Ttf structure. Structure field. Structure field. Ttf structure. Structure field. Structure field. Ttf structure. Structure field. Structure field. Structure field. Ttf structure. Structure field. Structure field. Structure field. Ttf structure. Structure field. Structure field. Structure field. Structure field. Structure field. Ttf structure. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Structure field. Holds glyph info and its width of character. Holds glyph index. Holds character's width. Code of the char symbol. Compares two WidthDescriptor objects. Another object for comparing. A signed integer that indicates the relative order of this instance and value. Gets a value indicating whether this is empty. true if empty; otherwise, false. Ttf structure. Structure field. Ttf structure. Structure field. Structure field. Structure field. Structure field. Structure field. Helping class that allows to control the graphic handles. It controls numbering for such handles that are changing during actions such as SelectObject, DeleteObject Flag checking if object is system or created by user. Help flag for retrieving object from the stock. The collection of standard graphic objects that can be used currently. Holds the collection of created graphic objects that can be used currently Holds the list of avaible indexes Initializes the class. Adds the object under specified unique index object to be added unique index for the object Adds the object under specified unique index object to be added Selects object by the unique index unique index for the object selected object Deletes objects unique index for the object to be deleted Deleted object. Cleares collection of selected objects. Checks if object is stock object. Object for checking. True -if object is in stock, False otherwise. Retrieves object from the stock. ID of the object. Object from the stock if found, Null otherwise. Checks if object is in the stock or it's created by user. ID of the object. True - if object is in the stock, False otherwise. Retrieves object from the stock. ID of the object. Object from the stock if found, Null otherwise. Gets the collection of created graphic objects that can be used currently Gets the list of avaible indexes Help data during EMF metafiles parsing. Number of 0.01 millimeter per inch. Collection of created objects. Unmanaged handle used by the most of the GDI WinApi functions. Font object. Font object. Pen object. Current graphics path object. Image resource. Graphic state of the graphics context. Graphics object. Indicates if there is open graphics path object. Angle of the text. Cointrex stack. Bitmap for getting graphics from it. REsolution of the screen. Indicates background mode. Initializes a new instance of the class. The dpi. Disposes object. Recognizes selected object. Selected object. Deletes object from the context. Object to be deleted. Saves state to context stack. Restores state from context stack. Index in the stack. Copies data from current object to specified. Destination data object. Disposes selected objects. Gets collection of selected objects. Gets unmanaged handle used by the most of the GDI WinApi functions. Gets or sets graphic state of the graphics context. Gets or sets the font. The font. Gets or sets current brush object. Gets or sets current pen object. Gets or sets current graphics path. Gets or sets image object. Gets graphics object. Gets or sets the current point at DC. Gets or sets a value indicating whether this instance is open path. true if this instance is open path; otherwise, false. Gets or sets arc direction of current device context. Gets or sets text align. Gets or sets BackGroundMode Gets or sets Text color. Gets or sets back color. Gets or sets polygon fill mode. Gets default resolution of the screen. Gets or sets angle of the text. Gets context stack object. Class holding font and it's rotating angle. Font object. Structure describing font. Initializes a new instance of the class. The font. The structure. Disposes object. Gets font object. Gets text rotating angle. Gets LOGFONT structure from which font was created. Class implementing capabilities to parse EMF metafiles. Number of numbers in the point type. Number of numbers in the rectangle type. Size of Int32 type. Size of Short type. Size of Single type. Handler of function parsing metafile. Graphics context object. Asociated with parser context object. Asociated with parser context object. Parsing metafile object. Initializes the class. Initializes a new instance of the class. Initializes a new instance of the class. The renderer. Disposes object. Check result of function. If function failed - writes debug message. Result of the function. Creates handler of parsing function. Handler of parsing function. Reads number from the array. Array of data. Index in the array. Size of the number. Number form the array. Gets handler of parsing method. Gets or sets Graphics context. Gets or sets context of the parser. Gets or sets context of the parser. Gets or sets the parsing metafile object. Gets or sets the page scale. The page scale. Gets or sets the page unit. The page unit. Gets type of metafile parser is able to parse. Pixels per inch amount Number of degrees in one radian. Help objects. Type of metafile. Text Rotation Angle Holds the selected font Emf text Scaling factor Initializes a new instance of the class. The type. The dpi. Initializes a new instance of the class. The dpi. Initializes a new instance of the class. The renderer. Overloaded. Disposes resources. Overloaded. Creates handler of parsing function. Handler of parsing function. Enumerates metafile. Type of record. Help flags. Size of the data for the record. Pointer on the memory where data are located. Callback function. True - to proceed enumeration, False otherwise. Starts enumeration. Finishes enumeration. Saves graphic state of the graphics context. Data for the record. Restores device context to the previous state. Data for the record. Stores miter limit. Pointer to data. Process record of metafile. Pointer on record data. Process record of metafile. Pointer on record data. Process record of metafile. The data. Process record of metafile. The data. Process record of metafile. Pointer on record data. Process record of metafile. Pointer on record data. Process record of metafile. Record data. Indicates if it's 32 or 16 bit version. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. The PTR. Process record of metafile. Record data. Indicates if it's 32 or 16 bit version. Process record of metafile. The PTR. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Record data. Indicates if it's 32 or 16 bit version. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Datra of the record. Pointer to record data. Process record of metafile. Data of the record. Pointer to record data. Process record of metafile. Datra of the record. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. if b is arc, set to true. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Implements the final stage of the 'Blt'-family functions. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. True - if string is unicode, False - otherwise. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Process record of metafile. Pointer to record data. Check object path drawn pen is visible or not Converts glyph indices to unicode charachter codes. The glyph indices. The font. The unicode string. Trims the name of the font. Name of the font. Makes dump of the data. Data array. The type. Gets structure with data from Record data. The PTR. The type. Structure from the data. Gets structure with data from Record data. Record data. Sample structure object. Structure with data from IntPtr. This method marshals structures with arrays of unknown length. Converts logical point to device point. Logical point to be converted. Converted point to device point. Converts rectangle from logic units to device units. System.Drawing.Rectangle object. Converted rectangle. Converts logical point to device point. Logical point to be converted. Converted point to device point. Converts logical point to device point. Logical point to be converted. Converted point to device point. Converts logic value to device value; Value in logic coordinates. Converts logic value to device value; Value in logic coordinates. Converts device point to logical point. Device point to be converted. Converted point to logical point. Converts device value to logical value; Value in device coordinates. Converts device value to logical value; Value in device coordinates. Converts device System.Drawing.Rectangle to logical value; The rectangle. Converted rectangle Reads RECT structure. Data array. Current index. RECT structure. Reads array from the record. Record data. Size of the array. Current index. Array of data. Creates array of points. Record data. Size of the array. Current index. If true - reads Int32 numbers, otherwise reads Short numbers. Array of data. Reads number. Data array. Current index. If true - reads Int32 numbers, otherwise reads Short numbers. Number from the data. Sets proper graphics mode. Converts points from GDI poiont type to PointF. Array of points. Converted array. Converts points from GDI poiont type to PointF. Array of points. Converted array. Converts points from GDI poiont type to PointF. Array of points. Converted array. Adds current point to array of points. Array of points. Array with current point. Converts XFORM structure to Matrix object. XFORM structure. Matrix object. Calculates angle between two vectors. x coordinate of start origin. y coordinate of start origin. x coordinate of vector. y coordinate of vector. Angle between vector and x origin. Returns point on the ellipse bounded by rectangle intersecyet with radial point. Bounds structure. Radial point. Point of intersection. Creates bitmap image. Offset to image data. Size of the image data. Pointer to the data. Pointer to the BitmapInfo structure. Bitmap Info header. Usage of the pixels. Bitmap image. Creates bitmap image. Offset to image data. Size of the image data. Pointer to the data. Pointer to the BitmapInfo structure. Usage of the pixels. Bitmap image. Creates bitmap image. Offset to image data. Size of the image data. Pointer to the data. Pointer to the BitmapInfo structure. Usage of the pixels. Bitmap image. Converts logical height of the font to it's point's value. Logical height of the font. Size of the font. Returns metric of the font. Font object. Metric of the font. Returns string format for the text. String format for the text. Draws text. Text to be printed. String format object. System.Drawing.Rectangle structure. Structure describing text settings. The widths. Gets current map mode. Current map mode. Retireves array of bytes from the unmanaged memory. Pointer to the memory. Size of the data. Byte array. Implements the final stage of the 'Blt'-family functions. Overloaded. Gets MetafileType.Emf Gets help objects. Gets text region mananger. Gets image region mananger. Class for parsing EmfPlus metafiles. Flag for recognizing type of region. Flag for objects recognizing. Flag for object index recognizing. Represents path filling type. Flag indicating whether color is in the data or it's index of the pen/brush. Represents flag indicating whether short type should be used. Storage of help objects. Type of metafile. Indicates whether we should start emf record processing. Store the path of current pen's end cap. Flag for connecting last and first points. Creates new object. The dpi. Creates new object. The renderer. The dpi. Overloaded. Creates handler of function parsing metafile. Enumerates metafile. Type of record. Help flags. Size of the data for the record. Pointer on the memory where data are located. Callback function. True - to proceed enumeration, False otherwise. Parses the meta record. The data. The flags. Parsing method. Method data. Headers this instance. Ends the of file. Begins the container. The data. The flags. Begins the container no params. The data. Clears the specified data. The data. Draws the arc. The data. The flags. Draws the beziers. The data. The flags. Draws the closed curve. The data. The flags. Draws the curve. The data. The flags. Draws the ellipse. The data. The flags. Draws the image. The data. The flags. Draws the image points. The data. The flags. Draws the lines. The data. The flags. Draws the path. The data. The flags. Draws the pie. The data. The flags. Draws the rectangle. The data. The flags. Draws string. Buffer containing record data. Record flags. Draws Driver string. Buffer containing record data. Record flags. Parses EndContainer record. Record data. Parses FillClosedCurve record. Record data. Record flags. Parses FillEllipse method. Record data. Record flags. Fills the region. The data. The flags. Objects the specified data. The data. The flags. Scales the world transform. The data. The flags. Sets the antialias mode. The data. The flags. Sets the clip path. The data. The flags. Sets the composing mode. The data. The flags. Sets the compositing quality. The data. The flags. Sets the interpolation mode. The data. The flags. Sets the page transform. The data. The flags. Sets the pixel offset mode. The data. The flags. Sets the rendering origin. The data. Sets the text contrast. The flags. Sets the text rendering hint. The flags. Sets the world transform. The data. Translates the world transform. The data. The flags. Reads the pen. The data. The index. Creates the path of pen's custom end cap. The data. The index. The flags. Reads the image. The data. The index. Reads the path. The data. The index. Reads the region. The data. The index. Reads the font. The data. The index. Reads the string format. The data. The index. Reads the brush. The data. The index. Reads the hatch brush. The data. The index. Reads the gradient brush. The data. The index. Reads path gradient brush. Data for the brush. The index. Reads the texture brush. The data. The index. The texture brush. Gets the rectangle step. The flags which holds the step value. The rectangle step. Reads the wrap mode. The data. The index. The WrapMode enum. Reads the gradient brush flags. The byte data array. The index of the flags. The initialized GradientBrushFlags. Reads the blend. The byte data array. The start position in the data. The size of the single value. The positions array. The factors array. The final index within the data. Reads the color blent. The byte data array. The start position in the data. The size of the single value. The blend object. Reads the points. The data. The index. The number. The step. Reads the point. The data. The index. The step. Reads an integer from a data array at an index specified. The data array. The index which the integer starts at. The integer read. Dumps the record data. The data. The type of the record. Read Graphics path from the region. Data of the record. Current index. step value. Graphics path object. Reads base region from the data. Record data. Current index. Step value. Region object. Combines regions. Source region. Destination region. Combine mode. Result region. Returns index of the object in the table. Flags data. Index of the object in the table. Checks whether data contains color or index of the object. Flags data. Checks whether data contains color or index of the object. Gets the fill mode. The flags. Gets the brush. The data. The index. The flags. Reads the RectL structure. The data. The index. Rectangle structure initialized. Starts processing of emf records. Type of record. Help flags. Size of the data for the record. Pointer on the memory where data are located. Callback function. Determines whether [is valid rect] [the specified rect]. The rect. true if [is valid rect] [the specified rect]; otherwise, false. Converts bitmap to PNG. The img. Overloaded. Returns metafile type. Gets a collection of objects in the stack. Region of the space in which image in metafile can take. Y co-ordinate of the region. Height of the region. Initializes a new instance of the class. Initializes a new instance of the class. The y. The height. Joins two regions. Image region to be joined. Image region to be joined. Joined region. Checks whether region intersect with the current one. Region object. True - if they're intersected, False - otherwise. Gets or sets Y co-ordinate of the region when the text starts. Gets or sets Height of the text region. Manages ImageRegion objects. Collection of the regions. Initializes a new instance of the class. Adds a Image region into the collection. region Searches for the largest Y co-ordinate of the region if the y is inside of any region or returns y if it's out of any region. Y co-ordinate of some text region. Searches for the largest Y co-ordinate of the region if the y is inside of any region or returns y if it's out of any region. Searches for the image region. Y co-ordinate of some image region. Returns the Y co-ordinate of last before image region. Clears the collection. Searches for all regions in the collection that are intersested with the current one. Current text region. Array of regions that intersect with the current. Removes region from the colection. Region that should be removed from he collection. Removes regions from the collection. Array of regions that should be removed from he collection. Joins array of regions and the region into one region. Array of the regions. Current image region. Number of numbers in the point type. Number of numbers in the rectangle type. Flag for recognizing type of region. Flag for objects recognizing. Type of path filling. Index where type of the brush is located. Size of Int32 type. Size of Short type. Size of Single type. Parsing metafile object. Parser of metafile. It depends on the metafile. Gets graphics context object. Checks if object is already disposed or not. Indicates whether image is WMF file and needs to be disposed. Static constructor. Creates new object. Creates new object. The renderer. Metafile for parsing. Disposes the object. Enumerates a metafile. True - successful enumeration, False otherwise. Assigns the metafile. The metafile. Recognizes which parser must be created according to metafile. Header of metafile. The dpi. Gets or sets the renderer. Gets or sets parsing metafile object. Gets context data of the parser. Gets context data of the parser. Gets parser object. Summary description for ObjectData. Mask for object index recognizing. Stores collection of the GDI objects. Holds all graphigcs states. Internal graphics context. Internal image object. Creates a new object. Disposes the object. Gets font by its index. Index of the object in the table of GDI objects. Font by its index. Gets brush by its index. Index of the object in the table of GDI objects. Brush by its index. Gets the pen from the collection. The index of the pen within the collection. The pen. Sets the pen. The index of the pen object. The pen which should be stored.. Gets object by its index. Index of the object in the table of GDI objects. Object by its index. Sets object to the collection. Index of the object in the collection. GDI object. Gets the state by its index. The index of the state. The graphics state stored previously. Sets the state with it index. The index of the state. The state. Disposes collection of the GDI objects. Gets internal graphics context. Matrix indicating bounds for the metafile output. Shows if the graphics state was changed. Shows if it's the first call to the OnDrawPrimitive method. UnitConvertor instance for X coorditate. UnitConvertor instance for Y coorditate. Holds mapping between .NET graphics states and PDF graphics states. Shows if it was the first transformation operation. Gets or sets the quality. When the image is stored into PDF not as a mask, you may reduce its quality, which saves the disk space. get or sets the image resolution When the image is stored into PDF not as a mask, you may reduce its resolution, which saves the disk space Represents flag indicating whether the page has been already transformed or not. TODO : Process Begin and End Container. Shows if the graphics state was restored. Internal varible to store the alpha pen. Internal varible to store the alpha brush. Internal varible to store tranaparency is applied or not. Internal varible to store the pdf blend mode. Internal variable to store whether to connect last and first points. Internal variable to store whether the EMF being drawn in a Tagged PDF. Asociated with parser context object. Used to store real clip value Internal variable to store the state change of the EMFplus and EMF used to store current emf record type used to store prvious record type stores the text clip internal variable to store custom line cap arrow data used to confirm wheather the text is clipped or not. Internal variable to store current pdf document internal variable to store identical image collection used as local font collection to avoid multi threading issues Specifies the private font collection. Initializes a new instance of the class. The graphics. Initializes a new instance of class. Initializes a new instance of the class. The graphics. The bitmap quality. Initializes a new instance of the The Graphics The Bitmap quality Begins a new virtual graphics container. A GraphicsContainer instance. Begins a new virtual container. The destination rectangle. The source rectangle. The unit. A GraphicsContainer instance. Fills the entire graphics with the specified color. The color. Draws an arc. The pen. The rectangle specifying the boundaries of the full circle, of which the arc is a part. The start angle. The sweep angle. Draws one or more Bezier curves. The pen. The points. Draws a closed curve. The pen. The points. The tension. The fill mode. Draws a curve. The pen. The points. Points to custom cap. The offset. The number of the segments. The tension. It isn't supported. Draws an ellipse. The pen. The rectangle specifying the boundaries of the ellipse. Draws an image. The image. The destination rectangle. The source rectangle. The units. Draws an image. The image. The points. The source rectangle. The units. Used to change the image resolution value of image resolution to set original image Draws an image and/or brush. The image to draw. The brush to draw. Where to draw. Where to draw from. Raster Operation Code. Draws extra line between the last and first points. The pen. The points. If true, connects last and first points. Draws lines specified by vertices. The pen. The points. Darw the multiple Line Convert the pen to PdfPen PdfPen Draws a path. The pen. The path. Draws polygon. Pen object. Array of points. Draws a pie. The pen. The rectangle specifying the boundaries of the complete circle, of which the pie is a part. The start angle. The sweep angle. Draws a series of rectangles. The pen. An array of rectangles. Draws a text string. The text. The font. The brush. The boundaries of the text. Draws a text string. The text. The font. The brush. The text boundaries. The string format. Checks if the given rectangle overflows the current page. Draws a text string. The text. The font. The brush. The text boundaries. The string format. Rotation Angle Corrects the location. The location. The size. The real size of the text. The format. The corrected location. Ends the specified graphics container. The container. Restores the graphics state saved by the appropriate BeginContainer method. Fills a closed curve. The brush. The points of the curve. The fill mode. The tension. It isn't supported. Fills an ellipse. The brush. The boundaries of the ellipse. Fills a path. The brush. The path. Fills a pie. The brush. The x coordinate of the ellipse boundaries, which the pie is a part of. The y coordinate of the ellipse boundaries, which the pie is a part of. The width of the ellipse boundaries, which the pie is a part of. The height of the ellipse boundaries, which the pie is a part of. The start angle. The sweep angle. Fills a polygon. The brush. The points of the polygon. Fills rectangles. The brush. The rectangles. Fills a region. The brush. The region. Performs multiply transformations. The matrix. The order. Translates the current clip region. The dx. The dy. Resets the current clip region to the infinite region. Resets the transformations. Performs the rotate transformations. The angle. The order. Saves the current graphics state. A GraphicsState instance that stores information about the current graphic state. Restores the graphics state to the specified graphics state. The saved graphics state. Performs scaling transformations. The scaling facto by x coordinate. The scaling facto by y coordinate. The order. Sets the current clip region. The path specifying the clip region. The combining mode. Sets the current clip region. The rectangle specifying the new clip region. The combining mode. Sets the current clip region. The region. The combining mode. Updates the clip region of this Graphics object to exclude the area specified by a Rectangle structure. Rectangle structure that specifies the rectangle to exclude from the clip region. Updates the clip region of this Graphics object to exclude the area specified by a Region object. Region object that specifies the region to exclude from the clip region. Updates the clip region of this Graphics object to the intersection of the current clip region and the specified RectangleF structure. RectangleF structure to intersect with the current clip region. Updates the clip region of this Graphics object to the intersection of the current clip region and the specified Region object. Region object to intersect with the current region. Transforms points. Destination space. Source space. Array of points. Sets the current rendering origin. The origin. Sets the specified transformation matrix. The matrix. Performs translate transformation of the graphics. The offset by the x coordinate. The offset by the y coordinate. The order of the matrix operations. Is called when the metafile parsing have been started. Is called when the metafile is at the end. Raises when error occured during metafile parsing. Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. Sets location / bounds for metafile object. Location of the metafile. Size of the metafile. Sets the Boundaries box. The bounds. Sets transformation matrix. Sets clip region. Sets clip region. Extracts fill mode of the path. Graphics path. Fill mode of the path. Gets clip path for the graphics. Gets PDF font for the text. Text to be printed. Font which will be used for printing. PDF font object. Called when we need to draw a primitive. Called when the graphics state was changed. Draws the cap. The cap. The points. The Start point index. The end point index. The width. The brush. Draws the customarrow end cap in the line Calculates scaling factor for text that fits to the specifiedboundaries. String text to be scaled. Font object. Text' boundaries. Size of the text. The format. The scaling factor. Converts GraphicsUnits to PrintUnits. returns PrintUnits Converts the .NET pen to a PDF pen. The pen. The alpha channel value. The proper PDF pen. Converts a .NET brush into a PDF brush. The brush. The alpha channel value. The proper PdfBrush class instance. Checks the alpha. The bitmap. The proper transparency mask. Checks if the alpha channel is present. The flags. The bitmap. The array. The proper mask. Converts a .NET hatch brush to a PDF tiling brush. The hatch brush. The alpha channel value. The well formed PdfBrush instance. Converts the .NET colors to PdfColor array. The colors. The well formed PdfColor array. Gets the brush from pen. The PDF pen. The brush initialized from pen parameters. Converts the System.Drawing.StringFormat format to Syncfusion.Pdf.Graphics.PdfStringFormat format. The format. Proper Syncfusion.Pdf.Graphics.PdfStringFormat format. Gets the type of the wrap. The string format flags. Proper StringWrapType value. Converts the line alignment. The string alignment. The proper VerticalAlignment value. Converts the alingnmet. The string alignment. The proper TextAlignment value. Converts a .NET pen to a PDF pen and sets transparency. The pen. Converts a .NET brush to a PDF brush and sets transparency. The brush. Internally resets clip region. Internally resets transformation. Draws custom cap. Pen used to draw cap. Path points. Custom points for cap. Indicates whether cap is start. Checks is points line or not. Points to be check. Is points line or not. Converts a System.Drawing.Drawing2D.LineCap value to the Syncfusion.Pdf.Graphics.LineCap. The cap value. Syncfusion.Pdf.Graphics.LineCap type value. Converts a System.Drawing.Drawing2D.LineJoin values to respective Syncfusion.Pdf.Graphics.LineJoin values. The join value. Proper Syncfusion.Pdf.Graphics.LineJoin value. Converts a System.Drawing.Drawing2D.DashStyle dash style to the corresponding Syncfusion.Pdf.Graphics.DashStyle dash style. The dash style. Proper Syncfusion.Pdf.Graphics.DashStyle value. Prepares a matrix to PDF. The matrix. A properly prepared PdfTransformationMatrix class instance. Prepares a matrix to PDF. The matrix. The page scale value. A properly prepared PdfTransformationMatrix class instance. Draws the cross brush pattern. The graphics. The pen. Size of the brush. Draws the backward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws the forward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws the horizontal brush pattern. The graphics. The pen. Size of the brush. Draws the vertical pattern. The graphics. The pen. Size of the brush. Draws the downward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws Weave style. Pdf Graphics on which style draws. Pdf pen which draws style. The size of the brush. Draws the upward diagonal brush pattern. The graphics. The pen. Size of the brush. Draws the brick tails for the brick pattern. The graphics. The pen. Size of the brush. Draws the horizontal brick pattern. The graphics. The pen. Size of the brush. Draws a checker board dash pattern. The graphics. The pen. Size of the brush. Size of the cell. Locates the font file. The font. Not the best way, but will work in most cases incase font substitution fails. Gets the font suffix. The fs. Check whether solid brush is empty color Gets or sets the complex script layouting. Gets or sets the custom font collection. Get or Sets transparency is applied or not. Get or Sets the alpha pen Get or Sets the alpha brush. Get or Sets the Blend mode. get or set the bool value to to idetenctical image get or set the PdfDocument Gets the PDF graphics object. Gets the native graphics object. Gets the clip bounds. Gets or sets transformation of graphics. Gets or sets the scaling between world units and page units for this Graphics object. Gets or sets the unit of measure used for page coordinates in this Graphics object. Gets the unit converter for X axis. Gets the unit converter for Y axis. Gets or sets a value indicating whether [page transformed]. true if [page transformed]; otherwise, false. Gets a value indicating whether [embed fonts]. true if [embed fonts]; otherwise, false. Gets text region manager Gets or sets context of the parser. Gets or Sets real clip value Gets or Sets to recreate inner metafile Region of the space which text in metafile can take. Y co-ordinate of the region. Height of the region. Creates new text region object. Creates new text region object. Gets or sets Y co-ordinate of the region when the text starts. Gets or sets Height of the text region. Joins two regions. Text region to be joined. Text region to be joined. Joined region. Checks whether region intersect with the current one. Region object. True - if they're intersected, False - otherwise. Gets or sets Y co-ordinate of the region when the text starts. Gets or sets Height of the text region. Manages TextRegion objects. Collection of the regions. Creates new object. Adds a text region into the collection. Searches for the largest Y co-ordinate of the region if the y is inside of any region or returns y if it's out of any region. Y co-ordinate of some text region. Searches for the largest Y co-ordinate of the region if the y is inside of any region or returns y if it's out of any region. Searches for the last before text region. Y co-ordinate of some text region. Returns the Y co-ordinate of last before text region. Clears the collection. Searches for all regions in the collection that are intersested with the current one. Current text region. Array of regions that intersect with the current. Removes region from the colection. Region that should be removed from he collection. Removes regions from the colection. Array of regions that should be removed from he collection. Joins array of regions and the region into one region. Array of the regions. Current text region. Type of the object. Invalid object type. Brush object. Pen object. Path object. Region object. Image object. Font object. String format object. Image attributes object. Custom line cap object. Type of the brush. Default value. Hatch brush. Texture brush. Path gradient brush. Linear gradient brush. Flags for a linear gradient brush. Minimal data are present. The brush applies a transformation matrix to the source image. The brush contains a ColorBlend object for use with its InterpolationColors property. The brush contains a Blend object for use with its Blend property. The brush has a non-default value for the FocusScales property. The brush uses gamma correction. Represents pen flags. Pen just with color set. Transformation set. (20-... - float ) StartCap set. ( 20 - int ) EndCap set. ( 20 - int ) LineJoin set. ( 20 - int ) MiterLimit set. ( 20 - float ) Pen has DashStyle defined. DashCap set. ( 20 - int ) DashOffset is defined. (20 - float) DashPattern is defined. (20 - int: numArray; 24-... - float: DashPattern ) Alignment set. (20 - int ) CompoundArray set. (20 - int: numArray; 24-... - float: compoundArray ) The pen uses a custom start cap. The pen uses a custom end cap. Indicates types of the images in the Object record. Unknown format. Bitmap image. Metafile image. Initial state of the region. Region is from rectangle. Region is from graphics path. Region is empty. Region is infinity. Default compression. Uses JBIG2 compression for monochrome TIFF images. The contains methods and properties to handle the Bitmap images //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represents the base class for images and provides functionality for the class //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromFile("Autumn Leaves.jpg"); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromFile("Autumn Leaves.jpg") 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) The stream containing image data. The size of the image in points. Horizontal image resolution. Vertical image resolution. Holds mask type flag. Holds list of color space Creates from the specified file.. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. A string that contains the name of the file from which to create the Returns a created PdfImage object. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromFile("Autumn Leaves.jpg"); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromFile("Autumn Leaves.jpg") 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Creates PdfImage from the specified data stream.. A Stream that contains the data for this . Returns a created PdfImage object. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromStream(File.OpenRead("Autumn Leaves.jpg")); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromStream(File.OpenRead("Autumn Leaves.jpg")) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Creates a from the existing . This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The from which to create the new . Returns a created PdfImage object. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load image from file Image picture = Image.FromFile("Autumn Leaves.jpg"); //Load the image from the Image object PdfImage image = PdfImage.FromImage(picture); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load image from file Dim picture As Image = Image.FromFile("Autumn Leaves.jpg") 'Load the image from the Image object Dim image As PdfImage = PdfImage.FromImage(picture) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Creates a new image instance from RTF text with the specified RTF text, width and image type This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The RTF text from which to create the new Width of the image in points. Type of the image that should be created. PdfImage containing RTF text. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; string rtfData = @"{\rtf1\ansi\deff0 {\colortbl;\red0\green0\blue0;\red255\green0\blue0; }Default Color\line\cf2Red Color\line\cf1Default Color}"; //Load image from rtf data. PdfImage image = PdfImage.FromRtf(rtfData, 200, PdfImageType.Bitmap) //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics Dim rtfData As String = "{\rtf1\ansi\deff0 {\colortbl;\red0\green0\blue0;\red255\green0\blue0; }Default Color\line\cf2Red Color\line\cf1Default Color}" 'Load image from rtf data. Dim Image As PdfImage = PdfImage.FromRtf(rtfData, 200, PdfImageType.Bitmap) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Creates a new image instance from RTF text with the specified RTF text, width, height and image type This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The RTF text from which to create the new . Width of the image in points. Height of the image in points. Type of the image that should be created. PdfImage containing RTF text. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; string rtfData = @"{\rtf1\ansi\deff0 {\colortbl;\red0\green0\blue0;\red255\green0\blue0; }Default Color\line\cf2Red Color\line\cf1Default Color}"; //Load image from rtf data. PdfImage image = PdfImage.FromRtf(rtfData, 200, 200, PdfImageType.Bitmap) //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics Dim rtfData As String = "{\rtf1\ansi\deff0 {\colortbl;\red0\green0\blue0;\red255\green0\blue0; }Default Color\line\cf2Red Color\line\cf1Default Color}" 'Load image from rtf data. Dim Image As PdfImage = PdfImage.FromRtf(rtfData, 200, 200, PdfImageType.Bitmap) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Checks the stream existence. The stream. The stream if it exists. It's thrown if the stream is null. Calculates the width and height of the image. Width of the image in points. Height of the image in points. Calculates the width and height of the image. Saves the image into stream. Sets the content stream. The content. Draws an element on the Graphics. Graphics context where the element should be printed. Gets bounds of image. The DPI is standard, not image DPI. Bounds of image. Calculates size of the image in points. Width in pixels. Height in pixels. size of the image in points. Calculates size of the image in points. Width in pixels. Height in pixels. Horizontal resolution. Vertical resolution. size of the image in points. Sets resolution of the image. Horizontal resolution of the image. Vertical resolution of the image. Gets the height of the image in pixels (Read only). The height of the image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromFile("Autumn Leaves.jpg"); //Get image width. float imageWidth = image.Width; //Get image height. float imageHeight = image.Height; //Get the horizontal resolution. float hResolution = image.HorizontalResolution; //Get the vertical resolution. float vResolution = image.VerticalResolution; //Get the image physical dimension. SizeF dimenstion = image.PhysicalDimension; Console.WriteLine("Image width :" + imageWidth); Console.WriteLine("Image height :" + imageHeight); Console.WriteLine("Horizontal resolution :" + hResolution); Console.WriteLine("Vertical resolution :" + vResolution); Console.WriteLine("Physical dimension :" + dimenstion); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromFile("Autumn Leaves.jpg") 'Get image width. Dim imageWidth As Single = image.Width 'Get image height. Dim imageHeight As Single = image.Height 'Get the horizontal resolution. Dim hResolution As Single = image.HorizontalResolution 'Get the vertical resolution. Dim vResolution As Single = image.VerticalResolution 'Get the image physical dimension. Dim dimenstion As SizeF = image.PhysicalDimension Console.WriteLine("Image width :" + imageWidth) Console.WriteLine("Image height :" + imageHeight) Console.WriteLine("Horizontal resolution :" + hResolution) Console.WriteLine("Vertical resolution :" + vResolution) Console.WriteLine("Physical dimension :" + dimenstion) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the width of the image in pixels (Read only). The width of the image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromFile("Autumn Leaves.jpg"); //Get image width. float imageWidth = image.Width; //Get image height. float imageHeight = image.Height; //Get the horizontal resolution. float hResolution = image.HorizontalResolution; //Get the vertical resolution. float vResolution = image.VerticalResolution; //Get the image physical dimension. SizeF dimenstion = image.PhysicalDimension; Console.WriteLine("Image width :" + imageWidth); Console.WriteLine("Image height :" + imageHeight); Console.WriteLine("Horizontal resolution :" + hResolution); Console.WriteLine("Vertical resolution :" + vResolution); Console.WriteLine("Physical dimension :" + dimenstion); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromFile("Autumn Leaves.jpg") 'Get image width. Dim imageWidth As Single = image.Width 'Get image height. Dim imageHeight As Single = image.Height 'Get the horizontal resolution. Dim hResolution As Single = image.HorizontalResolution 'Get the vertical resolution. Dim vResolution As Single = image.VerticalResolution 'Get the image physical dimension. Dim dimenstion As SizeF = image.PhysicalDimension Console.WriteLine("Image width :" + imageWidth) Console.WriteLine("Image height :" + imageHeight) Console.WriteLine("Horizontal resolution :" + hResolution) Console.WriteLine("Vertical resolution :" + vResolution) Console.WriteLine("Physical dimension :" + dimenstion) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the horizontal resolution, in pixels per inch, of this Image (Read only). The horizontal resolution of the image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromFile("Autumn Leaves.jpg"); //Get image width. float imageWidth = image.Width; //Get image height. float imageHeight = image.Height; //Get the horizontal resolution. float hResolution = image.HorizontalResolution; //Get the vertical resolution. float vResolution = image.VerticalResolution; //Get the image physical dimension. SizeF dimenstion = image.PhysicalDimension; Console.WriteLine("Image width :" + imageWidth); Console.WriteLine("Image height :" + imageHeight); Console.WriteLine("Horizontal resolution :" + hResolution); Console.WriteLine("Vertical resolution :" + vResolution); Console.WriteLine("Physical dimension :" + dimenstion); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromFile("Autumn Leaves.jpg") 'Get image width. Dim imageWidth As Single = image.Width 'Get image height. Dim imageHeight As Single = image.Height 'Get the horizontal resolution. Dim hResolution As Single = image.HorizontalResolution 'Get the vertical resolution. Dim vResolution As Single = image.VerticalResolution 'Get the image physical dimension. Dim dimenstion As SizeF = image.PhysicalDimension Console.WriteLine("Image width :" + imageWidth) Console.WriteLine("Image height :" + imageHeight) Console.WriteLine("Horizontal resolution :" + hResolution) Console.WriteLine("Vertical resolution :" + vResolution) Console.WriteLine("Physical dimension :" + dimenstion) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the vertical resolution, in pixels per inch, of this Image (Read only). The vertical resolution of the image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromFile("Autumn Leaves.jpg"); //Get image width. float imageWidth = image.Width; //Get image height. float imageHeight = image.Height; //Get the horizontal resolution. float hResolution = image.HorizontalResolution; //Get the vertical resolution. float vResolution = image.VerticalResolution; //Get the image physical dimension. SizeF dimenstion = image.PhysicalDimension; Console.WriteLine("Image width :" + imageWidth); Console.WriteLine("Image height :" + imageHeight); Console.WriteLine("Horizontal resolution :" + hResolution); Console.WriteLine("Vertical resolution :" + vResolution); Console.WriteLine("Physical dimension :" + dimenstion); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromFile("Autumn Leaves.jpg") 'Get image width. Dim imageWidth As Single = image.Width 'Get image height. Dim imageHeight As Single = image.Height 'Get the horizontal resolution. Dim hResolution As Single = image.HorizontalResolution 'Get the vertical resolution. Dim vResolution As Single = image.VerticalResolution 'Get the image physical dimension. Dim dimenstion As SizeF = image.PhysicalDimension Console.WriteLine("Image width :" + imageWidth) Console.WriteLine("Image height :" + imageHeight) Console.WriteLine("Horizontal resolution :" + hResolution) Console.WriteLine("Vertical resolution :" + vResolution) Console.WriteLine("Physical dimension :" + dimenstion) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the size of the image in points (Read only). The size of the image in points This property uses HorizontalResolution and VerticalResolution for calculating the size in points. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfImage image = PdfImage.FromFile("Autumn Leaves.jpg"); //Get image width. float imageWidth = image.Width; //Get image height. float imageHeight = image.Height; //Get the horizontal resolution. float hResolution = image.HorizontalResolution; //Get the vertical resolution. float vResolution = image.VerticalResolution; //Get the image physical dimension. SizeF dimenstion = image.PhysicalDimension; Console.WriteLine("Image width :" + imageWidth); Console.WriteLine("Image height :" + imageHeight); Console.WriteLine("Horizontal resolution :" + hResolution); Console.WriteLine("Vertical resolution :" + vResolution); Console.WriteLine("Physical dimension :" + dimenstion); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As PdfImage = PdfImage.FromFile("Autumn Leaves.jpg") 'Get image width. Dim imageWidth As Single = image.Width 'Get image height. Dim imageHeight As Single = image.Height 'Get the horizontal resolution. Dim hResolution As Single = image.HorizontalResolution 'Get the vertical resolution. Dim vResolution As Single = image.VerticalResolution 'Get the image physical dimension. Dim dimenstion As SizeF = image.PhysicalDimension Console.WriteLine("Image width :" + imageWidth) Console.WriteLine("Image height :" + imageHeight) Console.WriteLine("Horizontal resolution :" + hResolution) Console.WriteLine("Vertical resolution :" + vResolution) Console.WriteLine("Physical dimension :" + dimenstion) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Holds list of color space An array of component values specifying the matte color with which the image data in the parent image has been preblended. The array consists of numbers, where n is the number of components in the color space specified by the ColorSpace entry in the parent images image dictionary; the numbers must be valid color components in that color space. Gets the image. The image. Gets the image stream. Gets the mask type. true if soft mask; otherwise, hard mask false. Gets the wrapped element. Gets or sets Xmp metadata of the image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk with enable metadata extraction. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg", true); //Get image metadata XmpMetadata metadata = image.Metadata; //Create custom schema. CustomSchema customSchema = new CustomSchema(metadata, "custom", "http://www.syncfusion.com"); customSchema["Author"] = "Syncfusion"; customSchema["creationDate"] = DateTime.Now.ToString(); customSchema["DOCID"] = "SYNCSAM001"; //Set image metadata image.Metadata = metadata; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk with enable metadata extraction. Dim image As New PdfBitmap("Autumn Leaves.jpg", true) 'Get image metadata Dim metadata As XmpMetadata = image.Metadata //Create custom schema. Dim customSchema As New CustomSchema(metadata, "custom", "http://www.syncfusion.com") customSchema("Author") = "Syncfusion" customSchema("creationDate") = DateTime.Now.ToString() customSchema("DOCID") = "SYNCSAM001" 'Set image metadata image.Metadata = metadata 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Start of image marker. JFIF marker. Start of scan marker. End of image marker. Holds image. Holds the index of active frame for multiframe images. Holds image frame dimention. Holds mask for current image. Holds bits per component. Holds image color space. A flag indicating whether the image is to be treated as an image mask. Holds list of saved frames. Indicates if the object has been disposed. The quality of the stored image. When the image is stored into PDF not as a mask, you may reduce its quality, which saves the disk space. Internal variable to store the check value. Holds the raw image stream Indicates whether the quality is set to custom. Initializes a new instance of the class from the specified existing image. The from which to create the new Bitmap. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load image from file Image picture = Image.FromFile("Autumn Leaves.jpg"); //Load the image from the Image object PdfBitmap image = new PdfBitmap(picture); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load image from file Dim picture As Image = Image.FromFile("Autumn Leaves.jpg") 'Load the image from the Image object Dim image As New PdfBitmap(picture) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class from the specified file. The bitmap file name and path. The file name and path can be relative to the application or an absolute path. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk with enable metadata extraction. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg", true); //Get image metadata XmpMetadata metadata = image.Metadata; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk with enable metadata extraction. Dim image As New PdfBitmap("Autumn Leaves.jpg", true) 'Get image metadata Dim metadata As XmpMetadata = image.Metadata 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class from the specified file. The bitmap file name and path. Enable metadata extraction from image The file name and path can be relative to the application or an absolute path. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg", true); //Get image metadata XmpMetadata metadata = image.Metadata; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As New PdfBitmap("Autumn Leaves.jpg", true) 'Get image metadata Dim metadata As XmpMetadata = image.Metadata 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class from the specified data stream. The data stream used to load the image. /// //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the stream PdfBitmap image = new PdfBitmap(File.OpenRead("Autumn Leaves.jpg")); //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the stream Dim image As New PdfBitmap(File.OpenRead("Autumn Leaves.jpg")) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class from the specified file. The data stream used to load the image. Enable metadata extraction from image The file name and path can be relative to the application or an absolute path. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk with enable metadata extraction. PdfBitmap image = new PdfBitmap(File.OpenRead("Autumn Leaves.jpg"), true); //Get image metadata XmpMetadata metadata = image.Metadata; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk with enable metadata extraction. Dim image As New PdfBitmap(File.OpenRead("Autumn Leaves.jpg"), true) 'Get image metadata Dim metadata As XmpMetadata = image.Metadata 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection. Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Draw the image graphics.DrawImage(image, 0, 0); //Dispose the image object. image.Dispose(); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Draw the image graphics.DrawImage(image, 0, 0) 'Dispose the image object. image.Dispose() 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Disposes the specified disposing. if it is disposing, set to true. Saves the image into stream. Gets the bits per pixel. The pixel format of the image. Number of bits per pixel Gets the encoder info. Type of the MIME. Saves the image as JPG. Saves the current image as pixel matrix. Gets the color space from image stream. Memory stream of image. Color space. Sets the mask for image. Saves the required items. Creates the mask from ARGB image. The ARGB image. Creates the mask from an indexed image. The image. The proper greyscale image, which represents the mask. Saves the image by pixel format. Saves the image. The image filters. Sets the color space. Saves the additional items. Checks if frame was saved already. The frame index. true if frame was saved, otherwise false. Get or sets the Check Value. Gets or sets the active frame of the image. The index of the active frame. //Create a PDF document PdfDocument pdfDocument = new PdfDocument(); //Add a section to the PDF document PdfSection section = pdfDocument.Sections.Add(); //Declare the PDF page PdfPage page; //Declare PDF page graphics PdfGraphics graphics; //Load multi frame Tiff image PdfBitmap tiffImage = new PdfBitmap("image.tiff"); //Get the frame count int frameCount = tiffImage.FrameCount; //Access each frame draw into the page for (int i = 0; i!=frameCount-1; i++) { page = section.Pages.Add(); section.PageSettings.Margins.All = 0; graphics = page.Graphics; tiffImage.ActiveFrame = i; graphics.DrawImage(tiffImage, 0, 0, page.GetClientSize().Width, page.GetClientSize().Height); } //Save and close the document pdfDocument.Save("Sample.pdf"); pdfDocument.Close(true); 'Create a PDF document///Dim pdfDocument As New PdfDocument() 'Add a section to the PDF document Dim section As PdfSection = pdfDocument.Sections.Add() 'Declare the PDF page Dim page As PdfPage 'Declare PDF page graphics Dim graphics As PdfGraphics 'Load multi frame Tiff image Dim tiffImage As New PdfBitmap("image.tiff") 'Get the frame count Dim frameCount As Integer = tiffImage.FrameCount 'Access each frame draw into the page For i As Integer = 0 To frameCount - 1 page = section.Pages.Add() section.PageSettings.Margins.All = 0 graphics = page.Graphics tiffImage.ActiveFrame = i graphics.DrawImage(tiffImage, 0, 0, page.GetClientSize().Width, page.GetClientSize().Height) Next 'Save and close the document pdfDocument.Save("Sample.pdf") pdfDocument.Close(True) Gets the number of frames in the bitmap (Read only). The frame count of the image. //Create a PDF document PdfDocument pdfDocument = new PdfDocument(); //Add a section to the PDF document PdfSection section = pdfDocument.Sections.Add(); //Declare the PDF page PdfPage page; //Declare PDF page graphics PdfGraphics graphics; //Load multi frame Tiff image PdfBitmap tiffImage = new PdfBitmap("image.tiff"); //Get the frame count int frameCount = tiffImage.FrameCount; //Access each frame draw into the page for (int i = 0; i!=frameCount-1; i++) { page = section.Pages.Add(); section.PageSettings.Margins.All = 0; graphics = page.Graphics; tiffImage.ActiveFrame = i; graphics.DrawImage(tiffImage, 0, 0, page.GetClientSize().Width, page.GetClientSize().Height); } //Save and close the document pdfDocument.Save("Sample.pdf"); pdfDocument.Close(true); 'Create a PDF document///Dim pdfDocument As New PdfDocument() 'Add a section to the PDF document Dim section As PdfSection = pdfDocument.Sections.Add() 'Declare the PDF page Dim page As PdfPage 'Declare PDF page graphics Dim graphics As PdfGraphics 'Load multi frame Tiff image Dim tiffImage As New PdfBitmap("image.tiff") 'Get the frame count Dim frameCount As Integer = tiffImage.FrameCount 'Access each frame draw into the page For i As Integer = 0 To frameCount - 1 page = section.Pages.Add() section.PageSettings.Margins.All = 0 graphics = page.Graphics tiffImage.ActiveFrame = i graphics.DrawImage(tiffImage, 0, 0, page.GetClientSize().Width, page.GetClientSize().Height) Next 'Save and close the document pdfDocument.Save("Sample.pdf") pdfDocument.Close(True) Gets or sets the mask of bitmap. New PdfMask represents the mask image. //Create a PDF document PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the Tiff image PdfBitmap image = new PdfBitmap("image.tif"); //Create masking image PdfImageMask mask = new PdfImageMask(new PdfBitmap("mask.bmp")); image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Saves the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the Tiff image Dim image As New PdfBitmap("image.tif") 'Create masking image Dim mask As New PdfImageMask(New PdfBitmap("mask.bmp")) image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Saves the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets the quality of the image. When the image is stored into PDF not as a mask, you may reduce its quality, which saves the disk space. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the image from the disk. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Set image quality. image.Quality = 50; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the image from the disk. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Set image quality. image.Quality = 50 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the image. Represents the color mask for Bitmap images. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load image from file Image picture = Image.FromFile("Autumn Leaves.jpg"); //Load the image from the Image object PdfBitmap image = new PdfBitmap(picture); //Create a color mask PdfColorMask mask = new PdfColorMask(new PdfColor(Color.Red), new PdfColor(Color.Aqua)); //Apply a mask to the image image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load image from file Dim picture As Image = Image.FromFile("Autumn Leaves.jpg") 'Load the image from the Image object Dim image As New PdfBitmap(picture) 'Create a color mask Dim mask As New PdfColorMask(New PdfColor(Color.Red), New PdfColor(Color.Aqua)) 'Apply a mask to the image image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Base class for bitmap masking objects. //Create a PDF document PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the Tiff image PdfBitmap image = new PdfBitmap("image.tif"); //Create masking image PdfMask mask = new PdfImageMask(new PdfBitmap("mask.bmp")); image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Saves the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the Tiff image Dim image As New PdfBitmap("image.tif") 'Create masking image Dim mask As New PdfImageMask(New PdfBitmap("mask.bmp")) image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Saves the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Holds start color of color mask. Holds end color of color mask. Initializes a new instance of the class with the specified start and end color The start color of the color mask. The end color of the color mask. //Create a new PDF document.///PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load image from file Image picture = Image.FromFile("Autumn Leaves.jpg"); //Load the image from the Image object PdfBitmap image = new PdfBitmap(picture); //Create a color mask PdfColorMask mask = new PdfColorMask(new PdfColor(Color.Red), new PdfColor(Color.Aqua)); //Apply a mask to the image image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load image from file Dim picture As Image = Image.FromFile("Autumn Leaves.jpg") 'Load the image from the Image object Dim image As New PdfBitmap(picture) 'Create a color mask Dim mask As New PdfColorMask(New PdfColor(Color.Red), New PdfColor(Color.Aqua)) 'Apply a mask to the image image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the start color of the mask. The which represents the starting color of the color mask. //Create a new PDF document.///PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load image from file Image picture = Image.FromFile("Autumn Leaves.jpg"); //Load the image from the Image object PdfBitmap image = new PdfBitmap(picture); //Create a color mask PdfColorMask mask = new PdfColorMask(new PdfColor(Color.Red), new PdfColor(Color.Aqua)); //Set start color. mask.StartColor = new PdfColor(Color.Green); //Set end color. mask.EndColor = new PdfColor(Color.Red); //Apply a mask to the image image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load image from file Dim picture As Image = Image.FromFile("Autumn Leaves.jpg") 'Load the image from the Image object Dim image As New PdfBitmap(picture) 'Create a color mask Dim mask As New PdfColorMask(New PdfColor(Color.Red), New PdfColor(Color.Aqua)) 'Set start color. mask.StartColor = New PdfColor(Color.Green) 'Set end color. mask.EndColor = New PdfColor(Color.Red) 'Apply a mask to the image image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the end color of the mask. The which represents the ending color of the color mask. //Create a new PDF document.///PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load image from file Image picture = Image.FromFile("Autumn Leaves.jpg"); //Load the image from the Image object PdfBitmap image = new PdfBitmap(picture); //Create a color mask PdfColorMask mask = new PdfColorMask(new PdfColor(Color.Red), new PdfColor(Color.Aqua)); //Set start color. mask.StartColor = new PdfColor(Color.Green); //Set end color. mask.EndColor = new PdfColor(Color.Red); //Apply a mask to the image image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load image from file Dim picture As Image = Image.FromFile("Autumn Leaves.jpg") 'Load the image from the Image object Dim image As New PdfBitmap(picture) 'Create a color mask Dim mask As New PdfColorMask(New PdfColor(Color.Red), New PdfColor(Color.Aqua)) 'Set start color. mask.StartColor = New PdfColor(Color.Green) 'Set end color. mask.EndColor = New PdfColor(Color.Red) 'Apply a mask to the image image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Represents the image mask object for bitmap images. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create a PDF document PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the Tiff image PdfBitmap image = new PdfBitmap("image.tif"); //Create masking image PdfImageMask mask = new PdfImageMask(new PdfBitmap("mask.bmp")); image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Saves the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the Tiff image Dim image As New PdfBitmap("image.tif") 'Create masking image Dim mask As New PdfImageMask(New PdfBitmap("mask.bmp")) image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Saves the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Holds mask image. Holds mask type flag. Initializes a new instance of the PdfImageMask class from the specified This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The PdfBitmap which represents the image //Create a PDF document PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the Tiff image PdfBitmap image = new PdfBitmap("image.tif"); //Create masking image PdfImageMask mask = new PdfImageMask(new PdfBitmap("mask.bmp")); image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Saves the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the Tiff image Dim image As New PdfBitmap("image.tif") 'Create masking image Dim mask As New PdfImageMask(New PdfBitmap("mask.bmp")) image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Saves the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets the image mask for the bitmap (Read only). This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The represents the image mask. //Create a PDF document PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the Tiff image PdfBitmap image = new PdfBitmap("image.tif"); //Create masking image PdfImageMask mask = new PdfImageMask(new PdfBitmap("mask.bmp")); //Get the mask image. PdfBitmap maskedImage = mask.Mask; image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Saves the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the Tiff image Dim image As New PdfBitmap("image.tif") 'Create masking image Dim mask As New PdfImageMask(New PdfBitmap("mask.bmp")) 'Get the mask image. Dim maskedImage As PdfBitmap = mask.Mask image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Saves the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets the mask type for the bitmap (Read only). This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. true if soft mask; otherwise, hard mask false. //Create a PDF document PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Load the Tiff image PdfBitmap image = new PdfBitmap("image.tif"); //Create masking image PdfImageMask mask = new PdfImageMask(new PdfBitmap("mask.bmp")); //Check soft mask. bool isSoftMask = mask.SoftMask; image.Mask = mask; //Draw the image graphics.DrawImage(image, 0, 0); //Saves the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Load the Tiff image Dim image As New PdfBitmap("image.tif") 'Create masking image Dim mask As New PdfImageMask(New PdfBitmap("mask.bmp")) 'Check soft mask. Dim isSoftMask As Boolean = mask.SoftMask image.Mask = mask 'Draw the image graphics.DrawImage(image, 0, 0) 'Saves the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Class representing metafile image This API is not supported in WinRT, Windows Phone, ASP.NET Core, Xamarin, Universal Windows Platform and Silverlight. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Holds image. Holds template for metafile. Indicates if the metafile has been parsed. Contains the information about the text regions in the metafile. Contains the information about the image regions in the metafile. Indicates if the object has been disposed. Indicates whether we should dispose image or not. Indicates the quality of the image. Indicates the image resolution Contains the html hyperlink Contains document links. Contains form's input elements. Contains select elements. Contains button elements. Internal varible to store the alpha pen. Internal varible to store the alpha brush. Internal varible to store tranaparency is applied or not. Internal varible to store the pdf blend mode. Internal variable to store current pdf document internal variable to store identical image collection Internal variable to store ShapeLayoutBounds Check whether the metafile has PdfGrid internal variable to store GridbottomCellpadding Indicates whether the metafile rendered by complex script layout. Initializes a new instance of the class with This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The metafile. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; Metafile metaFile = new Metafile("MetaChart.emf"); //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile(metaFile); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True Dim metaFile As New Metafile("MetaChart.emf") 'Create a Metafile instance Dim metaChart As New PdfMetafile(metaFile) 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Initializes a new instance of the class with metafile path This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The metafile path. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Initializes a new instance of the class from stream of the metafile This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The stream. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; byte[] data = File.ReadAllBytes("MetaChart.emf"); //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile(new MemoryStream(data)); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True Dim data As Byte() = File.ReadAllBytes("MetaChart.emf") 'Create a Metafile instance Dim metaChart As New PdfMetafile(New MemoryStream(data)) 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection. Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Dispose the metafile. metaChart.Dispose(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Dispose the metafile. metaChart.Dispose() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Disposes the specified disposing. if it is disposing, set to true. Saves the image into stream. This methods prepares a PDF template (XObject) for saving and drawing. Layouts the element. Layout parameters. Returns lay outing results. Layouts the HtmlToPdf element. Layout parameters. Returns lay outing results. Checks the format of the metafile. Converts it to supported format. Input metafile. Resulted metafile. Converts WMF/EmfPlusDual metafile to EMF metafile. WMF/EmfPlusDual metafile. EMF metafile converted from WMF/EmfPlusDual metafile. Sets the transparency. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The alpha value for pen operations. The alpha value for brush operations. The blend mode. Transparency is applied or not. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Set transparency. metaChart.SetTransparency(0.5f, 0.5f, PdfBlendMode.Overlay, true); //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Set transparency. metaChart.SetTransparency(0.5F, 0.5F, PdfBlendMode.Overlay, True) 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets the text complex script layouting. Get or Sets transparency is applied or not. Get or Sets the alpha pen Get or Sets the alpha brush. Get or Sets the Blend mode. Gets the image. The image. Gets the information about the text regions in the metafile. Gets the information about the image regions in the metafile. Returns the internal template. get or set the PdfDocument get or set the bool value to to idetenctical image get or set the bool value to to embed font get or set the bool value to to embed complete font Gets or sets the quality of the image. When the image is stored into PDF not as a mask, you may reduce its quality, which saves the disk space. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Set image quality. metaChart.Quality = 10; //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Set image quality. metaChart.Quality = 10 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets the resolution of the image This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Set image resolution. metaChart.ImageResolution = 72; //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Set image resolution. metaChart.ImageResolution = 72 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Contains the html hyperlink collection. Used during html to pdf conversion to preserve live-links. Contains document links. Contains Input Elements. Contains List elements. Contains List elements. Gets or sets the page scale. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The page scale. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Set page scale. metaChart.PageScale = 1.2f; //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Set page scale. metaChart.PageScale = 1.2F 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets the page graphics unit. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The page unit. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create the layout format PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); //Split text and image between pages format.SplitImages = true; format.SplitTextLines = true; //Create a Metafile instance PdfMetafile metaChart = new PdfMetafile("MetaChart.emf"); //Set the page unit. metaChart.PageUnit = GraphicsUnit.Point; //Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create the layout format Dim format As New PdfMetafileLayoutFormat() 'Split text and image between pages format.SplitImages = True format.SplitTextLines = True 'Create a Metafile instance Dim metaChart As New PdfMetafile("MetaChart.emf") 'Set the page unit. metaChart.PageUnit = GraphicsUnit.Point 'Draw the Metafile in the page metaChart.Draw(page, PointF.Empty, format) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Checks whether the image is direct rendering or template based. Get or set current page graphics Gets or Sets to recreate metafile Gets or Sets to detect WordtoPDF metafile rendering Gets or sets the custom font collection. Gets or set the embedded fonts. Summary description for RtfToWmf. Message code. Message code. Message code. Message code. Type object of this class. Rectangle needed for content displaying inside of rich text paint. Creates new object. Converts RTF text to Wmf metafile. RTF text. Width of the text. Height of the text. May be -1. Type of the image. Image created from RTF. Retrieves data from RichTextBox control. RichTectBox control instance. Width of the output. Height of the output. Type of the image. Image created from RTF. Converts rtf to metafile. RichTextBox control. Width of the image. Height of the image. Image from RTF. Converts rtf to metafile. HtmlRichTextBox control. Width of the image. Height of the image. Image from RTF. Converts rtf to bitmap. RichTextBox control. Width of the image. Height of the image. Image from RTF. Draws rtf on the graphics context. RichTextBox control. Graphics context. Bounds of the image. Convert between inches and twips (1/1440 inch, used by Win32 API calls). Value in inches. Value in twips. Convert between inches and twips (1/1440 inch, used by Win32 API calls). Value in inches. Value in twips. Convert between pixels and inches. Value in pixels. Horizontal device resolution. Vertical device resolution. Value in inches.. Determines whether [is valid RTF] [the specified RTF]. The RTF. if it is valid RTF, set to true. Sets RTF text box. Rich text box control. Rtf text. Handles contentsResized event. Sender of the event. Event parameters. Implements structures and routines working with color. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF color. PdfColor color = new PdfColor(Color.Red); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF color. Dim color As New PdfColor(Color.Red) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Max value of color channel. Holds RGB colors converted into strings. Holds Grayscale colors converted into strings for stroking. Holds Grayscale colors converted into strings for filling. Holds the system-wide empty PDF color. Value of Red channel. Value of Cyan channel. Value of Green channel. Value of Magenta channel. Value of Blue channel. Value of Yellow channel. Value of Black channel. Value of Gray channel. Alpha channel. Shows if the color is empty. Initializes a new instance of the class with source color Source color object. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF color. PdfColor color = new PdfColor(new PdfColor(Color.Green)); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF color. Dim color As New PdfColor(New PdfColor(Color.Green)) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Initializes a new instance of the class with object Source color object. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF color. PdfColor color = new PdfColor(Color.Red); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF color. Dim color As New PdfColor(Color.Red) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Initializes a new instance of the class with gray value Gray value. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF color. PdfColor color = new PdfColor(0.5f); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF color. Dim color As New PdfColor(0.5F) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Initializes a new instance of the class with Red,Green and Blue values. Red channel value. Green channel value. Blue channel value. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF color. PdfColor color = new PdfColor(200, 120, 80); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF color. Dim color As New PdfColor(200, 120, 80) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Initializes a new instance of the class. The red colour value in the range from 0.0 to 1.0. The green value in the range from 0.0 to 1.0. The blue value in the range from 0.0 to 1.0. Creates new object. Alpha channel. Red channel value. Green channel value. Blue channel value. Initializes a new instance of the class with Cyan,Magenta,Yellow and Black channels. Cyan channel value. Magenta channel value. Yellow channel value. Black channel value. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF color. PdfColor color = new PdfColor(200, 120, 80, 40); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF color. Dim color As New PdfColor(200, 120, 80, 40) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Creates the Alpha ,Red ,Green, and Blue value of this PDFColor structure. ARGB value. //Create new PDF color. PdfColor color1 = new PdfColor(Color.LightBlue); //Get the ARGB value. int argb = color1.ToArgb(); Console.WriteLine("ARGB: "+ argb); 'Create new PDF color. Dim color1 As New PdfColor(Color.LightBlue) 'Get the ARGB value. Dim argb As Integer = color1.ToArgb() Console.WriteLine("ARGB: " + argb) Implicit operator. System.Drawing.Color. PDFColor. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF color. PdfColor color = System.Drawing.Color.Red; //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF color. Dim color As PdfColor = System.Drawing.Color.Red 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Implicit operator. System.Drawing.Color. PDFColor. //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(200, 120, 80); //Convert PDF color to System color. System.Drawing.Color systemColor = pdfColor; Console.WriteLine("Red: " + systemColor.R + " Green: " + systemColor.G + " Blue: " + systemColor.B); 'Create a new PDF color instance. Dim pdfColor As New PdfColor(200, 120, 80) 'Convert PDF color to System color. Dim systemColor As System.Drawing.Color = pdfColor Console.WriteLine("Red: " + systemColor.R + " Green: " + systemColor.G + " Blue: " + systemColor.B) Operator ==. The color 1. The color 2. True if color 1 is equal to color 2; otherwise False. //Create new PDF color. PdfColor color1 = new PdfColor(Color.Red); PdfColor color2 = new PdfColor(255, 0, 0); //Check both the color are equal. if (color1 == color2) Console.WriteLine("Both the colors are same."); 'Create new PDF color. Dim color1 As New PdfColor(Color.Red) Dim color2 As New PdfColor(255, 0, 0) 'Check both the color are equal. If color1 = color2 Then Console.WriteLine("Both the colors are same.") End If Operator !=. The color 1. The color 2. True if color 1 is not equal to color 2; otherwise False. //Create new PDF color. PdfColor color1 = new PdfColor(Color.Red); PdfColor color2 = new PdfColor(250, 0, 0); //Check both the color are equal. if (color1 != color2) Console.WriteLine("The colors are not same."); 'Create new PDF color. Dim color1 As New PdfColor(Color.Red) Dim color2 As New PdfColor(250, 0, 0) 'Check both the color are equal. If color1 = color2 Then Console.WriteLine("The colors are not same.") End If Determines whether the specified is equal to the current . The to compare with the current . True if the specified is equal to the current ; otherwise - False. //Create new PDF color. PdfColor color1 = new PdfColor(Color.Red); PdfColor color2 = new PdfColor(253, 0, 0); //Check both the color are equal. if(color1.Equals(color2)) Console.WriteLine("Both the colors are same."); 'Create new PDF color. Dim color1 As New PdfColor(Color.Red) Dim color2 As New PdfColor(253, 0, 0) 'Check both the color are equal. If color1.Equals(color2) Then Console.WriteLine("Both the colors are same.") End If Determines if the specified color is equal to this one. The color. True if the color is equal; otherwise - False. //Create new PDF color. PdfColor color1 = new PdfColor(Color.Red); PdfColor color2 = new PdfColor(253, 0, 0); //Check both the color are equal. if(color1.Equals(color2)) Console.WriteLine("Both the colors are same."); 'Create new PDF color. Dim color1 As New PdfColor(Color.Red) Dim color2 As New PdfColor(253, 0, 0) 'Check both the color are equal. If color1.Equals(color2) Then Console.WriteLine("Both the colors are same.") End If Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table. A hash code for the current . Sets RGB color. If color stroking. Result string. Sets Calibrated RGB color. Sets Calibrated Lab color. Sets Calibrated Gray color. Sets Calibrated RGB color. Sets Calibrated CMYK color. Sets Calibrated Lab color. Sets Calibrated Gray color. Sets gray color. If color stroking. Result string. Sets CMYK color. If color stroking. Result string. Writes RGB colour to string builder. The string builder. If set to True stroke. Writes CMYK color to string builder. The string builder. If set to true stroke; otherwise, false. Writes grayscale color to string builder. The string builder. If set to True stroke. Converts PDFColor to PDF string representation. Color space. If color stroking. Result string. Converts PDFColor to PDF string representation. Writes color value to a string builder. The string builder. The color space. If set to True stroke. Converts RGB to CMYK. Red channel value. Green channel value. Blue channel value. Converts CMYK to RGB. Cyan channel value. Magenta channel value. Yellow channel value. Black channel value. Compares colors. The color 1. The color 2. True if colors are identical; otherwise - False. Converts colour to a PDF array of R, G and B float values. Filled PdfArray object. Converts colour to a PDF array. The color space. The well filled PdfArray object. Gets a null color. The empty. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Gets an empty PDF color instance. PdfColor color = PdfColor.Empty; //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(color); //Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Gets an empty PDF color instance. Dim color As PdfColor = PdfColor.Empty 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(color) 'Draw string to PDF page. graphics.DrawString("Hello World!", font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets whether the PDFColor is Empty or not. true if this instance is empty; otherwise, false. //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(Color.Empty); //Check the color. bool isEmpty = pdfColor.IsEmpty; Console.WriteLine("The Color is " + (isEmpty? "empty" : "not empty")); 'Create a new PDF color instance. Dim pdfColor As New PdfColor(Color.Empty) 'Check the color. Dim isEmpty As Boolean = pdfColor.IsEmpty Console.WriteLine("The Color is " + (If(isEmpty, "empty", "not empty"))) Gets or sets Blue channel value. The B. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("SlateBlue"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the blue channel value. string text = "The blue channel value is " + pdfColor.B; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("SlateBlue") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the blue channel value. Dim text As String = "The blue channel value is " + pdfColor.B 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets the blue color // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("Blue"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the blue color value. string text = "The blue color value is " + pdfColor.Blue; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("Blue") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the blue color value. Dim text As String = "The blue color value is " + pdfColor.Blue 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Cyan channel value. The C. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("SlateBlue"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the cyan channel value. string text = "The cyan channel value is " + pdfColor.C; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("SlateBlue") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the cyan channel value. Dim text As String = "The cyan channel value is " + pdfColor.C 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Green channel value. The G. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("LawnGreen"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the green channel value. string text = "The green channel value is " + pdfColor.G; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("LawnGreen") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the green channel value. Dim text As String = "The green channel value is " + pdfColor.G 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets the green value The green. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("Green"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the green color value. string text = "The green color value is " + pdfColor.Green; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("Green") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the green color value. Dim text As String = "The green color value is " + pdfColor.Green 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Gray channel value. The gray. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("DarkSlateGray"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the gray channel value. string text = "The gray channel value is " + pdfColor.Gray; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("DarkSlateGray") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the gray channel value. Dim text As String = "The gray channel value is " + pdfColor.Gray 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Black channel value. The K. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("DarkSlateGray"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the black channel value. string text = "The black channel value is " + pdfColor.K; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("DarkSlateGray") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the black channel value. Dim text As String = "The black channel value is " + pdfColor.K 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Magenta channel value. The M. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("DarkSlateGray"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the megenta channel value. string text = "The megenta channel value is " + pdfColor.M; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("DarkSlateGray") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the megenta channel value. Dim text As String = "The megenta channel value is " + pdfColor.M 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Red channel value. The R. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("Red"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the red channel value. string text = "The red channel value is " + pdfColor.R; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("Red") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the red channel value. Dim text As String = "The red channel value is " + pdfColor.R 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets the red color // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("Red"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the red color value. string text = "The red color value is " + pdfColor.Red; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("Red") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the red color value. Dim text As String = "The red color value is " + pdfColor.Red 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Yellow channel value. The Y. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("YellowGreen"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the yellow channel value. string text = "The yellow channel value is " + pdfColor.Y; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("YellowGreen") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the yellow channel value. Dim text As String = "The yellow channel value is " + pdfColor.Y 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets Alpha channel value. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create color Color color = Color.FromName("DarkSlateGray"); //Create a new PDF color instance. PdfColor pdfColor = new PdfColor(color); //Create new PDF brush. PdfBrush brush = new PdfSolidBrush(pdfColor); //Get the alpha channel value. string text = "The alpha channel value is " + pdfColor.A; //Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create color Dim color As Color = Color.FromName("DarkSlateGray") 'Create a new PDF color instance. Dim pdfColor As New PdfColor(color) 'Create new PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(pdfColor) 'Get the alpha channel value. Dim text As String = "The alpha channel value is " + pdfColor.A 'Draw string to PDF page. graphics.DrawString(text, font, brush, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) This class helps to fill correctly External graphics state dictionary. Gets the element. The Syncfusion.Pdf.Graphics namespace contains classes to render graphics objects Represents a graphics context of the objects. It's used for performing all the graphics operations. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Draw string to PDF page graphics. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Draw the rectangle to PDF page graphics. graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 20, 200, 100)); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Draw string to PDF page graphics. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Draw the rectangle to PDF page graphics. graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 20, 200, 100)) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Specifies the mask of path type values. Check whether it is an emf call Check whether it is an emf plus call check whether to use font size to calculate the shift Check whether it is an emf call Represents the Stream writer object. Represents the Resource container for the graphics. Represents the Size of the canvas. Represents the size of the canvas reduced by margins and templates. Represents the state, whether it is saved or not. Represents the Current pen. Represents the Current brush. Represents the Current font. Represents the Current color space. Indicates whether color space was initialized. Stack of the graphics states. The transformation matrix monitoring all changes with CTM. Stores previous rendering mode. Previous character spacing value or 0. Previous word spacing value or 0. The previously used text scaling value. Holds transparencies used in the graphics. Current string format. Internal variable to store layer on which this graphics lays. Internal variable to store layer on which this graphics PdfLayer. Internal variable to store collection of automatic fields. Internal variable to store layout result after drawing string. Internal variable to store position of split. Indicates whether the object had trasparency. Helps to lock s_mask to avoid race conditions. Helps to lock DrawTemplate in multi threading Emf Text Scaling Factor Check whether it is an emf Text Matrix Identifying the Optimized image To check wihether its a direct text rendering. To store the previous document color spaace. To store the previous graphics color spaace. To check whether the last color space of document and garphics is saved. Stores Text rendering mode. Indicates whether the text rendering mode is set. Shows if the graphics state was changed. Shows if it was the first transformation operation. Shows if the graphics state was restored. Shows if it's the first call to the OnDrawPrimitive method. stores the text clip Indicate whether the Word to PDF DirectConversion. Indicate whether the Word to PDF DirectConversion need to optimize identical Image Indicate variable whether XPS token or not Dictionary hold the XPS replace character token Initializes a new instance of the class. The size. The resources. The stream writer of the current layer. Initializes a new instance of the class. The size. The resources. The stream of the current layer. Draws a rounded rectangle specified by a pen, a brush, a radius and Rectangle structure. A Rectangle structure that represents the rectangle to draw A Radius that determines the curve of ronded rectangle A Pen that determines the color, width, and style of the rectangle. Brush that determines the color and texture of the rectangle Draws a rounded rectangle specified by a pen, a brush, a coordinate pair, a width, and a height. The x-coordinate of the upper-left corner of the rectangle to draw. The y-coordinate of the upper-left corner of the rectangle to draw. Width of the rectangle to draw. Height of the rectangle to draw. A Radius that determines the curve of ronded rectangle A Pen that determines the color, width, and style of the rectangle. Brush that determines the color and texture of the rectangle Draws the specified PdfImage, using its original physical size, at the specified location.. PdfImage to draw. Point structure that represents the location of the upper-left corner of the drawn image. //Creates a new PDF document. PdfDocument doc = new PdfDocument(); //Adds a page to the document. PdfPage page = doc.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics g = page.Graphics; //Creates an image object. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Draws the image. g.DrawImage(image, new PointF(0, 0)); //Saves the document. doc.Save("Output.pdf"); //Closes the document. doc.Close(true); 'Creates a new PDF document. Dim doc As New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Creates PDF graphics for the page. Dim g As PdfGraphics = page.Graphics 'Creates an image object. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Draws the image. g.DrawImage(image,New PointF(0, 0)) 'Saves the document. doc.Save("Output.pdf") 'Closes the document. doc.Close() Draws the specified image, using its original physical size, at the location specified by a coordinate pair. PdfImage to draw. The x-coordinate of the upper-left corner of the drawn image. The y-coordinate of the upper-left corner of the drawn image. //Creates a new PDF document. PdfDocument doc = new PdfDocument(); //Adds a page to the document. PdfPage page = doc.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics g = page.Graphics; //Creates an image object. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Draws the image. g.DrawImage(image, 0, 0); //Saves the document. doc.Save("Output.pdf"); //Closes the document. doc.Close(true); 'Creates a new PDF document. Dim doc As New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Creates PDF graphics for the page. Dim g As PdfGraphics = page.Graphics 'Creates an image object. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Draws the image. g.DrawImage(image, 0, 0) 'Saves the document. doc.Save("Output.pdf") 'Closes the document. doc.Close() Draws the specified Image at the specified location and with the specified size. PdfImage to draw. RectangleF structure that specifies the location and size of the drawn image. //Creates a new PDF document. PdfDocument doc = new PdfDocument(); //Adds a page to the document. PdfPage page = doc.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics g = page.Graphics; //Creates an image object. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Draws the image. g.DrawImage(image, new RectangleF(0, 0, 300, 200)); //Saves the document. doc.Save("Output.pdf"); //Closes the document. doc.Close(true); 'Creates a new PDF document. Dim doc As New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Creates PDF graphics for the page. Dim g As PdfGraphics = page.Graphics 'Creates an image object. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Draws the image. g.DrawImage(image,New RectangleF(0, 0, 300, 200)) 'Saves the document. doc.Save("Output.pdf") 'Closes the document. doc.Close() Draws the specified Image at the specified location and with the specified shape and size. PdfImage to draw. Point structure that represents the location of the upper-left corner of the drawn image. SizeF structure that represents the height and width of the drawn image. //Creates a new PDF document. PdfDocument doc = new PdfDocument(); //Adds a page to the document. PdfPage page = doc.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics g = page.Graphics; //Creates an image object. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Draws the image. g.DrawImage(image, new PointF(0, 0), new SizeF(300, 200)); //Saves the document. doc.Save("Output.pdf"); //Closes the document. doc.Close(true); 'Creates a new PDF document. Dim doc As New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Creates PDF graphics for the page. Dim g As PdfGraphics = page.Graphics 'Creates an image object. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Draws the image. g.DrawImage(image,New PointF(0, 0), New SizeF(300, 200)) 'Saves the document. doc.Save("Output.pdf") 'Closes the document. doc.Close() Draws the specified image, using its original physical size, at the location specified by a coordinate pair. PdfImage to draw. The x-coordinate of the upper-left corner of the drawn image. The y-coordinate of the upper-left corner of the drawn image. Width of the drawn image. Height of the drawn image. //Creates a new PDF document. PdfDocument doc = new PdfDocument(); //Adds a page to the document. PdfPage page = doc.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics g = page.Graphics; //Creates an image object. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Draws the image. g.DrawImage(image, 0, 0, 300, 200); //Saves the document. doc.Save("Output.pdf"); //Closes the document. doc.Close(true); 'Creates a new PDF document. Dim doc As New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Creates PDF graphics for the page. Dim g As PdfGraphics = page.Graphics 'Creates an image object. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Draws the image. g.DrawImage(image, 0, 0, 300, 200) 'Saves the document. doc.Save("Output.pdf") 'Closes the document. doc.Close() Set the Page xobject in page parent dictionary. Gets the identical Xobject from Image collection. Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Brush that determines the color and texture of the drawn text. PointF structure that specifies the upper-left corner of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Creates a solid brush. PdfBrush brush = new PdfSolidBrush(Color.Black); //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, brush, new PointF(20, 20)); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Creates a solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, brush, New PointF(20,20)) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Brush that determines the color and texture of the drawn text. PointF structure that specifies the upper-left corner of the drawn text. The text string format. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Creates a solid brush. PdfBrush brush = new PdfSolidBrush(Color.Black); //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, brush, new PointF(20, 20), format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Creates a solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, brush, New PointF(20,20), format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Brush that determines the color and texture of the drawn text. The x. The y. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, PdfBrushes.Red, 20, 20); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, PdfBrushes.Red, 20,20) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Brush that determines the color and texture of the drawn text. The x-coordinate of the upper-left corner of the drawn text. The y-coordinate of the upper-left corner of the drawn text. The text string format. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Creates a solid brush. PdfBrush brush = new PdfSolidBrush(Color.Black); //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, brush, 20, 20, format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Creates a solid brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, brush, 20,20, format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. PointF structure that specifies the upper-left corner of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, new PointF(20, 20)); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, New PointF(20,20)) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. PointF structure that specifies the upper-left corner of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, new PointF(20, 20), format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, New PointF(20,20), format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) The text string format. Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. The x-coordinate of the upper-left corner of the drawn text. The y-coordinate of the upper-left corner of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 20, 20); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, 20, 20) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string.. Pen that determines the color, width, and style of the path. The x-coordinate of the upper-left corner of the drawn text. The y-coordinate of the upper-left corner of the drawn text. The text string format. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 20, 20, format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, 20,20, format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. Brush that determines the color and texture of the drawn text. PointF structure that specifies the upper-left corner of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, new PointF(20, 20)); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, New PointF(20, 20)) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. Brush that determines the color and texture of the drawn text. PointF structure that specifies the upper-left corner of the drawn text. StringFormat that specifies formatting attributes, such as line spacing and alignment, that are applied to the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, new PointF(20, 20), format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, New PointF(20,20), format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. The text string. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. Brush that determines the color and texture of the drawn text. The x-coordinate of the upper-left corner of the drawn text. The y-coordinate of the upper-left corner of the drawn text. The text string format. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, 20, 20, format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, 20,20, format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location with the specified Brush and Font objects. The text string. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. Brush that determines the color and texture of the drawn text. The x-coordinate of the upper-left corner of the drawn text. The y-coordinate of the upper-left corner of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, 20, 20); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, 20, 20) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location and size with the specified Brush and Font objects. The text string. Font that defines the text format of the string. Brush that determines the color and texture of the drawn text. RectangleF structure that specifies the bounds of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, PdfBrushes.Red, new RectangleF(20, 20, 200, 20)); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, PdfBrushes.Red, New RectangleF(20, 20, 200, 20)) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location and size with the specified Brush and Font objects. String to draw. Font that defines the text format of the string. Brush that determines the color and texture of the drawn text. RectangleF structure that specifies the bounds of the drawn text. StringFormat that specifies formatting attributes, such as line spacing and alignment, that are applied to the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, PdfBrushes.Red, new RectangleF(20, 20, 200, 20), format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, PdfBrushes.Red, New RectangleF(20, 20, 200, 20), format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location and size with the specified Brush, shift value and Font objects. Draws the specified text string at the specified location and size with the specified Pen and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. RectangleF structure that specifies the bounds of the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, new RectangleF(20, 20, 200, 20)); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, New RectangleF(20, 20, 200, 20)) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location and size with the specified Pen and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. RectangleF structure that specifies the bounds of the drawn text. StringFormat that specifies formatting attributes, such as line spacing and alignment, that are applied to the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, new RectangleF(20, 20, 200, 20), format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, New RectangleF(20, 20, 200, 20), format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location and size with the specified Pen, Brush and Font objects. String to draw. Font that defines the text format of the string. Pen that determines the color, width, and style of the path. The brush. RectangleF structure that specifies the bounds of the drawn text. StringFormat that specifies formatting attributes, such as line spacing and alignment, that are applied to the drawn text. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Sets the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create PDF string format. PdfStringFormat format = new PdfStringFormat(); //Set text alignement. format.Alignment = PdfTextAlignment.Left; format.LineAlignment = PdfVerticalAlignment.Top; //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, new RectangleF(20, 20, 200, 20), format); //Saves the document. document.Save("Sample.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Adds a page to the document. Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Sets the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create PDF string format. Dim format As New PdfStringFormat() 'Set text alignement. format.Alignment = PdfTextAlignment.Left format.LineAlignment = PdfVerticalAlignment.Top 'Draws the text. graphics.DrawString("Hello world!", font, PdfPens.Red, PdfBrushes.Green, New RectangleF(20, 20, 200, 20), format) 'Saves the document. document.Save("Sample.pdf") 'Closes the document document.Close(true) Draws the specified text string at the specified location and size with the specified Pen, Brush, shift Value and Font objects. Changes the origin of the coordinate system by prepending the specified translation to the transformation matrix of this Graphics. The x-coordinate of the translation. The y-coordinate of the translation. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. graphics.Save(); //Set graphics translate transform. graphics.TranslateTransform(100, 100); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Restore the graphics. graphics.Restore(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. graphics.Save() 'Set graphics translate transform. graphics.TranslateTransform(100, 100) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Restore the graphics. graphics.Restore() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Applies the specified scaling operation to the transformation matrix of this Graphics by prepending it to the object's transformation matrix. Scale factor in the x direction. Scale factor in the y direction. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. graphics.Save(); //Scale transform graphics.ScaleTransform(0.5f, 0.5f); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Restore the graphics. graphics.Restore(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. graphics.Save() 'Scale transform graphics.ScaleTransform(0.5F, 0.5F) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Restore the graphics. graphics.Restore() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Applies the specified rotation to the transformation matrix of this Graphics. Angle of rotation in degrees. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. graphics.Save(); //Set rotate transform graphics.RotateTransform(-90); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, -100, 0); //Restore the graphics. graphics.Restore(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. graphics.Save() 'Set rotate transform graphics.RotateTransform(-90) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, -100, 0) 'Restore the graphics. graphics.Restore() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Skews the coordinate system axes. Skews the X axis by this angle (in degrees). Skews the Y axis by this angle (in degrees). // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. graphics.Save(); //Set skew transform graphics.SkewTransform(10,10); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Restore the graphics. graphics.Restore(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. graphics.Save() 'Set skew transform graphics.SkewTransform(10, 10) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Restore the graphics. graphics.Restore() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Multiplies the world transformation of this Graphics and specified the Matrix. The matrix that multiplies the world transformation. Draws a template using its original size, at the specified location. object. PointF structure that specifies the upper-left corner of the drawn template. //Creates a new PDF document. PdfDocument pdfDocument = new PdfDocument(); //Adds a page to the PDF document. PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a PDF Template. PdfTemplate template = new PdfTemplate(100, 50); //Draws a rectangle into the graphics of the template. template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new System.Drawing.RectangleF(0, 0, 100, 50)); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14); PdfBrush brush = new PdfSolidBrush(Color.Black); //Draws a string into the graphics of the template. template.Graphics.DrawString("Hello World", font, brush, 5, 5); //Draws the template into the page graphics of the document. pdfPage.Graphics.DrawPdfTemplate(template, PointF.Empty); //Saves the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Creates a new PDF document. Dim pdfDocument As New PdfDocument() 'Adds a page to the PDF document Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Creates a PDF Template. Dim template As New PdfTemplate(100, 50) 'Draws a rectangle into the graphics of the template. template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New System.Drawing.RectangleF(0, 0, 100, 50)) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14) Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draws a string into the graphics of the template. template.Graphics.DrawString("Hello World", font, brush, 5, 5) 'Draws the template into the page graphics of the document. pdfPage.Graphics.DrawPdfTemplate(template, PointF.Empty) 'Saves the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Draws a template at the specified location and size. object. PointF structure that specifies the upper-left corner of the drawn template. Size of the template. //Creates a new PDF document. PdfDocument pdfDocument = new PdfDocument(); //Adds a page to the PDF document. PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a PDF Template. PdfTemplate template = new PdfTemplate(100, 50); //Draws a rectangle into the graphics of the template. template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, new System.Drawing.RectangleF(0, 0, 100, 50)); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14); PdfBrush brush = new PdfSolidBrush(Color.Black); //Draws a string into the graphics of the template. template.Graphics.DrawString("Hello World", font, brush, 5, 5); //Draws the template into the page graphics of the document. pdfPage.Graphics.DrawPdfTemplate(template, PointF.Empty, template.Size); //Saves the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Creates a new PDF document. Dim pdfDocument As New PdfDocument() 'Adds a page to the PDF document Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Creates a PDF Template. Dim template As New PdfTemplate(100, 50) 'Draws a rectangle into the graphics of the template. template.Graphics.DrawRectangle(PdfBrushes.BurlyWood, New System.Drawing.RectangleF(0, 0, 100, 50)) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14) Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Draws a string into the graphics of the template. template.Graphics.DrawString("Hello World", font, brush, 5, 5) 'Draws the template into the page graphics of the document. pdfPage.Graphics.DrawPdfTemplate(template, PointF.Empty, template.Size) 'Saves the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Forces execution of all pending graphics operations and returns immediately without waiting for the operations to finish. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Draw string to PDF page graphics. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty); //Draw the rectangle to PDF page graphics. graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 20, 200, 100)); graphics.Flush(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Draw string to PDF page graphics. graphics.DrawString("Hello World!", font, PdfBrushes.Black, PointF.Empty) 'Draw the rectangle to PDF page graphics. graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 20, 200, 100)) graphics.Flush() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Saves the current state of this Graphics and identifies the saved state with a GraphicsState. This method returns a GraphicsState that represents the saved state of this Graphics. This method works similar to method. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. graphics.Save(); //Set graphics translate transform. graphics.TranslateTransform(100, 100); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Restore the graphics. graphics.Restore(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. graphics.Save() 'Set graphics translate transform. graphics.TranslateTransform(100, 100) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Restore the graphics. graphics.Restore() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Restores the state of this Graphics to the state represented by a GraphicsState. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. graphics.Save(); //Set graphics translate transform. graphics.TranslateTransform(100, 100); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Restore the graphics. graphics.Restore(); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. graphics.Save() 'Set graphics translate transform. graphics.TranslateTransform(100, 100) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Restore the graphics. graphics.Restore() 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Restores the state of this Graphics to the state represented by a GraphicsState. GraphicsState that represents the state to which to restore this Graphics. This method works similar to method. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. PdfGraphicsState state = graphics.Save(); //Set graphics translate transform. graphics.TranslateTransform(100, 100); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Restore the graphics. graphics.Restore(state); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. Dim state As PdfGraphicsState = graphics.Save() 'Set graphics translate transform. graphics.TranslateTransform(100, 100) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Restore the graphics. graphics.Restore(state) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Sets the clipping region of this Graphics to the rectangle specified by a RectangleF structure. RectangleF structure that represents the new clip region. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //set clip. graphics.SetClip(new RectangleF(0, 0, 50, 12)); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'set clip. graphics.SetClip(New RectangleF(0, 0, 50, 12)) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Sets the clipping region of this Graphics to the result of the specified operation combining the current clip region and the rectangle specified by a RectangleF structure. RectangleF structure to combine. Member of the PdfFillMode enumeration that specifies the filling operation to use. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //set clip. graphics.SetClip(new RectangleF(0, 0, 50, 12), PdfFillMode.Alternate); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'set clip. graphics.SetClip(New RectangleF(0, 0, 50, 12), PdfFillMode.Alternate) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Sets the clipping region of this Graphics to the result of the specified operation combining the current clip region and the specified PdfPath. PdfPath to clip. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF path. PdfPath path = new PdfPath(); path.AddRectangle(new RectangleF(0, 0, 50, 12)); //set clip. graphics.SetClip(path); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF path. Dim path As New PdfPath() path.AddRectangle(New RectangleF(0, 0, 50, 12)) 'set clip. graphics.SetClip(path) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Modifying the current clipping path by intersecting it with the current path. PdfPath to fill. Member of the PdfFillMode enumeration that specifies the filling operation to use. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Create PDF path. PdfPath path = new PdfPath(); path.AddRectangle(new RectangleF(0, 0, 50, 12)); //set clip. graphics.SetClip(path, PdfFillMode.Alternate); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Create PDF path. Dim path As New PdfPath() path.AddRectangle(New RectangleF(0, 0, 50, 12)) 'set clip. graphics.SetClip(path, PdfFillMode.Alternate) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Sets the transparency of this Graphics with the specified value for pen The alpha value for both pen and brush operations. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Set transparancy. graphics.SetTransparency(0.5f); //Draws the String. graphics.DrawString("Hello world!", font, PdfBrushes.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Set transparancy. graphics.SetTransparency(0.5F) 'Draws the String. graphics.DrawString("Hello world!", font, PdfBrueshes.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Sets the transparency of this Graphics with the specified value for pen and brush The alpha value for pen operations. The alpha value for brush operations. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Set transparancy. graphics.SetTransparency(0.5f, 0.5f); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Black, PdfBrushes.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Set transparancy. graphics.SetTransparency(0.5F, 0.5F) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Black, PdfBrueshes.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Sets the transparency of this Graphics with the specified PdfBlendMode The alpha value for pen operations. The alpha value for brush operations. The blend mode. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Set transparancy. graphics.SetTransparency(0.5f, 0.5f, PdfBlendMode.HardLight); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Black, PdfBrushes.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Set transparancy. graphics.SetTransparency(0.5F, 0.5F, PdfBlendMode.HardLight) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Black, PdfBrueshes.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Normalizes the text. The font. The text. The normalized string. Initializes this instance. Sets the layer for the graphics. The layer. Sets the layer for the graphics Write End Mark Content for PDFLayer Write Begin Mark Content for PDFLayer Handles the Save event of the Page control. The source of the event. The instance containing the event data. Updates y co-ordinate. Y co-ordinate. Updated y co-ordinate. Writes a comment line. The comment. Clears an instance. Restores graphics state. The restored graphics state. Controls all state modifications and react repectively. The pen. The brush. The font. Controls all state modifications and react respectively. The pen. The brush. The font. Text settings. Saves the font and other font settings. Current font. Current format. If set to true the state's been changed. Saves the ColorSpace and other ColorSpace settings. Controls the brush state. The brush. if set to true the state's been changed. Initializes the current color space. Initializes the current color space. Controls the pen state. The pen. if set to true the state's been changed. Draws custom or sets predefined line cap style. The pen. The x2. The y2. The x1. The y1. Draws the path. The pen. The brush. if it is need to close, set to true. Draws the path. The pen. The brush. The fill mode. if it is need to close, set to true. Gets the bezier points for arc constructing. The x1. The y1. The x2. The y2. The start angle. The extent. Constructs the arc path using Bezier curves. The x1. The y1. The x2. The y2. The start angle. The sweep angle. Builds up the path. The path. Gets the bezier points from respective arrays. The points. The types. The i. The p2. The p3. Builds up the path. The points. The types. Checks path point type flags. The path point type. Gets the text rendering mode. The pen. The brush. The format. Proper TextRenderingMode value. Sets the drawing area and translates origin. X co-ordinate of the co-ordinate system. Y co-ordinate of the co-ordinate system. Left margin value. Top margin value. Right margin value. Bottom margin value. Sets the drawing area and translates origin. Clip bounds of the graphics. Initializes coordinate system. Initializes coordinate system. Flips the hirizontally. Flips the coordinates vertically. Translates coordinates of the input matrix. X translation. Y translation. Input matrix. Output matrix. Scales coordinates of the input matrix. X scaling. Y scaling. Input matrix. Output matrix. Rotates coordinates of the input matrix. Rotation angle. Input matrix. Output matrix. Skews coordinates of the input matrix. X skewing. Y skewing. Input matrix. Output matrix. Draws a CJK string. The line info. The layout rectangle. The font. The format. Gets a CJK string. The line. A proper PdfString class instance. Draws Ascii line. Text line. Lay outing rectangle. Font object. Text format. Creates PdfString from ASCII string. String line. PdfString object. Draws unicode line. Text line. Lay outing rectangle. Font object. Text format. Creates PdfString from the unicode text. Unicode text. PdfString object. Breakes the unicode line to the words and converts symbols to glyphs. String text. TTF font. Array of real words. Array of text in glyphs. Converts to unicode format. Unicode text. The TTF font. Converted string Draws array of unicode tokens. Unicode tokens. Array of the real words. Font object. Text formatting. Word spacing value if need to be justified. Gets the text lines from the text. The text. Applies all the text settings. Font object. Pen object. Brush object. Text format. Calculates shift value if the line is horizontaly aligned. Line width. Bounds width. Text format. Shift value. Calculates shift value if the text is vertically aligned. Text height. Bounds height. Text format. Shift value. Justifies the line if needed. String text. Width of the bounds. Text format. Space width for justifying. Checks whether the line should be justified. String text. Width of the bounds. Text format. True if the line should be justified. Checks and corrects layoutRectangle for text lay outing. Text bounds. True - if some part of the layoutRectangle fits the canvas ClipBounds, false otherwise. Creates lay outed rectangle depending on the text settings. Size of the text. X co-ordinate of the text. Y co-ordinate of the text. Text format settings. layout rectangle. Emulates Underline, Strikeout of the text if needed. Current pen. Current brush. Lay outing result. Font object. Lay outing rectangle. Text format. Creates a pen for drawing lines in the text. Current pen. Current brush. Current font. Text format. Pen for the lines. Draws layout result. Layout result. Text font. Text format. Layout rectangle. Draws a layout result with shift value. Draws a layout result. Layout result. Text font. The pen object. The brush object. Layout rectangle. Text format. Returns line indent for the line. Line info. Text settings. Layout Bounds. Indicates whether the line is the first in the text. Returns line indent for the line. Checks whether RTL is enabled. Text settings. Tre if RTL is enabled. Returns bounds of the line info. index of the line in the result. Layout result. Font used for this text. Layout rectangle. Text settings. Returns bounds of the line info. Sets the BBox entry of the graphics dictionary. The bounds. Raise the event on property changed. Draws a text string. The text. The font. The brush. The text boundaries. The string format. Check and returns, text glyph are avaliable in PdfFont Returns opentype font Returns the script tags values Calculates scaling factor for text that fits to the specifiedboundaries. String text to be scaled. Font object. Text' boundaries. Size of the text. The format. The scaling factor. Resets the current clip region to the infinite region. Prepares a matrix to PDF. The matrix. The page scale value. A properly prepared PdfTransformationMatrix class instance. Sets the current clip region. The rectangle specifying the new clip region. The combining mode. Called when we need to draw a primitive. Converts the System.Drawing.StringFormat format to Syncfusion.Pdf.Graphics.PdfStringFormat format. The format. Proper Syncfusion.Pdf.Graphics.PdfStringFormat format. Converts the line alignment. The string alignment. The proper VerticalAlignment value. Gets the type of the wrap. The string format flags. Proper StringWrapType value. Converts the alingnmet. The string alignment. The proper TextAlignment value. Performs translate transformation of the graphics. The offset by the x coordinate. The offset by the y coordinate. The order of the matrix operations. Performs the rotate transformations. The angle. The order. Converts GraphicsUnits to PrintUnits. returns PrintUnits Internally resets clip region. Sets transformation matrix. Resets the transformations. Sets clip region. Sets clip region. Gets clip path for the graphics. Extracts fill mode of the path. Graphics path. Fill mode of the path. Internally resets transformation. Saves the current graphics state. A GraphicsState instance that stores information about the current graphic state. Restores the graphics state to the specified graphics state. The saved graphics state. Gets the size of the canvas. Usually, this value is equal to the size of the object this graphics belongs to. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Get the graphics canvas size. SizeF canvasSize = graphics.Size; //Draw string to PDF page graphics. graphics.DrawString("Canvas size: " + canvasSize.ToString(), font, PdfBrushes.Black, PointF.Empty); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Get the graphics canvas size. Dim canvasSize As SizeF = graphics.Size 'Draw string to PDF page graphics. graphics.DrawString("Canvas size: " + canvasSize.ToString(), font, PdfBrushes.Black, PointF.Empty) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets the size of the canvas reduced by margins and page templates. It indicates a size of the canvas reduced by margins and template dimensions. This value doesn't change when any custom clip is set. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Get the graphics client size. SizeF clientSize = graphics.ClientSize; //Draw rectangle to PDF graphics. graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(PointF.Empty, clientSize)); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Get the graphics client size. Dim clientSize As SizeF = graphics.ClientSize 'Draw rectangle to PDF graphics. graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(PointF.Empty, clientSize)) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets or sets the current color space of the document The value change of this property has impact on the objects which will be drawn after the change. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Set the color space. graphics.ColorSpace = PdfColorSpace.GrayScale; //Get the graphics client size. SizeF clientSize = graphics.ClientSize; //Draw rectangle to PDF graphics. graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(PointF.Empty, clientSize)); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Set the color space. graphics.ColorSpace = PdfColorSpace.GrayScale 'Get the graphics client size. Dim clientSize As SizeF = graphics.ClientSize 'Draw rectangle to PDF graphics. graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(PointF.Empty, clientSize)) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Gets the stream writer. Gets the transformation matrix reflecting current transformation. Gets the layer for the graphics, if exists. The layer. Gets the page for this graphics, if exists. The page. Gets the automatic fields. The automatic fields. Returns the result after drawing string. Gets or sets the split before being processed by Text and Image region managers. Gets the transparency object value Gets or sets tag for the element Gets a value indicating whether the document is auto-tagged. Gets or sets the current tag type. Gets or sets a value, indicating the template graphics. Gets or sets transformation of graphics. Gets or sets the scaling between world units and page units for this Graphics object. Gets or sets the unit of measure used for page coordinates in this Graphics object. Get or set a value indicates to enable the Direct Word to PDF conversion. get or set the bool value to to idetenctical image Get or set value, indicating the XPS token. Gets the XPS replace character tokens Delegate declaring a method returning resources. Delegate declaring a method to process tag. Holds info about transparency. Initializes a new instance of the class. The alpha pen. The alpha brush. The blend mode. Indicates whether this instance and a specified object are equal. Another object to compare to. true if obj and this instance are the same type and represent the same value; otherwise, false. Returns the hash code for this instance. A 32-bit signed integer that is the hash code for this instance. Represents the state of a Graphics object. This object is returned by a call to the Save methods. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Save the graphics. PdfGraphicsState state = graphics.Save(); //Set graphics translate transform. graphics.TranslateTransform(100, 100); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0); //Restore the graphics. graphics.Restore(state); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Save the graphics. Dim state As PdfGraphicsState = graphics.Save() 'Set graphics translate transform. graphics.TranslateTransform(100, 100) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Red, 0, 0) 'Restore the graphics. graphics.Restore(state) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Parent graphics object. The current transformation matrix. Stores previous rendering mode. Previous character spacing value or 0. Previous word spacing value or 0. The previously used text scaling value. Current pen. Current brush. Current font. Current color space. default constructor. Creates new object. Parent graphics state. The current transformation matrix. Gets the parent graphics object. Gets the current matrix. Gets or sets the current character spacing. Gets or sets the word spacing value. Gets or sets the text scaling value. Gets or sets the current pen object. Gets or sets the brush. Gets or sets the current font object. Gets or sets the current color space value. Gets or sets the text rendering mode. A class representing PDF page margins. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Create new PDF margin. PdfMargins margin = new PdfMargins(); //Set all the side of the page margin. margin.All = 20; //Set margin document.PageSettings.Margins = margin; //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Saves the document. document.Save("output.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As New PdfDocument() 'Create new PDF margin. Dim margin As New PdfMargins() 'Set all the side of page margin. margin.All = 20 'Set margin. document.PageSettings.Margins = margin 'Adds a page.PdfPage Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Saves the document. document.Save("output.pdf") 'Closes the document. document.Close(True) Represents the Default Page Margin value. Initializes a new instance of the class. Sets the margins. The margin size. Sets the margins. The left right. The top bottom. Sets the margins. The left. The top. The right. The bottom. Clones the object. The cloned object. //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Create new PDF margin. PdfMargins margin = new PdfMargins(); //Set left margin. margin.All = 20; //Create new PDF section. PdfSection section = document.Sections.Add(); //Set margin. section.PageSettings.Margins = margin; //Adds a page.PdfPage PdfPage page = section.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Create new PDF section. section = document.Sections.Add(); //Clone the margin. PdfMargins margin1 = margin.Clone() as PdfMargins; margin1.Left = 30; //set marign. section.PageSettings.Margins = margin1; page = section.Pages.Add(); //Creates PDF graphics for the page. graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Saves the document. document.Save("output.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As New PdfDocument() 'Create new PDF margin. Dim margin As New PdfMargins() 'Set left margin. margin.All = 20 'Create new PDF section. Dim section As PdfSection = document.Sections.Add() 'Set margin. section.PageSettings.Margins = margin 'Adds a page.PdfPage Dim page As PdfPage = section.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Create new PDF section. section = document.Sections.Add() 'Clone the margin. Dim margin1 As PdfMargins = TryCast(margin.Clone(), PdfMargins) margin1.Left = 30 'set marign. section.PageSettings.Margins = margin1 page = section.Pages.Add() 'Creates PDF graphics for the page. graphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Saves the document. document.Save("output.pdf") 'Closes the document. document.Close(True) Gets or sets the left margin size. Default value: 40 pixels //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Create new PDF margin. PdfMargins margin = new PdfMargins(); //Set left margin. margin.Left = 20; //Set right margin. margin.Right = 40; //Set top margin. margin.Top = 100; //Set bottom margin. margin.Bottom = 100; //Set margin. document.PageSettings.Margins = margin; //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Saves the document. document.Save("output.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As New PdfDocument() 'Create new PDF margin. Dim margin As New PdfMargins() 'Set left margin. margin.Left = 20 'Set right margin. margin.Right = 40 'Set top margin. margin.Top = 100 'Set bottom margin. margin.Bottom = 100 'Set margin. document.PageSettings.Margins = margin 'Adds a page.PdfPage Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Saves the document. document.Save("output.pdf") 'Closes the document. document.Close(True) Gets or sets the top margin size. Default value: 40 pixels //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Create new PDF margin. PdfMargins margin = new PdfMargins(); //Set left margin. margin.Left = 20; //Set right margin. margin.Right = 40; //Set top margin. margin.Top = 100; //Set bottom margin. margin.Bottom = 100; //Set margin. document.PageSettings.Margins = margin; //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Saves the document. document.Save("output.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As New PdfDocument() 'Create new PDF margin. Dim margin As New PdfMargins() 'Set left margin. margin.Left = 20 'Set right margin. margin.Right = 40 'Set top margin. margin.Top = 100 'Set bottom margin. margin.Bottom = 100 'Set margin. document.PageSettings.Margins = margin 'Adds a page.PdfPage Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Saves the document. document.Save("output.pdf") 'Closes the document. document.Close(True) Gets or sets the right margin size. Default value: 40 pixels //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Create new PDF margin. PdfMargins margin = new PdfMargins(); //Set left margin. margin.Left = 20; //Set right margin. margin.Right = 40; //Set top margin. margin.Top = 100; //Set bottom margin. margin.Bottom = 100; //Set margin. document.PageSettings.Margins = margin; //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Saves the document. document.Save("output.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As New PdfDocument() 'Create new PDF margin. Dim margin As New PdfMargins() 'Set left margin. margin.Left = 20 'Set right margin. margin.Right = 40 'Set top margin. margin.Top = 100 'Set bottom margin. margin.Bottom = 100 'Set margin. document.PageSettings.Margins = margin 'Adds a page.PdfPage Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Saves the document. document.Save("output.pdf") 'Closes the document. document.Close(True) Gets or sets the bottom margin size. Default value: 40 pixels //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Create new PDF margin. PdfMargins margin = new PdfMargins(); //Set left margin. margin.Left = 20; //Set right margin. margin.Right = 40; //Set top margin. margin.Top = 100; //Set bottom margin. margin.Bottom = 100; //Set margin. document.PageSettings.Margins = margin; //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Saves the document. document.Save("output.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As New PdfDocument() 'Create new PDF margin. Dim margin As New PdfMargins() 'Set left margin. margin.Left = 20 'Set right margin. margin.Right = 40 'Set top margin. margin.Top = 100 'Set bottom margin. margin.Bottom = 100 'Set margin. document.PageSettings.Margins = margin 'Adds a page.PdfPage Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Saves the document. document.Save("output.pdf") 'Closes the document. document.Close(True) Sets margin of each side of the page Margin of each side. Default value: 40 pixels //Creates a new PDF document. PdfDocument document = new PdfDocument(); //Create new PDF margin. PdfMargins margin = new PdfMargins(); //Set all the side of the page margin. margin.All = 20; //Set margin document.PageSettings.Margins = margin; //Adds a page.PdfPage PdfPage page = document.Pages.Add(); //Creates PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Draws the String. graphics.DrawRectangle(PdfPens.Red, new RectangleF(new PointF(0, 0), page.GetClientSize())); //Saves the document. document.Save("output.pdf"); //Closes the document. document.Close(true); 'Creates a new PDF document. Dim document As New PdfDocument() 'Create new PDF margin. Dim margin As New PdfMargins() 'Set all the side of page margin. margin.All = 20 'Set margin. document.PageSettings.Margins = margin 'Adds a page.PdfPage Dim page As PdfPage = document.Pages.Add() 'Creates PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Draws the String. graphics.DrawRectangle(PdfPens.Red, New RectangleF(New PointF(0, 0), page.GetClientSize())) 'Saves the document. document.Save("output.pdf") 'Closes the document. document.Close(True) A class defining settings for drawing operations, that determines the color, width, and style of the drawing elements. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Indicates if the pen is immutable. Initializes a new instance of the class. Doesn't change current colour. Initializes a new instance of the class. The color. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(new PdfColor(Color.Red)); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(New PdfColor(Color.Red)) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The system color. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with color and width of the pen The provides color to the pen. Width of the pen's line. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(new PdfColor(Color.Red), 2); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(New PdfColor(Color.Red), 2) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with color and width of the pen The provides color to the pen. Width of the pen's line. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red, 2); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red, 2) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with The provides color and texture to the pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(new PdfSolidBrush(Color.Red)); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(New PdfSolidBrush(Color.Red)) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class. The provides color to the pen. if set to true the pen is immutable. Initializes a new instance of the class with color. The provides color to the pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; // Create Gray ColorSpace PdfCalGrayColorSpace calGrayCS = new PdfCalGrayColorSpace(); // Create new instance for PdfCalGrayColor PdfCalGrayColor gray = new PdfCalGrayColor(calGrayCS); gray.Gray = 0.2; //Create new PDF pen instance. PdfPen pen = new PdfPen(gray); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics ' Create Gray ColorSpace Dim calGrayCS As New PdfCalGrayColorSpace() ' Create new instance for PdfCalGrayColor Dim gray As New PdfCalGrayColor(calGrayCS) gray.Gray = 0.2 'Create new PDF pen instance. Dim pen As New PdfPen(gray) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. Clones this instance. A new pen with the same properties. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Clone the PDF pen. PdfPen pen1 = pen.Clone(); pen1.Width = 10; graphics.DrawRectangle(pen1, new RectangleF(10, 120, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Clone the PDF pen. Dim pen1 As PdfPen = pen.Clone() pen1.Width = 10 graphics.DrawRectangle(pen1, New RectangleF(10, 120, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Sets the brush. The brush. Sets the stroking flag to brush. The brush. Resets the stroking. The brush. Monitors the changes. The current pen. The stream writer. The get resources. if it is save state, set to true. The current color space. The current transformation matrix. True if the pen was different. Gets the pattern. The initialized pattern. Controls the dash style and behaviour of each line. The pen. if set to true the state should be changed anyway. The stream writer. True if the dash is different. Checks the immutability. Name of the property. Get or set the Colorspace. Gets or sets the brush, which specifies the pen behavior. The that determines the color and texture If the brush is set, the color values are ignored, except for PdfSolidBrush. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set brush. pen.Brush = new PdfSolidBrush(Color.Green); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set brush. pen.Brush = New PdfSolidBrush(Color.Green) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the color of the pen. The provide the color to pen //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set pen color. pen.Color = new PdfColor(Color.Green); //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set pen color. pen.Color = New PdfColor(Color.Green) 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the dash offset of the pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set pen dash offset. pen.DashOffset = 0.5f; //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set pen dash offset. pen.DashOffset = 0.5F 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the dash pattern of the pen. we can't set the Dash pattern for solid dash style //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set custom dash style. pen.DashStyle = PdfDashStyle.Custom; // Create a custom dash pattern. pen.DashPattern = new float[] { 4.0f, 2.0f, 1.0f, 3.0f } //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set custom dash style. pen.DashStyle = PdfDashStyle.Custom 'Create a custom dash pattern. pen.DashPattern = New Single() { 4.0F, 2.0F, 1.0F, 3.0F} 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the dash style of the pen. The provides the various dash styles //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set custom dash style. pen.DashStyle = PdfDashStyle.Custom; // Create a custom dash pattern. pen.DashPattern = new float[] { 4.0f, 2.0f, 1.0f, 3.0f } //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set custom dash style. pen.DashStyle = PdfDashStyle.Custom 'Create a custom dash pattern. pen.DashPattern = New Single() { 4.0F, 2.0F, 1.0F, 3.0F} 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the line cap of the pen. The gives various line cap options //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set custom dash style. pen.DashStyle = PdfDashStyle.Custom; //Set line cap. pen.LineCap = PdfLineCap.Round; // Create a custom dash pattern. pen.DashPattern = new float[] { 4.0f, 2.0f, 1.0f, 3.0f } //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set custom dash style. pen.DashStyle = PdfDashStyle.Custom 'Create a custom dash pattern. 'Set line cap. pen.LineCap = PdfLineCap.Round pen.DashPattern = New Single() { 4.0F, 2.0F, 1.0F, 3.0F} 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the line join style of the pen. The provides various line join options. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set custom dash style. pen.DashStyle = PdfDashStyle.Custom; //Set line jion. pen.LineJoin = PdfLineJoin.Bevel; // Create a custom dash pattern. pen.DashPattern = new float[] { 4.0f, 2.0f, 1.0f, 3.0f } //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set custom dash style. pen.DashStyle = PdfDashStyle.Custom 'Set line jion. pen.LineJoin = PdfLineJoin.Bevel 'Create a custom dash pattern. pen.DashPattern = New Single() { 4.0F, 2.0F, 1.0F, 3.0F} 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the width of the pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set pen width. pen.Width = 4; //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set pen width. pen.Width = 4 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets or sets the miter limit. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set pen width. pen.Width = 4; //Set miter limit, pen.MiterLimit = 2; //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set pen width. pen.Width = 4 'Set miter limit, pen.MiterLimit = 2 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) The collection of the default pens. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Black, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Black, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Creates the default pen. The color. Name of the color. The proper PdfPen instance. Disallows to create an instance of PDfPens class. Gets the AliceBlue pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.AliceBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.AliceBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the antique white pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.AntiqueWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.AntiqueWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Aqua default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Aqua, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Aqua, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Aquamarine default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Aquamarine, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Aquamarine, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Azure default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Azure, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Azure, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Beige default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Beige, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Beige, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Bisque default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Bisque, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Bisque, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Black default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Black, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Black, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the BlanchedAlmond default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.BlanchedAlmond, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.BlanchedAlmond, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Blue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Blue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Blue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the BlueViolet default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.BlueViolet, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.BlueViolet, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Brown default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Brown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Brown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the BurlyWood default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.BurlyWood, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.BurlyWood, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the CadetBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.CadetBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.CadetBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Chartreuse default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Chartreuse, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Chartreuse, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Chocolate default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Chocolate, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Chocolate, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Coral default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Coral, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Coral, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the CornflowerBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.CornflowerBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.CornflowerBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Corn silk default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Cornsilk, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Cornsilk, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Crimson default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Crimson, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Crimson, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Cyan default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Cyan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Cyan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkCyan default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkCyan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkCyan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkGoldenrod default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkGoldenrod, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkGoldenrod, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkGray default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkKhaki default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkKhaki, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkKhaki, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkMagenta default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkMagenta, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkMagenta, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkOliveGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkOliveGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkOliveGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkOrange default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkOrange, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkOrange, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkOrchid default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkOrchid, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkOrchid, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkRed default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSalmon default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSalmon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSalmon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSeaGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSlateBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSlateBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSlateBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkSlateGray default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSlateGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkSlateGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkTurquoise default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkTurquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkTurquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DarkViolet default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DarkViolet, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DarkViolet, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DeepPink default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DeepPink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DeepPink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DeepSkyBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DeepSkyBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DeepSkyBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DimGray default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DimGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DimGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the DodgerBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.DodgerBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.DodgerBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Firebrick default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Firebrick, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Firebrick, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the FloralWhite default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.FloralWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.FloralWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the ForestGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.ForestGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.ForestGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Fuchsia default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Fuchsia, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Fuchsia, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Gainsborough default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Gainsboro, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Gainsboro, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the GhostWhite default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.GhostWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.GhostWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Gold default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Gold, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Gold, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Goldenrod default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Goldenrod, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Goldenrod, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Gray default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Gray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Gray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Green default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Green, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Green, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the GreenYellow default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.GreenYellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.GreenYellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Honeydew default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Honeydew, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Honeydew, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the HotPink default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.HotPink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.HotPink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the IndianRed default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.IndianRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.IndianRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Indigo default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Indigo, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Indigo, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Ivory default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Ivory, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Ivory, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Khaki default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Khaki, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Khaki, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Lavender default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Lavender, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Lavender, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LavenderBlush default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LavenderBlush, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LavenderBlush, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LawnGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LawnGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LawnGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LemonChiffon default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LemonChiffon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LemonChiffon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightCoral default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightCoral, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightCoral, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightCyan default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightCyan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightCyan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightGoldenrodYellow default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightGoldenrodYellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightGoldenrodYellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightGray default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightPink default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightPink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightPink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSalmon default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightSalmon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightSalmon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSeaGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightSeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightSeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSkyBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightSkyBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightSkyBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSlateGray default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightSlateGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightSlateGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightSteelBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightSteelBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightSteelBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LightYellow default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LightYellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LightYellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Lime default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Lime, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Lime, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the LimeGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.LimeGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.LimeGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Linen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Linen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Linen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Magenta default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Magenta, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Magenta, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Maroon default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Maroon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Maroon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumAquamarine default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumAquamarine, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumAquamarine, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumOrchid default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumOrchid, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumOrchid, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumPurple default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumPurple, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumPurple, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumSeaGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumSeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumSeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumSlateBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumSlateBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumSlateBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumSpringGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumSpringGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumSpringGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumTurquoise default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumTurquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumTurquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MediumVioletRed default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MediumVioletRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MediumVioletRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MidnightBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MidnightBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MidnightBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MintCream default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MintCream, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MintCream, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the MistyRose default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.MistyRose, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.MistyRose, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Moccasin default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Moccasin, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Moccasin, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the NavajoWhite default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.NavajoWhite, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.NavajoWhite, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Navy default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Navy, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Navy, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the OldLace default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.OldLace, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.OldLace, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Olive default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Olive, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Olive, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the OliveDrab default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.OliveDrab, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.OliveDrab, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Orange default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Orange, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Orange, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the OrangeRed default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.OrangeRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.OrangeRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Orchid default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Orchid, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Orchid, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleGoldenrod default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.PaleGoldenrod, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.PaleGoldenrod, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.PaleGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.PaleGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleTurquoise default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.PaleTurquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.PaleTurquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PaleVioletRed default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.PaleVioletRed, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.PaleVioletRed, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PapayaWhip default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.PapayaWhip, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.PapayaWhip, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PeachPuff default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.PeachPuff, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.PeachPuff, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Peru default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Peru, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Peru, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Pink default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Pink, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Pink, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Plum default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Plum, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Plum, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the PowderBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.PowderBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.PowderBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Purple default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Purple, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Purple, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Red default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Red, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Red, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the RosyBrown default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.RosyBrown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.RosyBrown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the RoyalBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.RoyalBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.RoyalBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SaddleBrown default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SaddleBrown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SaddleBrown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Salmon default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Salmon, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Salmon, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SandyBrown default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SandyBrown, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SandyBrown, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SeaGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SeaGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SeaGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SeaShell default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SeaShell, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SeaShell, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Sienna default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Sienna, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Sienna, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Silver default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Silver, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Silver, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SkyBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SkyBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SkyBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SlateBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SlateBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SlateBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SlateGray default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SlateGray, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SlateGray, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Snow default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Snow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Snow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SpringGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SpringGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SpringGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the SteelBlue default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.SteelBlue, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.SteelBlue, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Tan default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Tan, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Tan, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Teal default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Teal, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Teal, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Thistle default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Thistle, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Thistle, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Tomato default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Tomato, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Tomato, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Transparent default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Transparent, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Transparent, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Turquoise default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Turquoise, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Turquoise, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Violet default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Violet, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Violet, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Wheat default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Wheat, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Wheat, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the White default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.White, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.White, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the WhiteSmoke default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.WhiteSmoke, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.WhiteSmoke, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the Yellow default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.Yellow, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.Yellow, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Gets the YellowGreen default pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Draw rectangle. graphics.DrawRectangle(PdfPens.YellowGreen, new RectangleF(0, 0, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Draw rectangle. graphics.DrawRectangle(PdfPens.YellowGreen, New RectangleF(0, 0, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Dictionary of the objects names. Dictionary of the properties names. Initializes a new instance of the class. Initializes a new instance of the class. The base dictionary. Generates name for the object and adds to the resource if the object is new. Otherwise returns object's name in the context of the resources. Object contained by a resource. Returns object's name in the context of the resources. Gets resource names to font dictionaries. The names to font dictionaries. Requires the proc set. Name of the proc set. Generates Unique string name. Adds object to the resources. Object to be added to resources. Name of the object. Adds the font to the "Fonts" sub dictionary. The font to add. The name. Adds the Layer Properties to the "Properties" dictionary. The layer properties to add. The reference. Adds the template to the "XObject" sub dictionary. The template to add. The name. Adds the image to the "XObject" sub dictionary. The image to add. The name. Adds the specified brush to the resources. The brush. The name of the brush. Adds the specified transparancy to the resources. The transparancy. The name of the brush. Adds the specified ColorSpaces to the resources. Adds the specified Dictionary to the resources. Gets the font names. Get or set the type1 font name other than PdfStandardFonts,inorder to refer exact font from page's font resource Get or set the page document. Class for representing Root transformation matrix. Value for angle converting. Value for angle converting. Transformation matrix. Initializes object. Initializes object. Translates coordinates by specified coordinates. Offsets for translation. Order of transformation sequence is significant. Translates coordinates by specified coordinates. The X value by which to translate coordinate system. The Y value by which to translate coordinate system. Order of transformation sequence is significant. Scales coordinates by specified coordinates. Scaling values. Order of transformation sequence is significant. Scales coordinates by specified coordinates. The value by which to scale coordinate system in the X axis direction. The value by which to scale coordinate system in the Y axis direction. Order of transformation sequence is significant. Rotates coordinate system in counterclockwise direction. The angle of the rotation (in degrees). Order of transformation sequence is significant. Skews coordinate system axes. Skew angles. Order of transformation sequence is significant. Skews coordinate system axes. Skews the X axis by this angle (in degrees). Skews the Y axis by this angle (in degrees). Order of transformation sequence is significant. Applies the specified shear vector to this Matrix by prepending the shear transformation. The shear X factor. The shear Y factor. The transformation applied in this method is a pure shear only if one of the parameters is 0. Applied to a rectangle at the origin, when the shearY factor is 0, the transformation moves the bottom edge horizontally by shearX times the height of the rectangle. When the shearX factor is 0, it moves the right edge vertically by shearY times the width of the rectangle. Caution is in order when both parameters are nonzero, because the results are hard to predict. For example, if both factors are 1, the transformation is singular (hence noninvertible), squeezing the entire plane to a single line. Applies a clockwise rotation about the specified point. The angle. The point. Gets PDF representation. PDF representation. Multiplies matrixes (changes coordinate system.) Matrix to be multiplied. Converts degrees to radians. The degrees X. The value in radians. Converts radians to degress. The radians. The value in degress. Clones this instance. The cloned instance. Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. Gets the X translation value. Gets the Y translation value. Gets or sets the internal matrix object. Represents a simple transparency. Internal variable to store dictionary. Initializes a new instance of the class. The stroke operation alpha value. The fill operation alpha value. The blend mode. Determines whether the specified is equal to the current . The to compare with the current . true if the specified is equal to the current ; otherwise, false. Serves as a hash function for a particular type. is suitable for use in hashing algorithms and data structures like a hash table. A hash code for the current . Gets the number value. Name of the key. The value of the number specified by the string key. Gets the name value. Name of the key. The name value specified by the key. Gets the stroke operation alpha value. Gets the fill operation alpha value. Gets the blend mode. Gets the element. Class allowing to convert different unit metrics. Converting is based on Graphics object DPI settings that is why for differ graphics settings must be created new instance. For example: printers often has 300 and greater dpi resolution, for compare default display screen dpi is 96. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to point. float width = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point); float height = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, new RectangleF(0, 0, width, height)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF bitmap instance. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor() 'Convert to point. Dim width As Single = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point) Dim height As Single = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, New RectangleF(0, 0, width, height)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Indicates default horizontal resolution. Indicates default vertical resolution. Width, in millimeters, of the physical screen. Height, in millimeters, of the physical screen. Width, in pixels, of the screen. Height, in pixels, of the screen. Matrix for conversations between different numeric systems Static constructor. Initializes a new instance of the class with default DPI value of 96. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to point. float width = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point); float height = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, new RectangleF(0, 0, width, height)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF bitmap instance. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor() 'Convert to point. Dim width As Single = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point) Dim height As Single = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, New RectangleF(0, 0, width, height)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with DPI value The dpi. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(360); //Convert to point. float width = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point); float height = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, new RectangleF(0, 0, width, height)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF bitmap instance. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor(360) 'Convert to point. Dim width As Single = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point) Dim height As Single = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, New RectangleF(0, 0, width, height)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Initializes a new instance of the class with System.Drawing.Graphics. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Graphics for measuring the DPI value //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); Image systemImage = Image.FromFile("Autumn Leaves.jpg"); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap(systemImage); //Create system graphics. Graphics graphics = Graphics.FromImage(systemImage); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(graphics); //Convert to point. float width = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point); float height = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, new RectangleF(0, 0, width, height)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() Dim systemImage As Image = Image.FromFile("Autumn Leaves.jpg") 'Create PDF bitmap instance. Dim image As New PdfBitmap(systemImage) 'Create system graphics. Dim graphics As Graphics = Graphics.FromImage(systemImage) 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor(graphics) 'Convert to point. Dim width As Single = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point) Dim height As Single = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, New RectangleF(0, 0, width, height)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts the value, from one graphics unit to another graphics unit. Value to convert Indicates units to convert from Indicates units to convert to Value stored in "to" units Converts the value to pixel from specified graphics unit. Value to convert Indicates units to convert from Value stored in pixels //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF unitconverter. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to pixels. float pageWidth = converter.ConvertToPixels(doc.PageSettings.Size.Width, PdfGraphicsUnit.Point); page.Graphics.DrawString("PDF page width is " + pageWidth + " pixel", new PdfStandardFont(PdfFontFamily.Helvetica,12),PdfBrushes.Red, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF unitconverter. Dim converter As New PdfUnitConvertor() 'Convert to pixels. Dim pageWidth As Single = converter.ConvertToPixels(doc.PageSettings.Size.Width, PdfGraphicsUnit.Point) page.Graphics.DrawString("PDF page width is " + pageWidth + " pixel", New PdfStandardFont(PdfFontFamily.Helvetica, 12), PdfBrushes.Red, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts the rectangle location and size to Pixels from specified measure units source rectangle source rectangle measure units Rectangle with Pixels //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF unitconverter. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to pixels. RectangleF rect = converter.ConvertToPixels(new RectangleF(100, 100, 200, 100), PdfGraphicsUnit.Point); page.Graphics.DrawRectangle(PdfPens.Red, rect); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF unitconverter. Dim converter As New PdfUnitConvertor() 'Convert to pixels. Dim rect As RectangleF = converter.ConvertToPixels(New RectangleF(100, 100, 200, 100), PdfGraphicsUnit.Point) page.Graphics.DrawRectangle(PdfPens.Red, rect) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts point from specified graphics units to pixels source point for convert measure units point in pixels coordinates //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF unitconverter. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to pixels. PointF location = converter.ConvertToPixels(new PointF(100, 100), PdfGraphicsUnit.Point); page.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(location, new SizeF(200, 50)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF unitconverter. Dim converter As New PdfUnitConvertor() 'Convert to pixels. Dim location As PointF = converter.ConvertToPixels(New PointF(100, 100), PdfGraphicsUnit.Point) page.Graphics.DrawRectangle(PdfPens.Red, new RectangleF(location, new SizeF(200, 50)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts size from specified graphics units to pixels source size measure units size in pixels //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF unitconverter. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to pixels. SizeF pageSize = converter.ConvertToPixels(doc.PageSettings.Size, PdfGraphicsUnit.Point); page.Graphics.DrawString("PDF page size is " + pageSize + " pixel", new PdfStandardFont(PdfFontFamily.Helvetica,12),PdfBrushes.Red, PointF.Empty); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF unitconverter. Dim converter As New PdfUnitConvertor() 'Convert to pixels. Dim pageSize As SizeF = converter.ConvertToPixels(doc.PageSettings.Size, PdfGraphicsUnit.Point) page.Graphics.DrawString("PDF page size is " + pageSize + " pixel", New PdfStandardFont(PdfFontFamily.Helvetica, 12), PdfBrushes.Red, PointF.Empty) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts value, to specified graphics unit from Pixel. Value to convert Indicates units to convert to Value stored in "to" units //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to point. float width = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point); float height = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, new RectangleF(0, 0, width, height)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF bitmap instance. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor() 'Convert to point. Dim width As Single = converter.ConvertFromPixels(image.Width, PdfGraphicsUnit.Point) Dim height As Single = converter.ConvertFromPixels(image.Height, PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, New RectangleF(0, 0, width, height)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts rectangle in Pixels into rectangle with specified measure units source rectangle in pixels units convert to units output Rectangle in specified units //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to point. RectangleF rect = converter.ConvertFromPixels(new RectangleF(100,100,500, 700), PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, rect); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF bitmap instance. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor() 'Convert to point. Dim rect As RectangleF = converter.ConvertFromPixels(New RectangleF(100,100,500, 700), PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, rect) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts rectangle from pixels to specified units point in pixels units convert to units output Point in specified units //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to point. PointF location = converter.ConvertFromPixels(new PointF(100,100), PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, new RectangleF(location, image.GetBounds().Size)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF bitmap instance. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor() 'Convert to point. Dim location As PointF = converter.ConvertFromPixels(New PointF(100,100), PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, New RectangleF(location, image.GetBounds().Size)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Converts Size in pixels to size in specified measure units source size convert to units output size in specified measure units //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF bitmap instance. PdfBitmap image = new PdfBitmap("Autumn Leaves.jpg"); //Create a PDF unit converter instance. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to point. SizeF size = converter.ConvertFromPixels(image.GetBounds().Size, PdfGraphicsUnit.Point); //Draw image to PDF page. page.Graphics.DrawImage(image, new RectangleF( new PointF(0, 0), size)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF bitmap instance. Dim image As New PdfBitmap("Autumn Leaves.jpg") 'Create a PDF unit converter instance. Dim converter As New PdfUnitConvertor() 'Convert to point. Dim size As SizeF = converter.ConvertFromPixels(image.GetBounds().Size, PdfGraphicsUnit.Point) 'Draw image to PDF page. page.Graphics.DrawImage(image, New RectangleF(New PointF(0, 0), size)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Update proportions matrix according to Graphics settings The pixel per inch value. Represents the Painting and graphics state Text Grayscale images or image masks Color images Indexed (color-table) images Specifies the type of Horizontal alignment. Specifies the element is aligned to Left. Specifies the element is aligned to Center. Specifies the element is aligned to Right. Specifies the type of Vertical alignment. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Set the line alignment. format.LineAlignment = PdfVerticalAlignment.Middle; 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Specifies the element is aligned to Top. Specifies the element is aligned to Middle. Specifies the element is aligned to Bottom. Specifies the type of horizontal text alignment. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create a new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Create a new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); //Set the text alignment. format.Alignment = PdfTextAlignment.Center; //Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, new RectangleF(0, 0, 200, 100), format); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create a new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Create a new PDF string format instance. Dim format As PdfStringFormat = New PdfStringFormat() 'Set the text alignment. format.Alignment = PdfTextAlignment.Center 'Draw string to PDF page. graphics.DrawString("Hello World!", font, PdfBrushes.Black, New RectangleF(0, 0, 200, 100), format); 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Specifies the text is aligned to Left. Specifies the text is aligned to Center. Specifies the text is aligned to Right. Specifies the text as Justified text. Represents the text rendering direction. Specifies the default text order. Specifies the left to right direction. Specifies the right to left direction. Specifies the text rendering mode. Fill text. Stroke text. Fill, then stroke text. Neither fill nor stroke text (invisible). The flag showing that the text should be a part of a clipping path. Fill text and add to path for clipping (see above). Stroke text and add to path for clipping. Fill, then stroke text and add to path for clipping. Add text to path for clipping. Specifies the corner style of the shapes. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set custom dash style. pen.DashStyle = PdfDashStyle.Custom; //Set line jion. pen.LineJoin = PdfLineJoin.Bevel; // Create a custom dash pattern. pen.DashPattern = new float[] { 4.0f, 2.0f, 1.0f, 3.0f }; //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set custom dash style. pen.DashStyle = PdfDashStyle.Custom 'Set line jion. pen.LineJoin = PdfLineJoin.Bevel 'Create a custom dash pattern. pen.DashPattern = New Single() { 4.0F, 2.0F, 1.0F, 3.0F} 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) The outer edges for the two segments are extended until they meet at an angle. An arc of a circle with a diameter equal to the line width is drawn around the point where the two segments meet, connecting the outer edges for the two segments. The two segments are finished with caps and the resulting notch beyond the ends of the segments is filled with a triangle. Specifies the line cap style to be used at the ends of the lines. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set custom dash style. pen.DashStyle = PdfDashStyle.Custom; //Set line cap. pen.LineCap = PdfLineCap.Round; // Create a custom dash pattern. pen.DashPattern = new float[] { 4.0f, 2.0f, 1.0f, 3.0f }; //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set custom dash style. pen.DashStyle = PdfDashStyle.Custom 'Create a custom dash pattern. 'Set line cap. pen.LineCap = PdfLineCap.Round pen.DashPattern = New Single() { 4.0F, 2.0F, 1.0F, 3.0F} 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) The stroke is squared off at the endpoint of the path. There is no projection beyond the end of the path. A semicircular arc with a diameter equal to the line width is drawn around the endpoint and filled in. The stroke continues beyond the endpoint of the path for a distance equal to half the line width and is squared off. Possible dash styles of the pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create new PDF pen instance. PdfPen pen = new PdfPen(Color.Red); //Set custom dash style. pen.DashStyle = PdfDashStyle.Custom; // Create a custom dash pattern. pen.DashPattern = new float[] { 4.0f, 2.0f, 1.0f, 3.0f }; //Draw rectangle. graphics.DrawRectangle(pen, new RectangleF(10, 10, 200, 100)); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create new PDF pen instance. Dim pen As New PdfPen(Color.Red) 'Set custom dash style. pen.DashStyle = PdfDashStyle.Custom 'Create a custom dash pattern. pen.DashPattern = New Single() { 4.0F, 2.0F, 1.0F, 3.0F} 'Draw rectangle. graphics.DrawRectangle(pen, New RectangleF(10, 10, 200, 100)) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Solid line. Dashed line. Dotted line. Dash-dot line. Dash-dot-dot line. User defined dash style. Specifies how the shapes are filled. //Create a document. PdfDocument doc = new PdfDocument(); //Add a new page. PdfPage page = doc.Pages.Add(); //Create new PDF path. PdfPath path = new PdfPath(); //Set the path fill mode. path.FillMode = PdfFillMode.Winding; //Add line path points. path.AddLine(new PointF(10, 100), new PointF(10, 200)); path.AddLine(new PointF(100, 100), new PointF(100, 200)); path.AddLine(new PointF(100, 200), new PointF(55, 150)); //Draw PDF path to page. path.Draw(page, PointF.Empty); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a document. Dim doc As New PdfDocument() 'Add a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF path. Dim path As New PdfPath() 'Set the path fill mode. path.FillMode = PdfFillMode.Winding; 'Add line path points. path.AddLine(New PointF(10, 100), New PointF(10, 200)) path.AddLine(New PointF(100, 100), New PointF(100, 200)) path.AddLine(New PointF(100, 200), New PointF(55, 150)) 'Draw PDF path to page. path.Draw(page, PointF.Empty) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Nonzero winding number rule of determining "insideness" of point. Even odd rule of determining "insideness" of point. Defines set of color spaces. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Set the color space. graphics.ColorSpace = PdfColorSpace.GrayScale; //Get the graphics client size. SizeF clientSize = graphics.ClientSize; //Draw rectangle to PDF graphics. graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(PointF.Empty, clientSize)); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Set the color space. graphics.ColorSpace = PdfColorSpace.GrayScale 'Get the graphics client size. Dim clientSize As SizeF = graphics.ClientSize 'Draw rectangle to PDF graphics. graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(PointF.Empty, clientSize)) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) RGB color space. CMYK color space. GrayScale color space. Indexed color space used internally. Describes the Color intents. Colors are represented solely with respect to the light source; no correction is made for the output medium’s white point (such as the color of unprinted paper). Colors are represented with respect to the combination of the light source and the output medium’s white point (such as the color of unprinted paper). Colors are represented in a manner that preserves or emphasizes saturation. Colors are represented in a manner that provides a pleasing perceptual appearance. Specifies the blend mode for transparency. // Create a PDF Document. PdfDocument doc = new PdfDocument(); //Add pages to the document PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; //Create PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular); //Set transparancy. graphics.SetTransparency(0.5f, 0.5f, PdfBlendMode.HardLight); //Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Black, PdfBrushes.Red, 0, 0); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a PDF Document. Dim doc As New PdfDocument() 'Add pages to the document Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics 'Create PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Regular) 'Set transparancy. graphics.SetTransparency(0.5F, 0.5F, PdfBlendMode.HardLight) 'Draws the String. graphics.DrawString("Hello world!", font, PdfPens.Black, PdfBrueshes.Red, 0, 0) 'Save the document doc.Save("Output.pdf") 'Close the document doc.Close(True) Selects the source color, ignoring the backdrop. Multiplies the backdrop and source color values. The result color is always at least as dark as either of the two constituent colors. Multiplying any color with black produces black; multiplying with white leaves the original color unchanged. Painting successive overlapping objects with a color other than black or white produces progressively darker colors. Multiplies the complements of the backdrop and source color values, then complements the result. The result color is always at least as light as either of the two constituent colors. Screening any color with white produces white; screening with black leaves the original color unchanged. The effect is similar to projecting multiple photographic slides simultaneously onto a single screen. Multiplies or screens the colors, depending on the backdrop color value. Source colors overlay the backdrop while preserving its highlights and shadows. The backdrop color is not replaced but is mixed with the source color to reflect the lightness or darkness of the backdrop. Selects the darker of the backdrop and source colors. The backdrop is replaced with the source where the source is darker; otherwise, it is left unchanged. Selects the lighter of the backdrop and source colors. The backdrop is replaced with the source where the source is lighter; otherwise, it is left unchanged. Brightens the backdrop color to reflect the source color. Painting with black produces no changes. Darkens the backdrop color to reflect the source color. Painting with white produces no change. Multiplies or screens the colors, depending on the source color value. The effect is similar to shining a harsh spotlight on the backdrop. Darkens or lightens the colors, depending on the source color value. The effect is similar to shining a diffused spotlight on the backdrop. Subtracts the darker of the two constituent colors from the lighter color. Painting with white inverts the backdrop color; painting with black produces no change. Produces an effect similar to that of the Difference mode but lower in contrast. Painting with white inverts the backdrop color; painting with black produces no change. Creates a color with the hue of the source color and the saturation and luminosity of the backdrop color. Creates a color with the saturation of the source color and the hue and luminosity of the backdrop color. Painting with this mode in an area of the backdrop that is a pure gray (no saturation) produces no change. Creates a color with the hue and saturation of the source color and the luminosity of the backdrop color. This preserves the gray levels of the backdrop and is useful for coloring monochrome images or tinting color images. Creates a color with the luminosity of the source color and the hue and saturation of the backdrop color. This produces an inverse effect to that of the Color mode. Specifies the type of the PdfImage. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create PDF graphics for the page PdfGraphics graphics = page.Graphics; string rtfData = @"{\rtf1\ansi\deff0 {\colortbl;\red0\green0\blue0;\red255\green0\blue0; }Default Color\line\cf2Red Color\line\cf1Default Color}"; //Load image from rtf data. PdfImage image = PdfImage.FromRtf(rtfData, 200, PdfImageType.Bitmap) //Draw the image graphics.DrawImage(image, 0, 0); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create PDF graphics for the page Dim graphics As PdfGraphics = page.Graphics Dim rtfData As String = "{\rtf1\ansi\deff0 {\colortbl;\red0\green0\blue0;\red255\green0\blue0; }Default Color\line\cf2Red Color\line\cf1Default Color}" 'Load image from rtf data. Dim Image As PdfImage = PdfImage.FromRtf(rtfData, 200, PdfImageType.Bitmap) 'Draw the image graphics.DrawImage(image, 0, 0) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Specifies the image is bitmap. Specifies the image is metafile. Specifies the types of the page's logical units. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page to the document. PdfPage page = doc.Pages.Add(); //Create new PDF unitconverter. PdfUnitConvertor converter = new PdfUnitConvertor(); //Convert to pixels. RectangleF rect = converter.ConvertToPixels(new RectangleF(100, 100, 200, 100), PdfGraphicsUnit.Point); page.Graphics.DrawRectangle(PdfPens.Red, rect); //Save the document. doc.Save("Output.pdf"); //Close the document. doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page to the document. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF unitconverter. Dim converter As New PdfUnitConvertor() 'Convert to pixels. Dim rect As RectangleF = converter.ConvertToPixels(New RectangleF(100, 100, 200, 100), PdfGraphicsUnit.Point) page.Graphics.DrawRectangle(PdfPens.Red, rect) 'Save the document. doc.Save("Output.pdf") 'Close the document. doc.Close(True) Specifies the Measurement is in centimeters. Specifies the Measurement is in picas. A pica represents 12 points. Specifies the unit of measurement is 1 pixel. Pixel unit is device dependent unit. The result depends on the default Dpi on the machine. Specifies a printer's point (1/72 inch) as the unit of measure. Specifies the inch as the unit of measure. Specifies the document unit (1/300 inch) as the unit of measure. Specifies the Measurement is in millimeters. Specifies the alignment type. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) To fit background image to the cell based on the cell with and height. The image is rendered by center of the cell. The image is stretched by the percentages required to fit the width and height of the cell. The imag is rendered by tile mode. The content is resized to fill the destination dimensions. The aspect ratio is not preserved. The content is resized to fit in the destination dimensions while it preserves its native aspect ratio. The content is resized to fill the destination dimensions while it preserves its native aspect ratio. If the aspect ratio of the destination rectangle differs from the source, the source content is clipped to fit in the destination dimensions. The content preserves its original size. Represents the html hyperlink used during the html to pdf conversion to preserve live-links. This class is used internally and should not be used directly. The bounds which the html element occupies. The target Url. The matching name of the document link. The id of the destination. Initializes a new instance of the class. The bounds. The href. Converts the bounds from pixel to point. Gets or sets the bounds. Gets or sets the id of the destination. Gets or sets the name (id) of the document link. Gets or Sets the Url. The matching type of form elements (i.e. input,select,button...). The bounds which the html form element occupies. The matching indepth type of the form element (i.e. radio,select,button,text,password...). The matching name of the form element. The matching value of the form element. The matching isChecked value of the form element. The parent name of the form element (form name/body name). The matching value of the form element. The matching value of the form element. The readOnly value of the form element. The color of background rectangle of the form element. The background color of the form element. The text color of the form element. The border color of the form element. The matching value of the multiple. The matching value of the selected Index of select options. The matching value of the list element's text,value pair. Initializes a new instance of the class. The bounds. The button type (ex: submit,reset,..). The name of the button element. The actual value of the button element. The color value of background rectangle of each button element. Initializes a new instance of the class. The bounds. The input type (ex: text, radio...). The name of the form element. The actual value of the form element. The value of checked property of form element. The parent element name of the form element. The color value of background rectangle of each form element. Initializes a new instance of the class. The bounds. The input type (ex: text, radio...). The name of the form element. The actual value of the form element. The possible of maximum no.of. char in form element. The readOnly value of form element (true/false). The color value of background rectangle of each form element. The background color value of each form element. The text color value of each form element. The border color value of each form element. Initializes a new instance of the class. The bounds. The input type (ex: text, radio...). The name of the form element. The actual value of the form element. The color value of background rectangle of each form element. Initializes a new instance of the class. The bounds. The input type (ex: text, radio...). The name of the form element. The actual value of the form element. The value of checked property of form element. The color value of background rectangle of each form element. Initializes a new instance of the class. The bounds. The input type (ex: text, radio...). The name of the form element. The actual value of the form element. The readOnly value of form element (true/false). The color value of background rectangle of each form element. The background color value of each form element. The text color value of each form element. The border color value of each form element. Initializes a new instance of the class. The bounds. The input type (ex: text, radio...). The name of the select element. The actual value of the select element. The multi select value (if true, select element is list. Else Combo) of select element. The selected index value of the select element. The color value of background rectangle of each select element. The list of option vlues of each select element. Converts the bounds from pixel to point. Gets or sets the input type of the form element(i.e. input,select,button...). Gets or sets the bounds. Gets or sets the indepth input type of the form element(i.e. radio,select,button,text,password...). Gets or sets the name/id of the document link/form element. Gets or sets the value of the form element. Gets or sets the isChecked value of the form element. Gets or sets the parent name of the form element. Gets or sets the id of the form element. Gets or sets the id of the form element. Gets or sets the readOnly bool value of the form element. Gets or sets the Background Rectangle's Color value of the form element. Gets or sets the Background Color value of the form element. Gets or sets the text Color value of the form element. Gets or sets the border Color value of the form element. Gets or sets the value of the selected item's index of select element. Gets or sets the value of the multiple field of select element. Gets or sets the value of the selected item's index of select element. Represents the html forms used during the html to pdf conversion to preserve forms in pdf. Gets or sets form field id Gets or sets form field value Gets or sets a value indicating whether the field is read only. Gets or sets whether the element is selected or not Gets or sets the field type Gets or sets the field page number Gets or sets the field bounds Represents the layout parameters. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Start lay outing page. The top Lay outing bounds. Layout settings. Gets or sets the starting layout page. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Gets or sets the lay outing bounds. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Gets or sets the vertical offsets. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The vertical offsets. Gets or sets the lay outing settings. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Start lay outing page. Lay outing bounds. Layout settings. Gets or sets start layouting page. Gets or sets layouting bounds. Gets or sets layouting settings. Indicates whether PaginateBounds were set and should be used or not. Bounds for the paginating. Layout type of the element. Break type of the element. Is Text Split Is Image Split Holds the total webpage layout size Holds the total Page count Holds the Page Number of PDF document Holds the split page size Image region manager to avoid split between pages Text region manager to avoid split between pages Form region manager to avoid split between pages Holds the Hyperlink Collections Holds the internal link collections Initializes a new instance of the class. Gets or sets layout type of the element. Gets or sets layout type of the element. Gets or sets layout type of the element. Gets or sets break type of the element. Gets or sets the bounds on the next page. If this property is set, the element will use it for the layouting on the next pages, otherwise, the element will be layout according to the bounds, used on the first page. Gets a value indicating whether [use paginate bounds]. true if [use paginate bounds]; otherwise, false. The Syncfusion.Pdf.HtmlToPdf namespace contains classes to perform HTML to PDF conversion Represents the result of html to PDF conversion. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Render the PdfMetafile in the PDF document result.Render(page, format); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False 'Render the PdfMetafile in the PDF document result.Render(page, format) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Holds the list of Page-Breaks. Holds the list of hyperlinks. Holds the list of hyperlinks. Holds the list of document links. Holds the list of input elements. Holds the list of select elements. Holds the list of button elements. Holds the list of internal links Holds the list of Form field details. Holds the resultant images. Internal variable to hold if conversion is completed. Internal variable to store the scroll position. Internal variable to store the height yet to be converted. Internal variable to store layout result of HTML to PDF. Hold the WebKit File path Layout details of whole document to update the form field bounds. Initializes a new instance of the class. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The image. The page breaks. The anchors. The document links. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Initializes new instance of the class. Initializes new instance of the class. Delete the file Draw the rendered HTML image to the PDF document This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The PDF document where the output should be drawn. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Render the PdfMetafile in the PDF document result.Render(doc); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False 'Render the PdfMetafile in the PDF document result.Render(doc) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Renders the WebKit result to single page and returns the PDF document PdfDocument PdfLayoutFormat PdfDocument with single PDF page Draw the rendered HTML image to the PDF document This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The page where the output will draw. The Metafile layout format. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Render the PdfMetafile in the PDF document result.Render(page, format); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False 'Render the PdfMetafile in the PDF document result.Render(page, format) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Draw the rendered HTML image to the PDF document This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The page where the output will draw. The Metafile layout format. The Metafile layout result //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Create new PDF layout result. PdfLayoutResult layoutResult; //Render the PdfMetafile in the PDF document result.Render(page, format, out layoutResult); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False 'Create new PDF layout result. Dim layoutResult As PdfLayoutResult 'Render the PdfMetafile in the PDF document result.Render(page, format, layoutResult) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Renders the HTML conversion and returns the layout result Draws the meta file. The page. The format. Draws the bitmap. The bitmap. The page. The bounds. The format. Update the bounds based on the layout result Actual size of the page updates the internal link destination Create pdf forms from m_webkitAutoCreateForms list Document to draw pdf forms Performs application-defined tasks associated with releasing, or resetting unmanaged resources. Gets or sets the value indicating whether to preserve the bookmark in the converted document or not;By default false This property is used internally and should not be used directly. Gets or sets a value indicating whether to preserve the TOC in the converted document or not;By default false This property is used internally and should not be used directly. Gets or sets TOC styles /// This property is used internally and should not be used directly. Gets the Page-Break Collection. Gets the hyper-links Collection. Gets if conversion is complete. Gets or sets enable forms. Gets the next scroll height. Gets the rendered image. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The rendered image. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Render the PdfMetafile in the PDF document result.Render(page, format); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False 'Render the PdfMetafile in the PDF document result.Render(page, format) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Returns the image array after the conversion. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The images. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.Images[0] as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.Images[0].Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Render the PdfMetafile in the PDF document result.Render(page, format); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.Images(0), Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.Images(0).Size.Height format.SplitTextLines = False format.SplitImages = False 'Render the PdfMetafile in the PDF document result.Render(page, format) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Handles the quality of Bitmap images in HTML. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Set image quality. result.Quality = 50; //Render the PdfMetafile in the PDF document result.Render(page, new PdfLayoutFormat()); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Set image quality. result.Quality = 50 'Render the PdfMetafile in the PDF document result.Render(page, New PdfLayoutFormat()) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Gets or set the location. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Set the location. result.Location = new PointF(100, 100); //Render the PdfMetafile in the PDF document result.Render(page, format); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False 'Set the location. result.Location = New PointF(100, 100); 'Render the PdfMetafile in the PDF document result.Render(page, format) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Gets or set the metafile transparency. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create new PDF document PdfDocument doc = new PdfDocument(); //Add a new page page = doc.Pages.Add(); //Set the dimension of the PDF page float width = new PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point); float height = -1f; //Initialize HTML to PDF converter using (Syncfusion.HtmlConverter.HtmlConverter html = new Syncfusion.HtmlConverter.HtmlConverter()) { //Convert the URL HtmlToPdfResult result = html.Convert("http://www.syncfusion.com", ImageType.Metafile, (int)width, (int)height, AspectRatio.KeepWidth); if (result != null) { //Get the HTML as PdfMetafile PdfMetafile mf = new PdfMetafile(result.RenderedImage as Metafile); //Formatting options PdfMetafileLayoutFormat format = new PdfMetafileLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.Layout = PdfLayoutType.Paginate; doc.PageSettings.Height = result.RenderedImage.Size.Height; format.SplitTextLines = false; format.SplitImages = false; //Set transparency. result.MetafileTransparency = 0.5f; //Render the PdfMetafile in the PDF document result.Render(page, format); } } //Save the PDF doc.Save(@"Output.pdf"); //Close the PDF doc.Close(true); 'Create new PDF document Dim doc As New PdfDocument() 'Add a new page page = doc.Pages.Add() 'Set the dimension of the PDF page Dim width As Single = New PdfUnitConvertor().ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point) Dim height As Single = -1F 'Initialize HTML to PDF converter Using html As New Syncfusion.HtmlConverter.HtmlConverter() 'Convert the URL Dim result As HtmlToPdfResult = html.Convert("http://www.syncfusion.com", ImageType.Metafile, CInt(width), CInt(height), AspectRatio.KeepWidth) If result IsNot Nothing Then 'Get the HTML as PdfMetafile Dim mf As New PdfMetafile(TryCast(result.RenderedImage, Metafile)) 'Formatting options Dim format As New PdfMetafileLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.Layout = PdfLayoutType.Paginate doc.PageSettings.Height = result.RenderedImage.Size.Height format.SplitTextLines = False format.SplitImages = False 'Set transparency. result.MetafileTransparency = 0.5F 'Render the PdfMetafile in the PDF document result.Render(page, format) End If End Using 'Save the PDF doc.Save("Output.pdf") 'Close the PDF doc.Close(True) Gets or sets the single page layout type Gets or sets a WebKit created temp directory. Use this option to render the whole HTML content into a single PDF page /// //Initialize HTML to PDF converter HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter(HtmlRenderingEngine.WebKit); //Create a new instance for webkit converter settings. WebKitConverterSettings settings = new WebKitConverterSettings(); //Set WebKit path settings.WebKitPath = @"QtBinaries"; //Set signle page layout. settings.SinglePageLayout = SinglePageLayout.FitHeight; //Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings; //Convert URL to PDF PdfDocument document = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework"); //Save and close the PDF document document.Save("Output.pdf"); document.Close(true); 'Initialize HTML to PDF converter Dim htmlConverter As New HtmlToPdfConverter(HtmlRenderingEngine.WebKit) 'Create a new instance for webkit converter settings. Dim settings As New WebKitConverterSettings() 'Set WebKit path settings.WebKitPath = "QtBinaries" 'Set signle page layout. settings.SinglePageLayout = SinglePageLayout.FitHeight 'Assign WebKit settings to HTML converter htmlConverter.ConverterSettings = settings 'Convert URL to PDF Dim document As PdfDocument = htmlConverter.Convert("https://en.wikipedia.org/wiki/.NET_Framework") 'Save and close the PDF document document.Save("Output.pdf") document.Close(True) Do not apply single page layout The page width is not resized to fit the HTML content to PDF page The page height is not resized to fit the HTML content PDF page Reader of the big endian data. Size of Int32 type. Size of Int16 type. Size of long type. Fraction coefficient for getting fixed type. Reader encoding. Binary reader. Initializes a new instance of the class. The reader. Closes all resources. Seeks reader to the sepcified position. Position of the reader. Skips number of bytes. Number of bytes to skip. Reverts array elements. Byte array. Reverted array. Reads 64 bit integer. 64 bit integer. Reads 64 bit integer. 64 bit integer. Reads 32 bit integer. 32 bit integer. Reads 32 bit integer. 32 bit integer. Reads 16 bit integer. 16 bit integer. Reads 16 bit integer. 16 bit integer. Reads one byte. One byte. Reads FIXED data type (16.16) fixed point number. FIXED data type (16.16) fixed point number. Reads bytes from the reader. Number of bytes. Byte array. Reads string. Size of the string in bytes. String data. Reads string. Size of the string in bytes. Indicates whethere string is unicode or not. String data. Reads bytes to array in BigEndian order. Byte array. Start index. Number bytes to read. Number bytes that was read. Gets or sets binary reader. Gets base stream. Writes data in BigEndian order. Size of Int32 type. Size of Int16 type. Size of long type. Fraction coefficient for getting fixed type. Reader encoding. Internal buffer. Current position. Creates a new writer. Capacity of the data. Writes short value. Value. Writes ushort value. Value. Writes int value. Value. Writes uint value. Value. Writes string value. Value. Writes byte[] value. Value. Writes array to the buffer. Byte data. Gets data written to the writter. Gets position of the internal buffer. CrossTable is a class that performs low-level I/O for parsing a PDF cross reference table. Holds the stream. Holds the stream reader. The parser of the reader. A container of all object offsets. The document trailer. A chache variable for chaching the document catalog offset. The last cross-reference table. The storage for stream object readers. The table of the archives within the document. The document encryptor. The high level cross-table. It's required for convertion PDFReferences into PDFReferenceHolders. Repairing wrong offset values Read the whitespaces in front of the document Searches for all instances of reference tables and parses them. The stream with the document. The high-level cross table. Searches for all instances of reference tables and parses them. The stream with the document. The high-level cross table. Indicates is Fdf export or not. Looks up for the token startxref. Retrieves an object by its reference. The reference of the object. The object read from its reference. Retrieves a PDF stream from a PDF document. The reference object to the stream. The array of bytes taken from the PDF stream. Parses the new table. The cross-reference table stream. The hash table of the objects. Parses current subsection. The PDF stream reader with the file in. The table with the offsets foud. Retrieves a PDF reader by the archive information. Retrieves an archive by its number. The archive. Parses the dictionary and retrieves the subsection information in the ArrayList. A PDF stream representing a cross-reference stream dictionary. The information about subsections. Parses a subsection within a cros-reference stream. A cross-reference stream. A structure that specifies a subsection. The table with the offsets foud. The start position within the stream data. The start position of the next subsection. Retrieves an object by its reference. The PDF parser. The position within the reader's stream. The object read from its reference. Skip junk string from the PDF Dispose the corsstable. Returns the offset of an obkect specified. Returns the collection of all object offsets and list of object information. Returns the number of the objects which have been found. Gets the document catalog address. Returns the stream. Use with caution. Returns the offset of the last cross-reference table. Returns the steream reader. Gets the parser. The parser. Returns the document's trailer. Gets or sets the encryptor. Represents a subsection in a cross-reference stream. The first object number in the subsection. The total number of the objects within the subsection. Initialize the subsection with start number and count. The first object number in the subsection. The total number of the objects within the subsection. Initialize the subsection with count. The total number of the objects within the subsection. Represents a type of an object. Stores information about a PDF packed object. A number of an object stream that holds the object. The index of the object within the archive. The archive. Delegate that retrieves an archive by its number. Initialize the archive information class with the archive number and the index within the archive. The archive number. The index within the archive. The GetArchive delegade. Gets a number of an object stream that holds the object. Gets the index of the object within the archive. Gets the archive number. Stores information about an PDF indirect object. The type of the object. The archive information. The PDF reader wich can read from the archive. The offset of the object. The CrossTable class instance. Converts an Object information into the offset. An ObjectInformation class instance. The offset of zero. Holds the parsed object. Initialize the object information object. The object's type. The object's offset or zero. The archive info or null. The low-level reading cross table. Gets the type of the object. The PDF reader wich can read from the archive. The offset of the object. Gets the archive information. Implements functionality of PDF object stream (or PDF archive). Interface of the objects that support Decryptable of their internals. Decrypts the specified encryptor. The encryptor. The curr obj number. Gets a value indicating whether [was encrypted]. true if [was encrypted]; otherwise, false. Gets a value indicating whether this is decrypted. true if decrypted; otherwise, false. Internal variable to hold cloned object. Initializes a new instance of the class. Initializes a new instance of the class. The dictionary. The data. Gets bytes of the stream. Stream to be converted. Destination bytes. Gets bytes of the stream. Stream to be converted. Indicates whether to write the whole stream. Destination bytes. Converts a stream to bigendian format. A stream containing data. A stream in bigendian format. Writes the specified symbol. The symbol. Writes the specified text. The text. Writes the specified data. The data. Blocks the encryption. Decompresses this instance. Hex to Decimal conversion Hex character to convert into Decimal Equivalent decimal value Decode hex stream to decimal equivalent hexadecimal byte stream decimal equivalent for the hexadecimal byte stream Cleares a stream. Dispose the stream data. Saves the object using the specified writer. The writer. Creates a copy of PdfStream. Decrypts the data using the specified encryptor. The encryptor. The current object number. Decompresses the stream data. The data to decompress. The filter name. Uncompressed byte array. Returnes a compressor by its name. The name of the compressor. IPDFCompressor interface. Performs postprocessing of the data for the filter specified. The data to process. The filter. Restored data. Normalizes the filter. If the filter array has only one element store that element instead of entire array. Compresses the content if it's required. The writer. The compressed data. Adds a filter to the filter array. Name of the filter. Encrypts the stream content. The data. The writer. The encrypted content. Gets the filter name from the stream dictionary. The dictionary. The filter name. Gets the internal stream. Gets or sets the data. The modifications of the returned stream have no impact on the real data. Gets or sets compression flag. true if compress; otherwise, false. Returns cloned object. Gets a value indicating whether the object was encrypted. Gets a value indicating whether this is decrypted. true if decrypted; otherwise, false. Holds sorted indices. Holds the objects. PDF stream writer. PDF stream writer. The current document. Initializes a new instance of the class. The document. Saves the object. The object. The reference. Gets the index of the object referenced by its number. The object number. The index of the object. Writes object to defined writer. Writer for object saving. Clears the PdfArchiveStream. Saves objects. Saves indices. Gets the count of objects. Stores information about current object and index. Current object. The current index within the object. Initializes a new instance of the class. The object. PDFCrossTable is responsible for intermediate level parsing and savingof a PDF document. The low level implementation of the cross-reference table. The document catalog. The stream the file within. The modified objects that should be saved. The number of the objects. Shows if the class have been dicposed. The trailer for a new document. The main PdfDocument class instance. Flag that forces an object to be 'a new'. The obj number stack. Holds object numbers that are used to decode strings and streams. Holds maximal generation number or offset to object. The current object archive. The mapped references. The value of the count stored before count was wiped out. The list of the completed archives. Internal variable to identify the current object is PdfEncryptor or not. Internal variable to store pages. Internal variable to store reference. Internal variable to store if document is being merged. internal varible to conform colorspace Repair the docuemnt which contains wrong offset values Indicates whether the crosstable completely disposed or not. Indicates whether the base class is disposed or not. The costructor of the table. A stream which contains the document. The costructor of the table. A stream which contains the document. Repair the crosstable witch contains wrong offsets The costructor of the table. A costructor thar initialize a new cross table. Initializes a new instance of the class. The count. The encryption dictionary. Initializes a new instance of the class. The count. The encryption dictionary. The costructor of the table. Indicates is Fdf export or not A stream which contains the document. Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection. Dereferences the specified primitive object. The primitive object. Dereferenced object. Retrieves an object by its reference. The reference of the object. The object read from its reference. Decrypt a decryptable object. Should be called during Prepare(). The decrypted object. Decrypts the specified obj. The obj. Retrieves a PDF stream from a PDF document. The reference object to the stream. The array of bytes taken from the PDF stream. Registers the object in the cross reference table. The offset of the object within the file The representation of the reference to the object. Registers an archived object. The archive. The reference to the object. Registers the object in the cross reference table. The offset of the object within the file The representation of the reference to the object. True if object is free. Saves the cross-reference table into the stream. The stream writer to save the cross-reference table into. Retrieves the reference of the object given. The object. The reference. If there is no registered reference, create a new one and register it. Retrieves the reference of the object given. The object. The output flag, which shows if the object is new. The reference. Forces all object to be 'a new'. Marks the trailer references being saved. Checks if an object is a page and convert it into a loaded page if necessary. The object, which should be checked. The checked and modified object. Prepares the cross-reference stream. The offset to the previous cross-reference stream. The current position. The reference. Prepared cross-reference stream. Gets the minimal number of bytes required to save the number. The number. How much bytes required. Saves the subsection. The binary writer of cross-reference stream. The object number. The count. The format. Saves the long. The xref stream. The number. The count of bytes. Sets the security to the document. Get the FileID value. Two strings of array Saves all objects in the collection. Writer object. Save object primitivies Saves the archives. The writer. Gets the mapped reference. The reference. The mapped reference. Finds the archive reference. The archive. The reference found. Saves indirect object. Indirect object that should be saved. Writer object. Retrieves the reference of the given object. The object. The reference. The writer. Saves the current archive. The writer. Performs real saving of the save object. The object. The reference. The writer. Generates the document page root dictionary object. The document page root dictionary object. Saves the xref section. The stream writer. Prepares a subsection of the current section within the cross-reference table. The first object in the subsection. The number of the entries in the section. Saves a subsection. A PDF writer. The firs object in the subsection. The number of the indirect objects in the subsection. Generates string for xref table item. Offset of the object in the file. The generation number of the object. Indicates whether object is free. String representation of the item. Saves the new trailer dictionary. A PDF writer. The total number of the objects. The PrevXRef value. Forces the ID to be in hex. The trailer. Saves the endess of the file. A PDF writer. The xref position. Saves the head. The writer. Generates the version of the file. the parent document. The version of the file. Checks the cross-reference type in the document. The parent document. True if cross-reference is a stream, False otherwise. Frees all resources. Releases unmanaged and - optionally - managed resources true to release both managed and unmanaged resources; false to release only unmanaged resources. Gets or sets the current object is PdfEncryptor or not. Returns the document catalog. Returns the source stream. Returns next available object number. Returns a low-level cross-reference table parser. Gets or sets the number of the objects within the document. Gets or sets the main PdfDocument class instance. Gets the chached PDF object main collection. Gets the trailer. Gets or sets if the document is merged. Gets or sets the encryptor. Gets the object collection. Gets the security dictionary. The security dictionary. Gets or sets page correspondance up on each page import. Gets or sets the PdfReference of latest processed object. Represents a registered object. The object number of the indirect object. The generation number of the indirect object. The offset of the indirect object within the file. Archive. Shows if the object is free. Holds the current cross-reference table. Initialize the structure with the proper values. The offset of the object. The reference representing the object number and the generation number of the indirect object. Initialize the structure with the proper values. The offset of the object. The reference representing the object number and the generation number of the indirect object. Shows if the object is free. Initializes a new instance of the class. The xref table. The archive. The reference. Gets the object number. Gets the offset. Stores information about an archive. The object number of the archive. The archive stream. Initializes a new instance of the class. The reference. The archive. PDF dictionary properties. Start marker for dictionary. Holds the current string being read. Holds the current parentessis index. Holds the current dictionary is structured or unstructured. Resets the lexer. Reads the count bytes from the stream. The number of bytes to read. The data which were read from the stream. Skips the new line. Skips the token. Gets the next token. Returns the current text value. Gets current line number. Gets the current string being read. Returns file position. Gets or sets the current dictionary is structured or unstructured. The collection of all objects within a PDF document. The collection of the indirect objects. The collection of the Indirect objects The collection of primitive objects. Holds the index of the object. Synchronization object. Initializes a new instance of the class. Adds the specified element. The element. Adds the specified object. The object. The reference. Removes the entry using index. Determines whether the specified element is within the collection. The element. true if the specified element is within the collection; otherwise, false. Determines whether the collection contains the specified reference. The reference. true if there is the specified reference; otherwise, false. Gets the reference of the object. The index. The reference of the object. Gets the reference of the object. The object. if set to true the object hasn't been found in the collection. The reference of the object. Gets the object specified by the index. The index. The object. Gets the object specified by the index. The index. The object. Gets the index of the object. The reference. The index of the object within the general object collection. Tries to set the reference to the object. The object. The reference. if set to true the object was found. True if the reference have been set successfully. Determines the index of the element within the collection. The element. The index of the element. Reregisters the reference. Old index of the obj. The new object. Reregisters reference from one object to another. The old (primitive) object. The new (complex) object. This method is useful when PDF primitives are converted into More complex objects. Looks through the collection for the object specified. The object to look for. The index of the object. Looks through the collection for the object specified by the reference. The reference. The index of the objec. Gets the at the specified index. Gets the count. Stores info about objects in the PDF document. Shows if the object was modified and requires saving. The PDF object. Object number and generation number of the object. Initializes a new instance of the class. The PDF object. Initializes a new instance of the class. The PDF object. The reference. Marks the object modified. Sets the reference. The reference. Returns a that represents the current . A that represents the current . Implements the operator ==. The object information. The object. The result of the operator. Implements the operator !=. The oi. The obj. The result of the operator. Determines whether the specified is equal to the current . The to compare with the current . true if the specified is equal to the current ; otherwise, false. Gets a value indicating whether the object has been modified. Gets the reference. Gets the object. Utility class to store information about Image transaction or scale matrix. Local variable to store content stream. Local variable to store the key value. Local variable to store the width. Local variable to store the height. Local variable to store the X co-ordinate value. Local variable to store the Y co-ordinate value. Local variable to store the transaction matrix value. Local variable to store the scale matrix value. Local variable to store the page size. Local variable to store the cm entries. Local variable to store the page margin cm. Local variable to store current Rectangle cm.. Local variable to store Previous Rectangle cm. Local variable to store eftMargin. Local variable to store topMargin. Initializes a new instance of the class. Initializes a new instance of the class. Content Stream. Key Value. Page Size. Calculate the matrix value from the content stream. The matrix value in the form of array list. Calculate the scale matrix value. Page size. Calculate the translation matrix value. Convert the matrix value as array. Matrix value. Gets the X co-ordinate value. Gets the Y co-ordinate value. Gets the image height Gets the image width value. gets the image leftmargin Gets the top margin A class of string messages. Class of string PDF common operators. Operator for starting indirect object. Operator for ending indirect object. Operator for reference on indirect object. Whitespace symbol. Slash symbol. Less than symbol. Greater than symbol. New Line symbol. Regex New Line symbol. Operator for starting stream object. Operator for ending indirect object. Operator for starting cross-reference table. Operator in cross-reference table. Operator in cross-reference table. Trailer begining. Operator in trailer object. End of File (trailer) operator. Start of File (trailer) operator. Begin text operator. End text operator. Begin path operator. Append line segment operator. Stroke operator. Fill by nonzero winding rule operator. Fill by even-odd rule operator. Fill && Stroke operator. Fill && Stroke operator. Append a cubic Bezier curve to the current path. Append a rectangle to the current path as a complete subpath. Save graphics state operator. Restore graphics state operator. Paint XObject operator. Modifies CTM (current transformation matrix). Modifies CTM (current transformation matrix). Sets line width. Sets line cap style. Sets line join style. Sets dash pattern. Sets flatness tolerance. Closes path. Closes and strokes path. Operator for closing then filling and stroking a path. Sets character space. Sets word space. Sets horizontal scaling. Sets text leading. Sets font operator. Sets rendering mode. Sets text rise. Sets text horizontal scaling. Set coordinates operator. Operator that sets the start of the new line and leading simultaneously. Sets text pointer to next line. Set text operator Operator to set text with formatting. Operator that writes text on the new line. Operator that writes text on the new line and set spacings. Selects a color space for the stroking color. Selects a color space for the nonstroking color. Sets RGB color for stroking operations. Same as RGB but for nonstroking operations. Sets CMYK color for stroking operations. Same as CMYK but for nonstroking operations. Sets gray color for stroking operations. Same as RGB but for nonstroking operations. Set pattern operator. Same as SC, but also supports Pattern, Separation, DeviceN, and ICCBased color spaces. For non-stroking operations. Same as SC, but also supports Pattern, Separation, DeviceN, and ICCBased color spaces. For stroking. Modify the current clipping path by intersecting it with the current path, using the nonzero winding number rule to determine which regions lie inside the clipping path. Modify the current clipping path by intersecting it with the current path, using the odd-even rule to determine which regions lie inside the clipping path. End the path object without filling or stroking it. This operator is a "path-painting no-op," used primarily for the side effect of changing the current clipping path (see "Clipping Path Operators"). Graphics state operator. Symbol of commenting. Indicates any symbol (regex syntax). Begins a marked-content sequence. Ends a marked-content sequence. Even-odd filling method marker. The operator to apped bezier curve with x2 y2 x3 y3 set. The operator to apped bezier curve with x1 y1 x3 y3 set. Set miter limit operator. Set color rendering intent operator. Set colour of the current colour space for stroking. Set colour of the current colour space for non-stroking operations. Private constructor. The cross-reference table. The reader. PDF lexer. The next token. Holds all integers that have been read ahead. he high level cross-table. It's required for convertion PDFReferences into PDFReferenceHolders. Internal variable to identify the current object is PdfEncryptor or not. To identify whether the dictionary contains colorspace Internal variable to indicate the string is password or not. Internal variable to indicate the string is certificate string or not. Initializes a new instance of the class. The cross-reference table. The reader. The cross table. Parses a PDF object. The offset to the object. The object. Parses a PDF object. The object. Reads a trailer from the stream at the offset. The offset. The trailer dictionary. Reads a trailer from the stream at the offset. The trailer dictionary. Reads startxref entry. The offset to the XRef table. Sets the offset. The offset. Parses the XRef table. The objects. The cross-reference table. The trailer dictionary. Rebuild the xref table for corrupted PDF Documents Create PdfParser Find object values Find first object to identify fast web view PDF documents Reads a simple object from the stream. Reads the object flag. A string that holds the flag. Starts from the offset specified. The offset. Read fdf object Parses old xref table. Cross table object. A collection of the objects. Determines whether there is a subsection. true if there is subsection; otherwise false. Reacts on an error. The error. The additional information. Matches the specified token. The token. The match. Reads the next token. Gets the next token. Reads the name. The PDFName. Reads the boolean. The PDF boolean object. Reads the unicode string. The PDF string object. Processes the unicode escapes. The text. A nornal string. Reads the string. The string. Checks if the string is Big Endian Encoded Encoded string True if the string is Big Endian Encoded Processes escapes. A text string. A string without escape sequences. Processes the octal number. The text. The index. The caracter which value is equal to the octal number. Processes escapes in password string. A text string. A string without escape sequences. Processes the octal number. The text. The index. The caracter which value is equal to the octal number. Read a string coded in hexadecimal digits. A string object. Reads an integer number. A PDF integer. Parses the integer. The integer. Read a real number. A PDF real. Reads an array. The well formed array. Reads a dictionary from the stream. The filled PDF dictionary object. Reads the stream. The stream dictionary. The PDFStream. Checks the given stream length is correct or not. Reads the pair. The well filled pair on success or Pair.Emty on failure. Find text contains unprocessed control character and non-ascii character Gets or sets the current object is PdfEncryptor or not. Gets the lexer object of the current parser Gets the current position of PDF reader Contains constants of errors. Holds the name-value pair. Holds the empty pair. Compares an object and a pair. The pair. The obj. True if the object is equal to the pair. Compares an object and a pair. The pair. The obj. True if the object is not equal to the pair. The name. The value. Initializes a new instance of the class. The name. The value. Indicates whether this instance and a specified object are equal. Another object to compare to. true if obj and this instance are the same type and represent the same value; otherwise, false. Returns the hash code for this instance. A 32-bit signed integer that is the hash code for this instance. Summary description for PDFReader. The stream our reader works with. A string with all delimeter characters except whitespaces, which are listed elsewhere. A string with all delimeter characters of json format except whitespaces, which are listed elsewhere. Holds peeked byte. Indicates if a byte was peeked. Initialize an instance of the PDFReader class. The stream. Disposes the object. Closes the object. Reads a single line from the stream. The line read. Check whitespace Reads a character from the stream and andvances the current position. A character read, or -1 if EOF reached. Reads a character from the stream and preserves the current position of the stream. A character read, or -1 if EOF reached. Read the sequence of bytes from the stream. The storage for the characters. The index in the buffer. The number of characters to read. The count of the characters read. Read the sequence of bytes from the stream. The storage for the characters. The index in the buffer. The number of characters to read. The count of the characters read. Read all bytes to the end of the stream and returns them as a single string. The characters read. Informs whether the character is from the EOL character. The character to test. True if the character is from EOL characters, false otherwise. Determines if the character specified is a separator character. The character to test. True is the character is a separator character. Determines if the character specified is a delimeter character. The character to test. True is the character is a delimeter character, false otherwise. Looks up for the token. What to look for. Searches for a token specified by 'token' string. What to search. The position of the found token. Reads a string from a stream in the oppozite direction. The string. Skip any whitespace at the tail. NOTE: stream.Position points to the last encounted whitespace. Skips all white spaces. stream.Position will point to the first nonspase character or EOF. Returns next string separated by delimiters. A string. Seeks for the position specified. The origin relative offset. The origin for the offset. The zero based position in the stream. Appends a line with the next character from the stream. Also it advances the current stream position. A text string. The resulting the character read, or -1 if EOF was reached during reading. Gets the peeked byte value. The byte value. True if the byte was acquired. Sets or gets the position within the stream. Returns the underlying stream. Helper class to write PDF graphic streams easily. Defines the basic interace of the various writers. Writes the specified PDF object. The PDF object. Writes the specified number. The number. Writes the specified number. The number. Writes the specified text. The text. Writes the specified text. The text. Writes the specified data. The data. Gets or sets the current position within the stream. Stream length. The document required for saving process. The PDF stream where the data should be write into. Initializes a new instance of the class. The PDF stream. Modifies TM (text matrix). Matrix to be inserted. Sets font. The font. The name of the font. Font size. Sets font. The font. The name of the font. Font size. Set the Colorspace. Sets the character spacing. The character spacing value. Sets the word spacing. The word spacing value. Sets the scaling. The scaling factor. The scaling factor of 100 means "normal size". Sets text leading. The leading value. Sets the text rendering mode. The rendering mode. Sets text rise. The text rise value. Sets the text scaling. The text scaling. Starts the next line. Starts the next line. The start point of the line. Shifts the text to the point. The x coordinate. The y coordinate. Sets the start of the next line and set leading. The point. Sets the start of the next line and set leading. The x. The y. Shows the text. The text. if set to true the text is in hex. Shows the text. The text. if set to true the text should be in hex. Shows the text. The text. Flushes tokens to the stream. String tokens. Shows the next line text. The text. if set to true the text should be in hex. Shows the next line text. The text. if set to true the text should be in hex. Shows the next line text. The text. Shows the text on the next line and sets word and character spacings. The word spacing. The char spacing. The text. if set to true the text should be in hex. Shows the text on the next line and sets word and character spacings. The word spacing. The char spacing. The text. if set to true the text should be in hex. Shows the text on the next line and sets word and character spacings. The word spacing. The char spacing. The text. Shows the text. The formatting. Begins text. Writes tags. Ends text. Begins start markup sequence text. The name of the markup sequence. Begins start markup sequence text. The name of the markup sequence. Ends markup sequence text. Writes comment to the file. Begins the path. The start point. Begins the path. The x. The y. Appends bezier segment. Appends bezier segment. The x1. The y1. The x2. The y2. The x3. The y3. Appends the bezier segment. The p2. The p3. if set to true p2 is used as p1. Appends the bezier segment. The x2. The y2. The x3. The y3. if set to true x2 is used as x1 and y2 is used as y1. Appends a line segment. The point. Appends a line segment. The x. The y. Appends the rectangle. The rectangle. Appends the rectangle. The x. The y. The width. The height. Closes path object. Closes the sub path. Fills path. if set to true use even-odd rule. Strokes path. Fills and strokes path. if set to true use even-odd rule. Closes and strokes the path. Closes, then fills and strokes the path. if set to true use even odd rule. Closes and fills the path. if set to true [use even odd rule]. Clips the path. if set to true use even odd rule. Ends the path. Saves the graphics state. Restores the graphics state. Modifies current transformation matrix. Matrix to be inserted. Sets the width of the line. The width. Sets the line cap. The line cap style. Sets the line join. The line join style. Sets the miter limit. The miter limit. Sets the line dash pattern. The pattern. The pattern offset. Sets the line dash pattern. The pattern. The pattern offset. Sets the color rendering intent. The intent value. Sets the flatness tolerance. The tolerance value. Sets the graphics state. Name of the graphics state dictionary. Sets the graphics state. Name of the graphics state dictionary. Sets the color space. The name of the colour space. if set to true the space is set for stroking operations. Sets the color space. The name of the colour space. if set to true the space is set for stroking operations. Sets the color and color space. The color. The color space. if set to true the colour is set for stroking operations. Sets the color and color space. Sets the color and space. The color. The color space. if it is for stroking, set to true. if it is check, set to true. if it is iccbased, set to true. Sets the color and space. The color. The color space. if it is for for stroking, set to true. if it is to check, set to true. if it is iccbased, set to true. if it is indexed, set to true. Sets the color. The color. The current space. if set to true the colour is set for stroking operations. Sets the colour with pattern. The colour array. The name of the pattern. if set to true the colours and pattern are set for stroking operations. Executes the XObject. The name of the XObject. Executes the XObject. The name of the XObject. Gets the stream. The internal PdfStream object. Clears a stream. Writes the point. The point. Writes the point. The x. The y. Writes the text. The text. Writes the text. The text. if set to true the text is in hex. Writes the text. The text. if set to true the text is in hex. Writes the text. The text. Writes the operator. The operator code. Checks the text param. The text. Checks the text param. The text. Checks the text param. The text. Writes the specified PDF object. The PDF object. Writes the specified number. The number. Writes the specified number. The number. Writes the specified text. The text. Writes the specified text. The text. Writes the specified data. The data. Gets or sets the current position within the stream. Gets stream length. Represents structure tree required to store document logical structure. Internal variable to hold structure elements. Internal variable to store PdfPage associated with the element. Internal variable to store structure id. Internal variable to store the bounding rectangle of the element. Internal Variable to store the order for the elements Internal Variable to store structure element parent and the tag. Internal variable to store current structure element's child Internal variable to store structure element's parent hierarchy. Internal variable to store tree root's child nodes Internal variable to store structure elements's childs Internal variable to store tags Internal variable to store tree root childs. Internal variable to store current parent data. Internal variable to store structure element parent data Internal variable to store sub-list dictionary Internal variable to store sub-list collection Internal variable to check whether order included. Internal variable to check whether nested grid rendering done. Constructor Adds the specified element to the document structure tree. Adds the specified element to the document structure tree. Adds annotation/form fields element to the structure tree root. the structure element Page the annotation dictionary Adds structure element to the document tree root the structure element Page returns an integer marked content identifier denoating marked content sequence Adds parent entry for Table/List structure element's parent hierarchy returns true if parent is identical Add entries for the structure elements Table/List structure elements's parent hierarchy returns true if parent is identical Checks whether table has child grid. the structure elements's hierarchy returns true if the table has child grid. Adds parent entry for the elements the structure element structure element's parent hierarchy returns true if parent is identical Checks whether List element has sub-list the structure element's parent hierarchy returns true if the list has sub-list. Set sub entries data. structure element's parent hierarchy current parent dictionary Adds tag for the structure elements Indicates whether the tag is identical returns true if tag is identical Sets parent entry for structure element hierarchy. the structure element hierarchy top level structure element dictionary the start index to add parent entry Set child entry for tree root the structure parent hierarchy Set child for the structure elements List/Table the structure parent hierarchy the child collection Dispose all the resources from strurture tree root. Finds structure elements parent the structure element returns the parent hierarchy for structure element Adds order value from structure element the structure element Converts equivalent name for the tag type. returns the converted tag name Re-Order the List the maximum child entries in parent the order list Re-arrange the structure elements from tree root the tree root child entries the order list Arranges order list from zero the child element count Gets Child elements from structure tree root. the structure tree root Initializes a new instance of the class. The stream. Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. Closes this instance. Writes the specified PDF object. The PDF object. Writes the specified number. The number. Writes the specified number. The number. Writes the specified text. The text. Writes the specified text. The text. Writes the specified data. The data. Gets the stream. The stream. Gets the stream. Gets or Sets the document required for saving process. Gets or sets the current position within the stream. Gets stream length. Holds all tokens which might appear in every PDF file. All element types. Specfies the status of the IPdfPrmitive. Status is registered if it has a reference or else none. Summary description for CryptoApi. Default constructor. WinAPi functions. To prevent construction of a class, we make a private constructor. Adds the font resource from the specified file to the system font table. The font can subsequently be used for text output by any application. String that contains a valid font file name. If the function fails, the return value is zero. Removes the fonts in the specified file from the system font table. String that names a font resource file. If the function fails, the return value is zero. Selects an object into the specified device context (DC). The new object replaces the previous object of the same type. Handle to the DC. Handle to the object to be selected. If the selected object is not a region and the function succeeds, the return value is a handle to the object being replaced. Deletes a logical pen, brush, font, bitmap, region, or palette, freeing all system resources associated with the object. After the object is deleted, the specified handle is no longer valid. Handle to a logical pen, brush, font, bitmap, region, or palette. If the function succeeds, the return value is nonzero. Retrieves font metric data for a TrueType font. Handle to the device context. Specifies the name of a font metric table from which the font data is to be retrieved Specifies the offset from the beginning of the font metric table to the location where the function should begin retrieving information. Pointer to a buffer that receives the font information. Specifies the length in bytes of the information to be retrieved If the function succeeds, the return value is the number of bytes returned. Retrieves the widths, in logical coordinates, of consecutive characters in a specified range from the current font. Handle to the device context. Specifies the first character in the group of consecutive characters. Specifies the last character in the group of consecutive characters, which must not precede the specified first character. Pointer to a buffer that receives the character widths, in logical coordinates. If the function succeeds, the return value is nonzero. Computes the width and height of the specified string of text. Handle to the device context. Pointer to a buffer that specifies the text string. Specifies the length of the lpString buffer. Pointer to a size structure that receives the dimensions of the string in logical units. If the function succeeds, the return value is nonzero. Computes the width and height of the specified string of text. Handle to the device context. Specifies the first character in the group of consecutive characters from the current font. Specifies the last character in the group of consecutive characters from the current font. Pointer to an array of ABC structures that receives the character widths, in logical units. The function succeeds, the return value is nonzero. The SetTextColor function sets the text color for the specified device context to the specified color. Handle to the device context. Specifies the color of the text. If the function succeeds, the return value is a color reference for the previous text color as a COLORREF value. The SetTextAlign function sets the text-alignment flags for the specified device context. Handle to the device context. Specifies the text alignment by using a mask of values. If the function succeeds, the return value is the previous text-alignment setting. The SetBkColor function sets the current background color to the specified color value or to the nearest physical color if the device cannot represent the specified color value. Handle to the device context. Specifies the new background color. If the function succeeds, the return value specifies the previous background color as a COLORREF value. The SaveDC function saves the current state of the specified device context (DC) Handle to the DC whose state is to be saved. If the function succeeds, the return value identifies the saved state. The GetTextColor function retrieves the current text color for the specified device context. Handle to the device context. If the function succeeds, the return value is the current text color as a COLORREF value. The GetBkColor function returns the current background color for the specified device context. Handle to the device context whose background color is to be returned. If the function succeeds, the return value is a COLORREF value for the current background color. The GetTextAlign function retrieves the text-alignment setting for the specified device context. Handle to the device context. The function succeeds, the return value is the status of the text-alignment flags. The RestoreDC function restores a device context (DC) to the specified state Handle to the DC. Specifies the saved state to be restored. If the function succeeds, the return value is nonzero. The LPtoDP function converts logical coordinates into device coordinates. Handle to device context. Pointer to an array of POINT structures. Specifies the number of points in the array. If the function succeeds, the return value is nonzero. The LPtoDP function converts logical coordinates into logical coordinates. Handle to device context. Pointer to an array of POINT structures. Specifies the number of points in the array. If the function succeeds, the return value is nonzero. The CreateIC function creates an information context for the specified device. Driver name. Device name. Port or file name. Optional initialization data. If the function succeeds, the return value is the handle to an information context. The SetWindowExtEx function sets the horizontal and vertical extents of the window for a device context by using the specified values. Handle to the device context. Specifies the window's horizontal extent in logical units. Specifies the window's vertical extent in logical units. Pointer to a size structure that receives the previous window extents, in logical units. The SetWindowOrgEx function specifies which window point maps to the viewport origin (0,0). Handle to the device context. Specifies the X coordinate in logical units of the new window origin. Specifies the Y coordinate in logical units of the new window origin. Pointer to a point structure that receives the previous origin of the window, in logical units. If the function succeeds, the return value is nonzero. The SetViewportExtEx function sets the horizontal and vertical extents of the viewport for a device context by using the specified values. Handle to the device context. Specifies the horizontal extent in device units of the viewport. Specifies the vertical extent in device units of the viewport. Pointer to a size structure that receives the previous viewport extents in device units. If the function succeeds, the return value is nonzero. The GetViewportExtEx function retrieves the horizontal extent and vertical extent of the current viewport for the specified device context. Handle to the device context. Pointer to a size structure that receives the previous viewport extents in device units. If the function succeeds, the return value is nonzero. The SetViewportOrgEx function specifies which device point maps to the window origin (0,0). Handle to the device context. Specifies the x-coordinate, in device units, of the new viewport origin. Specifies the Y coordinate in device units of the new viewport origin. Pointer to a point structure that receives the previous viewport origin in device coordinates. If the function succeeds, the return value is nonzero. The ScaleWindowExtEx function modifies the window for a device context using the ratios formed by the specified multiplicands and divisors. Handle to the device context. Specifies the amount by which to multiply the current horizontal extent. Specifies the amount by which to divide the current horizontal extent. Specifies the amount by which to multiply the current vertical extent Specifies the amount by which to divide the current vertical extent Pointer to a size structure that receives the previous window extents in logical units. If the function succeeds, the return value is nonzero. The ScaleViewportExtEx function modifies the viewport for a device context using the ratios formed by the specified multiplicands and divisors. Handle to the device context. Specifies the amount by which to multiply the current horizontal extent. Specifies the amount by which to divide the current horizontal extent. Specifies the amount by which to multiply the current vertical extent. Specifies the amount by which to divide the current vertical extent. Pointer to a size structure that receives the previous viewport extents in device units. If the function succeeds, the return value is nonzero. The SetMapMode function sets the mapping mode of the specified device context. Handle to device context. New mapping mode. If the function succeeds, the return value identifies the previous mapping mode. The GetGraphicsMode function retrieves the current graphics mode for the specified device context. Handle to device context. If the function succeeds, the return value is the current graphics mode. The GetDeviceCaps function retrieves device-specific information for the specified device. Handle to the DC. Specifies the item to return. The return value specifies the value of the desired item. The GetDC function retrieves a handle to a display device context (DC) for the client area of a specified window or for the entire screen. Handle to the window whose DC is to be retrieved If the function succeeds, the return value is a handle to the DC for the specified window's client area. The CreateDC function creates a device context (DC) for a device using the specified name. Driver name. Device name. Not used; should be NULL. Optional printer data. If the function succeeds, the return value is the handle to a DC for the specified device. The DeleteDC function deletes the specified device context (DC). Handle to the device context. If the function succeeds, the return value is nonzero. The ModifyWorldTransform function changes the world transformation for a device context using the specified mode. handle to device context. transformation data. The modififcation mode. modification mode. The SetWorldTransform function sets the world transformation for a device context using the specified mode. handle to device context. transformation data. modification mode. The GetMapMode function retrieves the current mapping mode. handle to device context. If the function succeeds, the return value specifies the mapping mode. The SetMiterLimit function sets the limit for the length of miter joins for the specified device context. handle to DC new miter limit previous miter limit If the function succeeds, the return value is nonzero. The GetMiterLimit function retrieves the miter limit for the specified device context. handle to DC miter limit If the function succeeds, the return value is nonzero. The SetPolyFillMode function sets the polygon fill mode for functions that fill polygons. handle to DC polygon fill mode The return value specifies the previous filling mode. If an error occurs, the return value is zero. The GetPolyFillMode function retrieves the current polygon fill mode. handle to DC The return value specifies the filling mode. If an error occurs, the return value is zero. The SetGraphicsMode function sets the graphics mode for the specified device context. Handle to the device context. Specifies the graphics mode. The BeginPath function opens a path bracket in the specified device context. Handle to the device context. If the function succeeds, the return value is nonzero. The MoveToEx function updates the current position to the specified point and optionally returns the previous position. Handle to the device context. Specifies the x-coordinate, in logical units, of the new position, in logical units. Specifies the y-coordinate, in logical units, of the new position, in logical units. Pointer to a POINT structure that receives the previous current position. If the function succeeds, the return value is nonzero. The LineTo function draws a line from the current position up to, but not including, the specified point. Handle to a device context. Specifies the x-coordinate, in logical units, of the line's ending point. Specifies the y-coordinate, in logical units, of the line's ending point. If the function succeeds, the return value is nonzero. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Retrieves text metrics for TrueType fonts. Handle to the device context. Specifies the size in bytes of the array that receives the text metrics. Pointer to an array of OUTLINETEXTMETRIC structures. If the function succeeds, the return value is nonzero or the size of the required buffer. Retrieves text metrics for TrueType fonts. Handle to the device context. Specifies the size in bytes of the array that receives the text metrics. Pointer to an array of OUTLINETEXTMETRIC structures. If the function succeeds, the return value is nonzero or the size of the required buffer. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. Exported function from Windows GDI. For more details see Windows GDI reference. This function allows an application to get a font that is embedded in a document or a webpage. A font that is added by AddFontMemResourceEx is always private to the process that made the call and is not enumerable. A pointer to a font resource. The number of bytes in the font resource that is pointed to by pbFont. Reserved. Must be 0. A pointer to a variable that specifies the number of fonts installed. The return value specifies the handle to the font added WinAPi functions. To prevent construction of a class, we make a private constructor. The GetLastError function retrieves the calling thread's last-error code value. The return value is the calling thread's last-error code value. Retrieves character-type information for the characters in the specified source string. Value that specifies the locale identifier. Value that specifies the type of character information the user wants to retrieve. Pointer to the string for which character types are requested. Size, in characters, of the string pointed to by the lpSrcStr parameter. Pointer to an array of 16-bit values. Boolean result, indicates success of WinAPI call Class containing API for RTL support. Operation succeed. Out of memory to suceed an operation. Default size of the buffer. Font doesn't support such glyphs. Default script program. Mask for setting script as SCRIPT_UNDEFINED. Identifies that layout is RTL. Default constructor. Retieves value from the structure. Value of the structure. Start position of the item inside of the structure. Length of the item in bits. Value from the structure. Class containing API for RTF support. Exported funtion. Exported funtion. Exported funtion. Specifies the type of character information the user wants to retrieve. Retrieves character type info Retrieves bi-directional layout info Retrieves text processing info These types support ANSI C and POSIX (LC_CTYPE) character-typing functions. A combination of these values is returned in the array pointed to by the lpCharType parameter when the dwInfoType parameter is set to CT_CTYPE1. Uppercase Lowercase Decimal digits Space characters Punctuation Control characters Blank characters Hexadecimal digits Any linguistic character: alphabetic, syllabary, or ideographic These types support proper layout of Unicode text. The direction attributes are assigned so that the bidirectional layout algorithm standardized by Unicode produces accurate results. These types are mutually exclusive. Left to right Right to left European number, European digit European numeric separator European numeric terminator Arabic number Common numeric separator Block separator Segment separator White space Other neutrals No implicit directionality (for example, control codes) These types are intended to be placeholders for extensions to the POSIX types required for general text processing or for the standard C library functions. A combination of these values is returned when dwInfoType is set to CT_CTYPE3. Diacritic nonspacing mark Vowel nonspacing mark Symbol Katakana character Hiragana character Half-width (narrow) character Full-width (wide) character Ideographic character Arabic Kashida character Punctuation which is counted as part of the word (Kashida, hyphen, feminine/masculine ordinal indicators, equal sign, and so forth) All linguistic characters (alphabetical, syllabary, and ideographic) Not applicable Native enum. Record of Emf metafile. New miter limit. Record of Emf metafile. The XFORM structure specifies a world-space to page-space transformation. Specifies scaling/rotation/reflection Specified shear/rotation Specified shear/rotation Specifies scaling/rotation/reflection Specifies the horizontal translation component, in logical units. Specifies the vertical translation component, in logical units. Record of Emf metafile. Record of Emf metafile. Point creation from lParam's data. lParam's data for initialing point structure. Performs an implicit conversion from to . The p. The result of the conversion. Performs an implicit conversion from to . The p. The result of the conversion. Performs an implicit conversion from to . The p. The result of the conversion. Windows structure. Windows structure. Windows structure. ABC structure. Structure for 32 bit images saving. Value of Blue chanel. Value of Green chanel. Value of Red chanel. Value of Alpha chanel. Structure for 24 bit images saving. Value of Blue chanel. Value of Green chanel. Value of Red chanel. Structure for 24 bit images saving. Value of Blue chanel. Value of Green chanel. Value of Red chanel. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Windows structure. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Record of Emf metafile. Structure for information about font. Class with simple constants. ExtTextOut options constants. The current background color should be used to fill the rectangle. The text will be clipped to the rectangle. Windows 95 and Windows NT 4.0 and later: The lpString array refers to an array returned from GetCharacterPlacement and should be parsed directly by GDI as no further language-specific processing is required. Glyph indexing only applies to TrueType fonts, but the flag can be used for bitmap and vector fonts to indicate that no further language processing is necessary and GDI should process the string directly. Note that all glyph indexes are 16-bit values even though the string is assumed to be an array of 8-bit values for raster fonts. For ExtTextOutW, the glyph indexes are saved to a metafile. However, to display the correct characters the metafile must be played back using the same font. For ExtTextOutA, the glyph indexes are not saved. Windows 95 and Windows NT 4.0 and later: To display numbers, use European digits. Windows 95 and Windows NT 4.0 and later: To display numbers, use digits appropriate to the locale. Windows 95 and Windows NT 4.0 and later for Middle East language edition of Windows: If this value is specified and a Hebrew or Arabic font is selected into the device context, the string is output using right-to-left reading order. If this value is not specified, the string is output in left-to-right order. The same effect can be achieved by setting the TA_RTLREADING value in SetTextAlign. This value is preserved for backward compatibility. Windows NT 4.0 and later: Reserved for system use. If an application sets this flag, it loses international scripting support and in some cases it may display no text at all. Windows 2000/XP: When this is set, the array pointed to by lpDx contains pairs of values. The first value of each pair is, as usual, the distance between origins of adjacent character cells, but the second value is the displacement along the vertical direction of the font. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Copies the source rectangle directly to the destination rectangle. Combines the colors of the source and destination rectangles by using the Boolean OR operator. Combines the colors of the source and destination rectangles by using the Boolean AND operator. Combines the colors of the source and destination rectangles by using the Boolean XOR operator. Combines the inverted colors of the destination rectangle with the colors of the source rectangle by using the Boolean AND operator. Copies the inverted source rectangle to the destination. Combines the colors of the source and destination rectangles by using the Boolean OR operator and then inverts the resultant color. Merges the colors of the source rectangle with the specified pattern by using the Boolean AND operator. Merges the colors of the inverted source rectangle with the colors of the destination rectangle by using the Boolean OR operator. Copies the specified pattern into the destination bitmap. Combines the colors of the pattern with the colors of the inverted source rectangle by using the Boolean OR operator. The result of this operation is combined with the colors of the destination rectangle by using the Boolean OR operator. Combines the colors of the specified pattern with the colors of the destination rectangle by using the Boolean XOR operator. Inverts the destination rectangle. Fills the destination rectangle using the color associated with index 0 in the physical palette. This color is black for the default physical palette. Fills the destination rectangle using the color associated with index 1 in the physical palette. This color is white for the default physical palette. Combines the colors of the source and destination rectangles by using the Boolean AND operator. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Constants from WinGdi.h file. Gdi Charset. Specifies raster operation. Represents raster operation as BLACK. Represents raster operation as NOTMERGEPEN. Represents raster operation as MASKNOTPEN. Represents raster operation as NOTCOPYPEN. Represents raster operation as MASKPENNOT. Represents raster operation as NOT. Represents raster operation as XORPEN. Represents raster operation as NOTMASKPEN. Represents raster operation as MASKPEN. Represents raster operation as NOTXORPEN. Represents raster operation as NOP. Represents raster operation as MERGENOTPEN. Represents raster operation as COPYPEN. Represents raster operation as MERGEPENNOT. Represents raster operation as MERGEPEN. Represents raster operation as WHITE. The class represents the graphics state data. Represents the method that executes on a when a new page is created. The source of the event. A that contains the event data. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the event. document.Pages.PageAdded += new PageAddedEventHandler(Pages_PageAdded); //Creates a new page and adds it as the last page of the document. PdfPage page = document.Pages.Add(); //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); page = document.Pages.Add(); //Save and close the document. document.Save("Sample.pdf"); document.Close(true); //Event handler for PageAdded event. void Pages_PageAdded(object sender, PageAddedEventArgs args) { PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); args.Page.Graphics.DrawString("New Page", font, PdfBrushes.Black, new PointF(100, 100)); } 'Create a new PDF document. Dim document As New PdfDocument() 'Add the event. document.Pages.PageAdded += New PageAddedEventHandler(Pages_PageAdded) 'Creates a new page and adds it as the last page of the document. Dim page As PdfPage = document.Pages.Add() 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) page = document.Pages.Add() 'Save and close the document. document.Save("Sample.pdf") document.Close(True) 'Event handler for PageAdded event. Private Sub Pages_PageAdded(sender As Object, args As PageAddedEventArgs) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) args.Page.Graphics.DrawString("New Page", font, PdfBrushes.Black, New PointF(100, 100)) End Sub Class Class Provides data for event. This event raises when adding the new to the . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the event. document.Pages.PageAdded += new PageAddedEventHandler(Pages_PageAdded); //Creates a new page and adds it as the last page of the document. PdfPage page = document.Pages.Add(); //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); page = document.Pages.Add(); //Save and close the document. document.Save("Sample.pdf"); document.Close(true); //Event handler for PageAdded event. void Pages_PageAdded(object sender, PageAddedEventArgs args) { PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); args.Page.Graphics.DrawString("New Page", font, PdfBrushes.Black, new PointF(100, 100)); } 'Create a new PDF document. Dim document As New PdfDocument() 'Add the event. document.Pages.PageAdded += New PageAddedEventHandler(Pages_PageAdded) 'Creates a new page and adds it as the last page of the document. Dim page As PdfPage = document.Pages.Add() 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) page = document.Pages.Add() 'Save and close the document. document.Save("Sample.pdf") document.Close(True) 'Event handler for PageAdded event. Private Sub Pages_PageAdded(sender As Object, args As PageAddedEventArgs) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) args.Page.Graphics.DrawString("New Page", font, PdfBrushes.Black, New PointF(100, 100)) End Sub Delegate. Class. Class. Initializes a new instance of the class. Initializes a new instance of the class with . A object representing the page which is added in the document. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the event. document.Pages.PageAdded += new PageAddedEventHandler(Pages_PageAdded); //Creates a new page and adds it as the last page of the document. PdfPage page = document.Pages.Add(); //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); page = document.Pages.Add(); //Save and close the document. document.Save("Sample.pdf"); document.Close(true); //Event handler for PageAdded event. void Pages_PageAdded(object sender, PageAddedEventArgs args) { PdfPage page = args.Page; PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); page.Graphics.DrawString("New Page", font, PdfBrushes.Black, new PointF(100, 100)); } 'Create a new PDF document. Dim document As New PdfDocument() 'Add the event. document.Pages.PageAdded += New PageAddedEventHandler(Pages_PageAdded) 'Creates a new page and adds it as the last page of the document. Dim page As PdfPage = document.Pages.Add() 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) page = document.Pages.Add() 'Save and close the document. document.Save("Sample.pdf") document.Close(True) 'Event handler for PageAdded event. Private Sub Pages_PageAdded(sender As Object, args As PageAddedEventArgs) Dim page As PdfPage = args.Page Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) page.Graphics.DrawString("New Page", font, PdfBrushes.Black, New PointF(100, 100)) End Sub Class. Gets the newly added page. A object representing the page which is added in the document. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the event. document.Pages.PageAdded += new PageAddedEventHandler(Pages_PageAdded); //Creates a new page and adds it as the last page of the document. PdfPage page = document.Pages.Add(); //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); page = document.Pages.Add(); //Save and close the document. document.Save("Sample.pdf"); document.Close(true); //Event handler for PageAdded event void Pages_PageAdded(object sender, PageAddedEventArgs args) { PdfPage page = args.Page; PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); page.Graphics.DrawString("New Page", font, PdfBrushes.Black, new PointF(100, 100)); } 'Create a new PDF document. Dim document As New PdfDocument() 'Add the event. document.Pages.PageAdded += New PageAddedEventHandler(Pages_PageAdded) 'Creates a new page and adds it as the last page of the document. Dim page As PdfPage = document.Pages.Add() 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) page = document.Pages.Add() 'Save and close the document. document.Save("Sample.pdf") document.Close(True) 'Event handler for PageAdded event. Private Sub Pages_PageAdded(sender As Object, args As PageAddedEventArgs) Dim page As PdfPage = args.Page Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) page.Graphics.DrawString("New Page", font, PdfBrushes.Black, New PointF(100, 100)) End Sub Class Class. Class Class Represents information about various predefined page sizes. //Create new document. PdfDocument document = new PdfDocument(); //Set page page for document. document.PageSettings.Size = PdfPageSize.A4; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set page page for document. document.PageSettings.Size = PdfPageSize.A4 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Letter format. Note format. Legal format. A0 format. A1 format. A2 format. A3 format. A4 format. A5 format. A6 format. A7 format. A8 format. A9 format. A10 format. B0 format. B1 format. B2 format. B3 format. B4 format. B5 format. ArchE format. ArchD format. ArchC format. ArchB format. ArchA format. The American Foolscap format. HalfLetter format. 11x17 format. Ledger format. Private constructor. Implements a virtual collection of all pages in the document. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); int startIndex = 0; int endIndex = ldoc.Pages.Count - 1; //Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex); //Get all the pages fron new document. PdfDocumentPageCollection docPages = doc.Pages; int newCount = 0; //Parse through pages from page collection. foreach (PdfPageBase page in docPages) { newCount++; } //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() Dim startIndex As Integer = 0 Dim endIndex As Integer = ldoc.Pages.Count - 1 'Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex) 'Get all the pages from new document. Dim docPages As PdfDocumentPageCollection = doc.Pages Dim newCount As Integer = 0 'Parse through pages from page collection. For Each page As PdfPageBase In docPages newCount += 1 Next 'Save and close the document. doc.Save("Output.pdf") doc.Close(True) ldoc.Close(True) Class Class Parent document. It holds the page collection with the index It counts the index of the page Initializes a new instance of the class. The document. Creates a page and adds it to the last section in the document. Created object. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); int startIndex = 0; int endIndex = ldoc.Pages.Count - 1; //Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex); //Get all the pages fron new document. PdfDocumentPageCollection docPages = doc.Pages; //Add new page in the document. docPages.Add(); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() Dim startIndex As Integer = 0 Dim endIndex As Integer = ldoc.Pages.Count - 1 'Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex) 'Get all the pages fron new document. Dim docPages As PdfDocumentPageCollection = doc.Pages 'Add new page in the document. docPages.Add() 'Save and close the document. doc.Save("Output.pdf") doc.Close(True) ldoc.Close(True) Class Class Adds the specified page to the last section. The page.i Inserts a page at the specified index to the last section in the document. The index of the page in the section. The . Page index start from 0 to (TotalPageCount - 1). Selected index must be within 0 to (TotalPageCount - 1) range. //Create new a document. PdfDocument document = new PdfDocument(); //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("Input.pdf"); //Importing pages from source document. document.ImportPageRange(doc, 0, doc.Pages.Count - 1); //Get all the pages fron new document. PdfDocumentPageCollection docPages = document.Pages; //Insert page to the specified index. docPages.Insert(1, new PdfPage()); docPages.Insert(10, new PdfPage()); //Save and Close the document. document.Save("Output.pdf"); document.Close(true); 'Create new a document. Dim document As PdfDocument = New PdfDocument() 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Importing pages from source document. document.ImportPageRange(doc, 0, doc.Pages.Count - 1) 'Get all the pages fron new document. Dim docPages As PdfDocumentPageCollection = document.Pages 'Insert page to the specified index. docPages.Insert(1, New PdfPage()) docPages.Insert(10, New PdfPage()) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Inserts a loaded page in the new PDF document at specified index. The index at which the page to be inserted The page to be inserted Page index start from 0 to (TotalPageCount - 1). Selected index must be within 0 to (TotalPageCount - 1) range. //Create new a document. PdfDocument document = new PdfDocument(); //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("Input.pdf"); //Get first page from source document. PdfLoadedPage lpage = doc.Pages[0] as PdfLoadedPage; //Importing pages from source document. document.ImportPageRange(doc, 0, doc.Pages.Count - 1); //Get all the pages fron new document. PdfDocumentPageCollection docPages = document.Pages; //Insert page to the specified index. docPages.Insert(1, lpage); //Save and Close the document. document.Save("Output.pdf"); document.Close(true); 'Create new a document. Dim document As PdfDocument = New PdfDocument() 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Get first page from source document. Dim lpage As PdfLoadedPage = TryCast(doc.Pages(0), PdfLoadedPage) 'Importing pages from source document. document.ImportPageRange(doc, 0, doc.Pages.Count - 1) 'Insert page to the specified index. document.Pages.Insert(1, lpage) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Removes the specified page. The page. Clears the page collection. Counts the pages. The total number of pages. Searches a page by its index in the document. Zero-based index of the page. Page by its index in the document. Adds a loaded page to the last section in the document. The loaded page. Returns last section in the document. Returns last section in the document. Called when new page has been added Event arguments. Adds a cloned page from a loaded document. The loaded document. The page. The destinations. Determines whether the page fit last section. The page. true if the page fit last section; otherwise, false. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Gets the total number of the pages. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); int startIndex = 0; int endIndex = ldoc.Pages.Count - 1; //Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex); //Get all the pages fron new document. PdfDocumentPageCollection docPages = doc.Pages; //Get total page count. int newCount = docPages.Count; //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() Dim startIndex As Integer = 0 Dim endIndex As Integer = ldoc.Pages.Count - 1 'Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex) 'Get all the pages fron new document. Dim docPages As PdfDocumentPageCollection = doc.Pages 'Get total page count. Dim newCount As Integer = docPages.Count 'Save and close the document. doc.Save("Output.pdf") doc.Close(True) ldoc.Close(True) Class Class Gets a page by its index in the document. //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Create a new document. PdfDocument doc = new PdfDocument(); int startIndex = 0; int endIndex = ldoc.Pages.Count - 1; //Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex); //Get all the pages fron new document. PdfDocumentPageCollection docPages = doc.Pages; //Gets a page by its index in the document. PdfPage page = docPages[0] as PdfPage; //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Create a new document. Dim doc As PdfDocument = New PdfDocument() Dim startIndex As Integer = 0 Dim endIndex As Integer = ldoc.Pages.Count - 1 'Importing pages from source document. doc.ImportPageRange(ldoc, startIndex, endIndex) 'Get all the pages fron new document. Dim docPages As PdfDocumentPageCollection = doc.Pages 'Gets a page by its index in the document. Dim page As PdfPage = TryCast(docPages(0), PdfPage) 'Save and close the document. doc.Save("Output.pdf") doc.Close(True) ldoc.Close(True) Class Class Gets a page index from the document. Represents the method that executes on a PdfDocument when a new page is created. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the event document.Pages.PageAdded += new PageAddedEventHandler(Pages_PageAdded); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Create font with Bold font style. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); page = document.Pages.Add(); //Saves the document document.Save("Sample.pdf"); document.Close(true); //Event handler for PageAdded event void Pages_PageAdded(object sender, PageAddedEventArgs args) { PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 10); args.Page.Graphics.DrawString("New Page", font, PdfBrushes.Black, new PointF(100, 100)); } 'Create a new PDF document. Dim document As New PdfDocument() 'Add the event document.Pages.PageAdded += New PageAddedEventHandler(Pages_PageAdded) 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Create font with Bold font style. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12F, PdfFontStyle.Bold) 'Draw text in the new page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) page = document.Pages.Add() 'Saves the document document.Save("Sample.pdf") document.Close(True) 'Event handler for PageAdded event Private Sub Pages_PageAdded(sender As Object, args As PageAddedEventArgs) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 10) args.Page.Graphics.DrawString("New Page", font, PdfBrushes.Black, New PointF(100, 100)) End Sub Class Class Section collection enumerator. Parent page collection. Current index of the enumerator. Initializes a new instance of the class. The section collection. Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Checks the index. Gets the current section. Encapsulates a page template for all the pages in the document. //Create a PDF document. PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height); //Creates a new page and adds it as the last page of the document template PdfPageTemplateElement footer = new PdfPageTemplateElement(rect); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); PdfSolidBrush brush = new PdfSolidBrush(Color.Gray); //Create page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font, brush); //Create page count field PdfPageCountField count = new PdfPageCountField(font, brush); PdfCompositeField compositeField = new PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count); compositeField.Bounds = footer.Bounds; compositeField.Draw(footer.Graphics, new PointF(40, footer.Height - 50)); //Add the footer template at the bottom doc.Template.Bottom = footer; //Save the document doc.Save("Template.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As RectangleF = New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height) 'Create a page template Dim footer As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Gray) 'Create page number field Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font, brush) 'Create page count field Dim count As PdfPageCountField = New PdfPageCountField(font, brush) Dim compositeField As PdfCompositeField = New PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count) compositeField.Bounds = footer.Bounds compositeField.Draw(footer.Graphics, New PointF(40, footer.Height - 50)) 'Add the footer template at the bottom doc.Template.Bottom = footer doc.Save("Template.pdf") 'Close the document doc.Close(True) Class Class Class Class Class Class Class Class Left page template object. Top page template object. Right page template object. Bottom page template object. Even Left page template object. Even Top page template object. Even Right page template object. Even Bottom page template object. Odd Left page template object. Odd Top page template object. Odd Right page template object. Odd Bottom page template object. The collection of the stamp elements. Initializes a new instance of the class. Returns left template. Page where the template should be printed. Returns left template. Returns top template. Page where the template should be printed. Returns top template. Returns right template. Page where the template should be printed. Returns right template. Returns bottom template. Page where the template should be printed. Returns bottom template. Checks whether the page is even or odd. The page object. True if the page is even, false otherwise. Checks a template element. The template element. The type that should be assigned to the template element. The template element which passed the check. Gets or sets a left page template. The to draw into the PDF page Gets or sets a top page template. The to draw into the PDF page Gets or sets a right page template. The to draw into the PDF page Gets or sets a bottom page template. The to draw into the PDF page Gets or sets a left page template using on the even pages. The to draw into the PDF page Gets or sets a top page template using on the even pages. The to draw into the PDF page Gets or sets a right page template using on the even pages. The to draw into the PDF page Gets or sets a bottom page template using on the even pages. The to draw into the PDF page Gets or sets a left page template using on the odd pages. The to draw into the PDF page Gets or sets a top page template using on the odd pages. The to draw into the PDF page Gets or sets a right page template using on the odd pages. The to draw into the PDF page Gets or sets a bottom page template using on the odd pages. The to draw into the PDF page Gets a collection of stamp elements. The ,a collection of stamps that are applied to the page templates. Represents a page loaded from a PDF document. //Load the document PdfLoadedDocument lDoc = new PdfLoadedDocument("input.pdf"); //get the first page from the document PdfLoadedPage page = lDoc.Pages[0] as PdfLoadedPage; //Get the annotation collection PdfLoadedAnnotationCollection annotations = page.Annotations; //Save the document lDoc.Save("output.pdf"); lDoc.Close(true); 'Load the document Dim lDoc As New PdfLoadedDocument("input.pdf") 'get the first page from the document Dim page As PdfLoadedPage = TryCast(lDoc.Pages(0), PdfLoadedPage) 'Get the annotation collection Dim annotations As PdfLoadedAnnotationCollection = page.Annotations 'Save the document lDoc.Save("output.pdf") lDoc.Close(True) The abstract base class for all pages, Provides methods and properties to create PDF pages and its elements Collection of the layers of the page. Collection of the annotations of the page. Index of the default layer. Local variable to store the Font Names. Local variable to store the Font Refences. Local variable to store the Fontcollection. Local variable to store page template. Local variable to store annotation count in the page. Internal variable to store layers count. Internal variable to store combined length. Internal variable to store if the page is imported. Helps to lock creating template to page in multi threading Internal variable to store tab order type for form fields Local variable to store if page updated. Internal variable to store image count for the page. Local variable to store resource information Local variable to store information about images. Local variable to store image information. ArrayList to store the extracted images. List to store the image information. List to store image keys. Stack to maintain the current matrix. Clear the page resource and record collection Initializes a new instance of the class. The page dictionary. Replace the Image at index's Position. index of an image The New Replace image //Load the PDF document PdfLoadedDocument doc = new PdfLoadedDocument(@"input.pdf"); //Create an image instance PdfBitmap bmp = new PdfBitmap(@"Autumn Leaves.jpg"); //Replace the first image in the page. doc.Pages[0].ReplaceImage(0, bmp); //Save the document doc.Save("output.pdf"); //Close the document doc.Close(true); 'Load the PDF document///Dim doc As New PdfLoadedDocument("input.pdf") 'Create an image instance Dim bmp As New PdfBitmap("Autumn Leaves.jpg") 'Replace the first image in the page. doc.Pages(0).ReplaceImage(0, bmp) 'Save the document doc.Save("output.pdf") 'Close the document doc.Close(True) Replace the Image at index's Position. index of an image The New Replace image Replace the Paginated Image. Loaded Page Image key name New image Reference Object index The image is replaced or not Creates a template from page content and all annotation appearances. The created PdfTemplate. //Load an existing PDF. PdfLoadedDocument loadedDocument = new PdfLoadedDocument(fileName); //Load the page PdfLoadedPage loadedPage = loadedDocument.Pages[0] as PdfLoadedPage; //Create the template from the page. PdfTemplate template = loadedPage.CreateTemplate(); //Create a new PDF document PdfDocument document = new PdfDocument(); //Set the document margin document.PageSettings.SetMargins(2); //Add the page PdfPage page = document.Pages.Add(); //Create the graphics PdfGraphics graphics = page.Graphics; //Draw the template graphics.DrawPdfTemplate(template, PointF.Empty,new SizeF(page.Size.Width/2,page.Size.Height)); //Save the new document. document.Save("output.pdf"); //Close the documents loadedDocument.Close(true); document.Close(true); 'Load the existing PDF document. Dim loadedDocument As New PdfLoadedDocument(fileName) 'Load the page Dim loadedPage As PdfLoadedPage = TryCast(loadedDocument.Pages(0), PdfLoadedPage) 'Create the template from the page. Dim template As PdfTemplate = loadedPage.CreateTemplate() 'Create a new PDF document Dim document As New PdfDocument() 'Set the document margin document.PageSettings.SetMargins(2) 'Add the page Dim page As PdfPage = document.Pages.Add() 'Create the graphics Dim graphics As PdfGraphics = page.Graphics 'Draw the template graphics.DrawPdfTemplate(template, PointF.Empty, New SizeF(page.Size.Width \ 2, page.Size.Height)) 'Save the new document. document.Save("output.pdf") 'Close the documents loadedDocument.Close(True) Extracts text from the PDF Page. The Extracted Text. //Load an existing PDF. PdfLoadedDocument loadedDocument = new PdfLoadedDocument(fileName); //Load the first page. PdfPageBase page = loadedDocument.Pages[0]; //Extract text from first page. string extractedText = page.ExtractText(); //Close the document loadedDocument.Close(true); 'Load an existing PDF. Dim loadedDocument As New PdfLoadedDocument(fileName) 'Load the first page. Dim page As PdfPageBase = loadedDocument.Pages(0) 'Extract the text from first page. Dim extractedText As String = page.ExtractText() 'close the document. loadedDocument.Close(True) Extracts text from the PDF Page based on its layout Extracts text based on the Layout of PDF Document if the parameter is set to true, else Extracts text normally. The Extracted Text. Extracting the text based on the layout may take additional processing time when compared to the normal extraction. //Load an existing PDF. PdfLoadedDocument loadedDocument = new PdfLoadedDocument(fileName); //Load first page. PdfPageBase page = loadedDocument.Pages[0]; //Extract text from first page. string extractedTexts = page.ExtractText(true); //close the document loadedDocument.Close(true); 'Load an existing PDF. Dim loadedDocument As New PdfLoadedDocument(fileName) 'Load first page. Dim page As PdfPageBase = loadedDocument.Pages(0) 'Extract text from first page. Dim extractedTexts As String = page.ExtractText(True) 'close the document loadedDocument.Close(True) Extracts text along with its format from the PDF Page. Provides the text data collection Returns the extracted text. Extracts text from the page of PDF document with lines and words collection. Holds the lines with bounds in the page. The Extracted Text. Gets the Font from the Xobject. Get the XObject font collection xobject resource dictionary font collection dictionary Collects the Font. Gets the XObject from the Resource dictionary Page resource XObject Get the XObject form the resource dictionary. Resource dictionary xobject Extracts images from the given PDF Page. Returns the extracted image as Image[]. Extract the Inner XObject Images. Extract the images from the PDF returns the List of images //Load an existing PDF. PdfLoadedDocument loadedDocument = new PdfLoadedDocument(fileName); //Load first page. PdfPageBase pageBase = loadedDocument.Pages[0]; //Extract images from first page. Image[] extractedImages = pageBase.ExtractImages(); //close the document loadedDocument.Close(true); 'Load an existing PDF Dim loadedDocument As New PdfLoadedDocument(fileName) 'Load first page. Dim pageBase As PdfPageBase = loadedDocument.Pages(0) 'Extract images from first page. Dim extractedImages As Image() = pageBase.ExtractImages() 'close the document. loadedDocument.Close(True) Remove the image from PDF page in existing PDF document //Load an existing PDF. PdfLoadedDocument loadedDocument = new PdfLoadedDocument(fileName); //Load first page. PdfPageBase pageBase = loadedDocument.Pages[0]; //Extract images from first page. PdfImageInfo imageInfo = loadedDocument.Pages[0].ImagesInfo[0]; //Remove the Image. loadedDocument.Pages[0].RemoveImage(imageInfo); // Save the document. loadedDocument.Save("output.pdf"); //close the document loadedDocument.Close(true); 'Load an existing PDF Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument(fileName) 'Load first page. Dim pageBase As PdfPageBase = loadedDocument.Pages(0) 'Extract images from first page. Dim imageInfo As PdfImageInfo = loadedDocument.Pages(0).ImagesInfo(0) 'Remove the Image. loadedDocument.Pages(0).RemoveImage(imageInfo) ' Save the document. loadedDocument.Save("output.pdf") 'close the document loadedDocument.Close(True) specifies whether check skip node. Regenerate the image if the image stream is disposed The image Name of the image to regenerate Gets the resources and modifies the page dictionary. Pdf resources. Sets the resources. The resources object. Sets the progress. Resets the progress. Gets the content of the page in form of a PDF template. A read-only PdfTemplate object that represents the content of the page (w/o annotations and other interactive elements). Re-Initialize page contents references. /// Returns the array of re-initialized page contents Checks the type of External object /// Returns the initialized page XObject reference Re-Initialize External form object references Checks the Optical content and re-initialize the references re-initialized Optical content Re-initialize image External object references Re-Initialize indirect reference for page resources. /// Returns the initialized page resources Checks the references of Page shading and re-initialize it. PageShading dictionary Re-Initialize the page annotation references Acroform dictionary Checks the annotation appearance and re-initialize the references The Appearance dictionary Re-Initialize the acroform references. AcroForm dictionary Re-Initialize thumbnail data references Re-initialize the ColorSpace references. The ColorSpace dictionary Re-initialize the page pattern references pattern dictionary Checks the font internals to re-initialize the reference The font dictionary Re-initialize font descriptor reference Font descriptor dictionary re-initialized font descriptor Re-initialize the external graphics state references. External graphics state dictionary Returns the initialized graphics state reference Re-Initialize ExternalObject resources External object's resource dictionary Gets the page orientation. The orientation of the page. Clears PdfPageBase. Imports all annotations from a page. The loaded document. The page. The destination list containing the destinations from annotations. Imports all annotations from a page. The loaded document. The page. Gets the destination. The loaded document. The annotation. The destination dictionary. Gets the annotations array. The array of the annotations. Returns number of annotations in the page. Gets the page rotation. The rotation of the page. Draws the annotation templates. The graphics. Normalizes the annotation location. The location. The graphics. The annotation template. The normalized location. Annotation location treats low left page corner as coordinates origin. However, graphics translate the origin to the top left corner. This method makes location relative to the top left page corner. Gets the annotation location. The annotation dictionary. The annotation location. Gets the size of the annotation. The annotation dictionary. The size of the annotation. Gets the size of the interactive element. The dictionary. Name of the property containing size rectangle (e.g. Rect, BBox). The size of the annotation. Gets the annotation template. The annotation. The annotation template. Gets the information about the extracted image from the PDF page This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Load PDF document. PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Gets ImageInfo from the first page. PdfImageInfo[] imageInfo = document.Pages[0].ImagesInfo; //Gets the Image Boundary location. RectangleF imageBounds = imageInfo[0].Bounds; //Gets the Image. Image image = imageInfo[0].Image; //Gets the Image index. int imageIndex = imageInfo[0].Index; //Closing the PDF document. document.Close(true); 'Load PDF document. Dim document As New PdfLoadedDocument("Input.pdf") 'Gets ImageInfo from the first page. Dim imageInfo As PdfImageInfo() = document.Pages(0).ImagesInfo 'Gets the Image Boundary location. Dim imageBounds As RectangleF = imageInfo(0).Bounds 'Gets the Image. Dim image As Image = imageInfo(0).Image 'Gets the Image index. Dim imageIndex As Integer = imageInfo(0).Index 'Closing the PDF document. document.Close(True) Class Class Gets the graphics of the . The that represents a graphics of the page. /// //Create a PDF document PdfDocument document = new PdfDocument(); //Create a PDF page PdfPage page = document.Pages.Add(); //Get graphics PdfGraphics graphics = page.Graphics; //Draw a rectangle graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(0, 0, 100, 200)); //Save and close the document document.Save("output.pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a PDF page Dim page As PdfPage = document.Pages.Add() 'Get graphics Dim graphics As PdfGraphics = page.Graphics 'Draw a rectangle graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(0, 0, 100, 200)) 'Save and close the document document.Save("output.pdf") document.Close(True) Class Class Class Gets or sets if a page is imported. Gets the collection of the page's layers (Read only). The that represents the page's layers //Create a PDF document PdfDocument document = new PdfDocument(); //Add page to the document PdfPage page=document.Pages.Add(); //Get the page layer PdfPageLayerCollection angle = page.Layers; //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Add page to the document Dim page As PdfPage = document.Pages.Add() 'Get the page layer Dim angle As PdfPageLayerCollection = page.Layers 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Class Class Gets the collection of the page's annotations (Read only). The that represents the page's annotations //Load the document PdfLoadedDocument lDoc = new PdfLoadedDocument("inputAnnotation.pdf"); //get the first page from the document PdfLoadedPage page = lDoc.Pages[0] as PdfLoadedPage; //Get the annotation collection PdfLoadedAnnotationCollection annotations = page.Annotations; //Save the document lDoc.Save("sample.pdf"); lDoc.Close(true); 'Load the document Dim lDoc As New PdfLoadedDocument("inputAnnotation.pdf") 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(lDoc.Pages(0), PdfLoadedPage) 'Get the annotation collections Dim annotations As PdfLoadedAnnotationCollection = page.Annotations 'Save the document lDoc.Save("sample.pdf") lDoc.Close(True) Class Class Gets or sets the tab order type for form fields //Create a new document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Set form fields tab order. page.FormFieldsTabOrder = PdfFormFieldsTabOrder.Manual; //Create new text box field. PdfTextBoxField field = new PdfTextBoxField(page, "Hello"); //Set field tab index as 3. field.TabIndex = 3; //Set field bounds. field.Bounds = new RectangleF(0, 0, 100, 30); //Create new text box field. PdfTextBoxField field1 = new PdfTextBoxField(page, "Hello1"); //Set field tab index as 2. field.TabIndex = 2; //Set field bounds. field1.Bounds = new RectangleF(200, 0, 100, 30); //Create new text box field. PdfTextBoxField field2 = new PdfTextBoxField(page, "Hello2"); //Set field tab index as 1. field.TabIndex = 1; //Set field bounds. field2.Bounds = new RectangleF(0, 50, 100, 30); //Create new text box field. PdfTextBoxField field3 = new PdfTextBoxField(page, "Hello3"); //Set field tab index as 0. field.TabIndex = 0; //Set field bounds. field3.Bounds = new RectangleF(200, 50, 100, 30); //Adds the form field to the document. document.Form.Fields.Add(field); document.Form.Fields.Add(field1); document.Form.Fields.Add(field2); document.Form.Fields.Add(field3); //Save the pdf document. document.Save("TabOrder.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = document.Pages.Add() 'Set form fields tab order. page.FormFieldsTabOrder = PdfFormFieldsTabOrder.Manual 'Create new text box field. Dim field As PdfTextBoxField = New PdfTextBoxField(page, "Hello") 'Set field tab index as 3. field.TabIndex = 3 'Set field bounds. field.Bounds = New RectangleF(0, 0, 100, 30) 'Create new text box field. Dim field1 As PdfTextBoxField = New PdfTextBoxField(page, "Hello1") 'Set field tab index as 2. field.TabIndex = 2 'Set field bounds. field1.Bounds = New RectangleF(200, 0, 100, 30) 'Create new text box field. Dim field2 As PdfTextBoxField = New PdfTextBoxField(page, "Hello2") 'Set field tab index as 1. field.TabIndex = 1 'Set field bounds. field2.Bounds = New RectangleF(0, 50, 100, 30) 'Create new text box field. Dim field3 As PdfTextBoxField = New PdfTextBoxField(page, "Hello3") 'Set field tab index as 0. field.TabIndex = 0 'Set field bounds. field3.Bounds = New RectangleF(200, 50, 100, 30) 'Adds the form field to the document. document.Form.Fields.Add(field) document.Form.Fields.Add(field1) document.Form.Fields.Add(field2) document.Form.Fields.Add(field3) 'Save document to disk. document.Save("TabOrder.pdf") 'Close the document. document.Close(True) Class Class Namespace Gets or sets index of the default layer. //Create new document. PdfDocument document = new PdfDocument(); //Set page size. document.PageSettings = new PdfPageSettings(new SizeF(350, 300)); //Add new page. PdfPage page = document.Pages.Add(); //Create new instance for PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 16); //Draw the text. page.Graphics.DrawString("Layers", font, PdfBrushes.DarkBlue, new PointF(150, 10)); //Add the first layer page.Layers.Add(); //Get default layer graphics. PdfGraphics graphics = page.DefaultLayer.Graphics; graphics.TranslateTransform(100, 60); //Create new instance for PDF pen. PdfPen pen = new PdfPen(Color.Red, 50); RectangleF rect = new RectangleF(0, 0, 50, 50); //Draw arc. graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Blue, 30); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); pen = new PdfPen(Color.Yellow, 20); graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Green, 10); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); //Add another layer on the page page.Layers.Add(); //Increment the layer page.DefaultLayerIndex += 1; graphics = page.DefaultLayer.Graphics; graphics.TranslateTransform(100, 180); graphics.SkewTransform(0, 50); //Draw another set of elements pen = new PdfPen(Color.Red, 50); graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Blue, 30); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); pen = new PdfPen(Color.Yellow, 20); graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Green, 10); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); //Save the pdf document. document.Save("Layer.pdf"); //Close the document. document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set page size. document.PageSettings = New PdfPageSettings(New SizeF(350, 300)) 'Add new page. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 16) 'Draw the text. page.Graphics.DrawString("Layers", font, PdfBrushes.DarkBlue, New PointF(150, 10)) 'Add the first layer page.Layers.Add() 'Get default layer graphics. Dim graphics As PdfGraphics = page.DefaultLayer.Graphics graphics.TranslateTransform(100, 60) 'Create new instance for PDF pen. Dim pen As PdfPen = New PdfPen(Color.Red, 50) Dim rect As RectangleF = New RectangleF(0, 0, 50, 50) 'Draw arc. graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Blue, 30) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) pen = New PdfPen(Color.Yellow, 20) graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Green, 10) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) 'Add another layer on the page page.Layers.Add() 'Increment the layer page.DefaultLayerIndex += 1 graphics = page.DefaultLayer.Graphics graphics.TranslateTransform(100, 180) graphics.SkewTransform(0, 50) 'Draw another set of elements pen = New PdfPen(Color.Red, 50) graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Blue, 30) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) pen = New PdfPen(Color.Yellow, 20) graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Green, 10) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) 'Save and close the document. document.Save("Layer.pdf") document.Close(True) Class Class Class Gets the default layer of the page (Read only). The of the Page //Create new document. PdfDocument document = new PdfDocument(); //Set page size. document.PageSettings = new PdfPageSettings(new SizeF(350, 300)); //Add new page. PdfPage page = document.Pages.Add(); //Create new instance for PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 16); //Draw the text. page.Graphics.DrawString("Layers", font, PdfBrushes.DarkBlue, new PointF(150, 10)); //Add the first layer page.Layers.Add(); //Get default layer graphics. PdfGraphics graphics = page.DefaultLayer.Graphics; graphics.TranslateTransform(100, 60); //Create new instance for PDF pen. PdfPen pen = new PdfPen(Color.Red, 50); RectangleF rect = new RectangleF(0, 0, 50, 50); //Draw arc. graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Blue, 30); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); pen = new PdfPen(Color.Yellow, 20); graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Green, 10); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); //Add another layer on the page page.Layers.Add(); //Increment the layer page.DefaultLayerIndex += 1; graphics = page.DefaultLayer.Graphics; graphics.TranslateTransform(100, 180); graphics.SkewTransform(0, 50); //Draw another set of elements pen = new PdfPen(Color.Red, 50); graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Blue, 30); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); pen = new PdfPen(Color.Yellow, 20); graphics.DrawArc(pen, rect, 360, 360); pen = new PdfPen(Color.Green, 10); graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360); //Save the pdf document. document.Save("Layer.pdf"); //Close the document. document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set page size. document.PageSettings = New PdfPageSettings(New SizeF(350, 300)) 'Add new page. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 16) 'Draw the text. page.Graphics.DrawString("Layers", font, PdfBrushes.DarkBlue, New PointF(150, 10)) 'Add the first layer page.Layers.Add() 'Get default layer graphics. Dim graphics As PdfGraphics = page.DefaultLayer.Graphics graphics.TranslateTransform(100, 60) 'Create new instance for PDF pen. Dim pen As PdfPen = New PdfPen(Color.Red, 50) Dim rect As RectangleF = New RectangleF(0, 0, 50, 50) 'Draw arc. graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Blue, 30) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) pen = New PdfPen(Color.Yellow, 20) graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Green, 10) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) 'Add another layer on the page page.Layers.Add() 'Increment the layer page.DefaultLayerIndex += 1 graphics = page.DefaultLayer.Graphics graphics.TranslateTransform(100, 180) graphics.SkewTransform(0, 50) 'Draw another set of elements pen = New PdfPen(Color.Red, 50) graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Blue, 30) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) pen = New PdfPen(Color.Yellow, 20) graphics.DrawArc(pen, rect, 360, 360) pen = New PdfPen(Color.Green, 10) graphics.DrawArc(pen, 0, 0, 50, 50, 360, 360) 'Save and close the document. document.Save("Layer.pdf") document.Close(True) Class Class Class Gets the size of the page (Read only). //Load an existing document. PdfLoadedDocument ldoc = new PdfLoadedDocument("Input.pdf"); //Get size of first page SizeF size = ldoc.Pages[0].Size; //Save and close the document. ldoc.Save("Output.pdf"); ldoc.Close(true); 'Load an existing document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Get size of first page Dim size As SizeF = ldoc.Pages(0).Size 'Save and close the document. ldoc.Save("Output.pdf") ldoc.Close(True) Class Gets the origin of the page Gets array of page's content. Gets the page dictionary. Gets or sets the PDF page rotation. The PdfPageRotateAngle that represents the page rotation //Create a PDF document PdfDocument document = new PdfDocument(); //Create a page PdfPage page = new PdfPage(); //Insert page in the document document.Pages.Insert(0, page); //Get rotation PdfPageRotateAngle angle = page.Rotation; //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a page Dim page As New PdfPage() 'Insert page in the document document.Pages.Insert(0, page) 'Get rotation Dim angle As PdfPageRotateAngle = page.Rotation 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Gets the page orientation. Returns the page template. Gets the page fields count. Get page graphics. Return true, when the page contains colored content. Gets the wrapped element. Dictionaries of terminal annotation. Collection of annotations. Holds the reference numbers of the widget annotations Internal variable to store array of annotation reference private variable to store list of redaction objects Add redaction to the PDF page. //Load the existing PDF document PdfLoadedDocument loadedDocument = new PdfLoadedDocument(docStream); //Create a redaction object PdfRedaction redaction = new PdfRedaction(new RectangleF(343, 167, 100, 25), Color.Black); //Add redaction object into redaction collection of loaded page page.AddRedaction(redaction); //Redact the contents from PDF document. loadedDocument.Redact(); //Creating the stream object MemoryStream stream = new MemoryStream(); //Save the document into stream. loadedDocument.Save(stream); //Close the documents. loadedDocument.Close(true); 'Load the existing PDF document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument(docStream) 'Create a redaction object Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(343, 167, 100, 25), Color.Black) 'Add redaction object into redaction collection of loaded page page.AddRedaction(redaction) 'Redact the contents from PDF document. loadedDocument.Redact() 'Creating the stream object Dim stream As MemoryStream = New MemoryStream() 'Save the document into stream. loadedDocument.Save(stream) 'Close the document. loadedDocument.Close(True) Gets the resources and modifies the page dictionary. Pdf resources. Parsing Xobject dictionary to get current page images Initializes a new instance of the class. The document. The cross-reference table. The page's dictionary. Retrieves the terminal annotations. Check whether annotation is form field or not. The annotation need to be check Returns true if the annotation is used by Acroform field, otherwise false. Gets the documents widget reference collection Removes field and kids annotation from dictionaries. The field. Removes all the reference for particular object The annotation need to be removed Gets the page template bounds collection Raises event. Event arguments. Raises when page dictionary is going to be saved. Sender of the event. Event arguments. Raises after the page dictionary was saved. Sender of the event. The instance containing the event data. Extract the font which are used in a given page. returns the extracted fonts as a PdfFont[]. Clears PdfLoadedPage. Gets the text size of a specified font. Font key Returns the text size of the specified font Gets the content size of the specified font. Font Key Content stream Font height Reading Font Name from Dictionary. Create metrics for embed font Gets the font style. The font family string. The style of pdf font. Gets the font family. The font family string. The font family. Gets the key value for a given font PdfFont value. Returns the key value. Calculates the bounds from dictionary bounds values. X Coordinate Y Coordinate Width Height Calculated Bounds Gets the cropbox from dictionary. Gets or Sets the collection of the page's annotations. The that represents the page's annotations //Load the document. PdfLoadedDocument lDoc = new PdfLoadedDocument("inputAnnotation.pdf"); //get the first page from the document. PdfLoadedPage page = lDoc.Pages[0] as PdfLoadedPage; //Get the annotation collection. PdfLoadedAnnotationCollection annotations = page.Annotations; //Save the document. lDoc.Save("sample.pdf"); lDoc.Close(true); 'Load the document. Dim lDoc As New PdfLoadedDocument("inputAnnotation.pdf") 'Get the first page from the document. Dim page As PdfLoadedPage = TryCast(lDoc.Pages(0), PdfLoadedPage) 'Get the annotation collections. Dim annotations As PdfLoadedAnnotationCollection = page.Annotations 'Save the document. lDoc.Save("sample.pdf") lDoc.Close(True) Class Class Gets collection of the page's redactions. list of redaction objects //Load the document. PdfLoadedDocument lDoc = new PdfLoadedDocument("input.pdf"); //Get the first page from the document. PdfLoadedPage page = lDoc.Pages[0] as PdfLoadedPage; //Create a redaction object PdfRedaction redaction = new PdfRedaction(new RectangleF(40, 40, 50, 20)); //Set fill color for the redaction bounds redaction.FillColor = System.Drawing.Color.Green; //Add redaction object into redaction collection of loaded page page.Redactions.Add(redaction); //Save and Close the document. lDoc.Save("sample.pdf"); lDoc.Close(true); 'Load the document. Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") //Create a redaction object Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(40, 40, 50, 20)) //Set fill color for the redaction bounds redaction.FillColor = Color.Green //Add redaction object into collection page.Redactions.Add(redaction) 'Save the document. lDoc.Save("sample.pdf") lDoc.Close(True) Gets the media box of the PDF page (Read only). The RectangleF that represents the media box of the page, which is intended to be displayed or printed. Media box is only read only, we cann't set value for loaded page Media box value. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get first page of loaded document. PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //Get loaded page Media box value. RectangleF rect = lpage.MediaBox; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page of loaded document. Dim lpage As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Get loaded page Media box value. Dim rect As RectangleF = lpage.MediaBox 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Gets the size of the page (Read only). /// The SizeF that represents the size of the page Gets the visible region of the page (Read only). The RectangleF that represents the crop box of the page Crop box is only read only, we cann't set value for loaded page crop box value. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get first page of loaded document. PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //Get loaded page crop box value. RectangleF rect = lpage.CropBox; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page of loaded document. Dim lpage As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Get loaded page crop box value. Dim rect As RectangleF = lpage.CropBox 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Gets page region after clipping (Read only). The RectangleF that represents the bleed box of a page Bleed box is only read only, we cann't set value for loaded page bleed box. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get first page of loaded document. PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //Get loaded page bleed box value. RectangleF rect = lpage.BleedBox; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page of loaded document. Dim lpage As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Get loaded page bleed box value. Dim rect As RectangleF = lpage.BleedBox 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Returns page region after trimming (Read only). The RectangleF that represents the trim box of a page Trim box is only read only, we cann't set value for loaded page trim box. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get first page of loaded document. PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //Get loaded page trim box value. RectangleF rect = lpage.TrimBox; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page of loaded document. Dim lpage As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Get loaded page trim box value. Dim rect As RectangleF = lpage.TrimBox 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Gets page region containing meaningful content (Read only). The RectangleF that represents the art box of the page Art box is only read only, we cann't set value for loaded page art box. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get first page of loaded document. PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //Get loaded page art box value. RectangleF rect = lpage.ArtBox; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page of loaded document. Dim lpage As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Get loaded page art box value. Dim rect As RectangleF = lpage.ArtBox 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Gets the base document (Read only). The , which is base class of PdfLoadedDocument //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get first page of loaded document. PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //Get loaded page base document. PdfLoadedDocument basedoc = lpage.Document as PdfLoadedDocument; //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Load an existing document. Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page of loaded document. Dim lpage As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Get loaded page base document. Dim basedoc As PdfLoadedDocument = TryCast(lpage.Document, PdfLoadedDocument) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Gets the ColorSpace details(Read only). //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get first page of loaded document. PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //Get loaded page base document. string colorSpace = page.ColorSpace; //Save and close the document. document.Save("Output.pdf"); document.Close(true); Class Gets the cross table. Gets or sets the terminal fields. Gets the origin coordinate of the loaded page Gets or sets the array of annotation reference Raises before the page saves. The class provides methods and properties to handle the collections of loaded PDF pages Initializes a new instance of the class. The document. The cross table. Creates a new page and adds it to the collection. The created page. Creates a new page of the specified size and adds it to the collection. The size of the new page. The created page. Creates a new page of the specified size and with the specified margins and adds it to the collection. The size of the new page. The margins of the new page. The created page. Creates a new page of the specified size and with the specified margins and adds it to the collection. The size of the new page. The margins of the new page. The rotation of the new page. The created page. Creates a new page of the specified size and with the specified margins and adds it to the collection. The size of the new page. The margins of the new page. The rotation of the new page. The location of the new page. The created page. Adds a cloned page from a loaded document. The loaded document. The page. The destinations. Adds a cloned page from a loaded document. The loaded document. The page. Creates a new page and inserts it at the specified index. The index. The created page. Creates a new page and inserts it at the specified index with specified size. The index. The size of the page. The created page. Creates a new page and inserts it at the specified index with specified size and margins. The index. The size of the page. The margins of the page. The created page. Creates a new page and inserts it at the specified index with specified size, margins and rotation angle The index. The size of the page. The margins of the page. The rotation of the new page. The created page. Removes the page at the given specified index. Index of the page. Removes the specified page. The page to be remove. Remove PdfPageTemplates from removing page Gets updated PdfPageTemplates Collection Re arrange the Pages in the Loaded Document. The page sequence to arrange the pages. //Load the PDF document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("Input.pdf"); //Rearrange the page by index loadedDocument.Pages.ReArrange(new int[] {1, 0}); //Save and close the document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Rearrange the page by index loadedDocument.Pages.ReArrange(New Integer() {1, 0}) 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Creates a new page and inserts it at the specified index with specified size,margins,rotation angle and orientation The index. The size of the page. The margins of the page. The rotation of the new page. The orientation of the new page. The created page. Inserts loaded page into loaded document at specified index The index at which page to be inserted. The page to be inserted. Gets the page. The page dictionary. The loaded page. Updates number of leaf nodes of corresponding page tree nodes starting with . The parent dictionary Returns the index of the page. The page. The index of the page. This might be a time consuming operation. Return index of page by parsing Catalog dictionary Parsing page nodes Find kids from pages dictionary Parse and find page nodes Gets the page by its index. The index. The proper PdfPageBase instance. Determines whether a node is a leaf nide. The node. true if the specified node is a leaf node; otherwise, false. Gets the node kids. The node. The node kids array. Gets the node count. The node. The number of the kids in the node. Gets the parent parent node. The index. Index of the local. if set to true zero index is a valid index. Gets the parent parent node - Should be used only in GetPage method. The index. Index of the local. if set to true zero index is a valid index. if set to true fetchs the page collection faster than native GetParent method. Clears page cache. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Gets the number of sections present in the document Get and set the Pdfloaded Document. Gets the at the specified index. Gets the number of pages presnt in the document Gets the page cache. Implements enumerator to the loaded page collection. Initializes a new instance of the class. The . Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Gets the current element in the collection. The current element in the collection. The enumerator is positioned before the first element of the collection or after the last element. The class provides methods and properties to handle the collections of . Local variable to store the PageLabel Count. Internal variable to store page Label. Internal variable to store page Label Collection. Add the to the collection Gets the number of from collection (Read only). The count. Gets the at the specified index (Read only). Gets the element. Provides methods and properties to create PDF pages and its elements, PdfPage class inherited from the PdfPageBase class The following example shows the several properties and methods of PdfPage class //Create a PDF document PdfDocument document = new PdfDocument(); //Create a page PdfPage page = new PdfPage(); //Get annotation collection PdfAnnotationCollection annotation = page.Annotations; //Get Graphics PdfGraphics graphics = page.Graphics; //Get page Layers PdfPageLayerCollection layers = page.Layers; //Get actual page size SizeF clientSize = page.GetClientSize(); //Insert page in the document document.Pages.Insert(0, page); //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a page Dim page As New PdfPage() 'Get annotation collection Dim annotation As PdfAnnotationCollection = page.Annotations 'Get Graphics Dim graphics As PdfGraphics = page.Graphics 'Get page Layers Dim layers As PdfPageLayerCollection = page.Layers 'Get actual page size Dim clientSize As SizeF = page.GetClientSize() 'Insert page in the document document.Pages.Insert(0, page) 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Class Class The variable is used to hold destination document while merging PDF Initializes a new instance of the PdfPage class. The following code example demonstrates how to construct a PdfPage //Create a PDF document PdfDocument document = new PdfDocument(); //Create a page PdfPage page = new PdfPage(); //Insert page in the document document.Pages.Insert(0, page); //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a page Dim page As New PdfPage() 'Insert page in the document document.Pages.Insert(0, page) 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Get the PDF page size reduced by page margins and page template dimensions. It's the actual size of the page where some output can be performed. Type: System.Drawing.SizeF The actual page size reduced by page margins and page template dimensions //Create a PDF document PdfDocument document = new PdfDocument(); //Create a page PdfPage page = new PdfPage(); //Insert page in the document document.Pages.Insert(0, page); //Get size of the page SizeF size = page.GetClientSize(); //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a page Dim page As New PdfPage() 'Insert page in the document document.Pages.Insert(0, page) 'Get size of the page Dim size As SizeF = page.GetClientSize() 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Raises event. Event arguments. Clears PdfPage. Sets parent section to the page. The parent section. Initializes a page. Draws page templates. Parent document. Removes template layers from the page layers. Parent document. Remove duplicate dictionary from Document Remove identical image and font resources from page resource Remove identical font resources from page resource Create hash from the current stream and returns true if present in the collection Add hash value to resource collection Optimizing descendant fonts Raises when page dictionary is going to be saved. Sender of the event. Event arguments. Raises after the page dictionary was saved. Sender of the event. The instance containing the event data. Gets the section of a page- Read only The PdfSection. Page must be added to some section before using. //Create a PDF document PdfDocument document = new PdfDocument(); //Create a page PdfPage page = new PdfPage(); //Insert page in the document document.Pages.Insert(0, page); //Get Section of a page PdfSection section = page.Section; //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a page Dim page As New PdfPage() 'Insert page in the document document.Pages.Insert(0, page) 'Get Section of a page Dim section As PdfSection = page.Section 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Class Class Gets size of the PDF page- Read only A SizeF that represents the size of the page //Create a PDF document PdfDocument document = new PdfDocument(); //Create a page PdfPage page = new PdfPage(); //Insert page in the document document.Pages.Insert(0, page); //Get size of a page SizeF size = page.Size; //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a page Dim page As New PdfPage() 'Insert page in the document document.Pages.Insert(0, page) 'Get size of a page Dim size As SizeF = page.Size 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Class Gets the origin of the page Gets a collection of the annotations of the page- Read only. A PdfAnnotationCollection that represents the annotations of the page. //Create a PDF document PdfDocument document = new PdfDocument(); //Create a page PdfPage page = new PdfPage(); //Insert page in the document document.Pages.Insert(0, page); //Get annotation collection PdfAnnotationCollection annotation = page.Annotations; //Save and close the PDF document document.Save("output.Pdf"); document.Close(true); 'Create a PDF document Dim document As New PdfDocument() 'Create a page Dim page As New PdfPage() 'Insert page in the document document.Pages.Insert(0, page) 'Get annotation collection Dim annotation As PdfAnnotationCollection = page.Annotations 'Save and close the PDF document document.Save("output.Pdf") document.Close(True) Gets current document. The pdf document. Gets or Sets the Destination document Raises before the page saves. Represents a text information Gets the text Gets the bounds of the text Gets the font name of the text. Gets the font size of the text. Gets the font style of the text. Gets the font color of the text. The used to identify each page visually on the screen or in print. Page labels and page indices need not coincide: the indices are fixed, running consecutively through the document starting from 0 for the first page, but the labels can be specified in any way that is appropriate for the particular document. Internal variable to store dictionary. Variable used to hold the start page index Initializes a new instance of the class. Converts style to a string. The style. The PDF name value representing the specified style. Converts string to numbering style. The PDF name of the style. The converted numbering style. Gets or sets the numbering style to be used for the numeric portion of each page label. The specifies numbering style of page labels. Gets or sets the label prefix for page labels. Gets or sets the value of the numeric portion for the first page label in the range The number must be greater than or equal to 1 Get or Set the Start page index for page label Gets the element. The used to create layers in PDF document. Layers refers to sections of content in a PDF document that can be selectively viewed or hidden by document authors or consumers //Create PDF document. PdfDocument document = new PdfDocument(); PdfPage page = document.Pages.Add(); //Add the first layer. PdfPageLayer layer = page.Layers.Add("Layer1"); PdfGraphics graphics = layer.Graphics; graphics.TranslateTransform(100, 60); //Draw arc. PdfPen pen = new PdfPen(System.Drawing.Color.Red, 50); RectangleF bounds = new RectangleF(0, 0, 50, 50); graphics.DrawArc(pen, bounds, 360, 360); //Add another layer on the page. PdfPageLayer layer2 = page.Layers.Add("Layer2"); graphics = layer2.Graphics; graphics.TranslateTransform(100, 180); //Draw ellipse. graphics.DrawEllipse(pen, bounds); //Save the document. document.Save("Sample.pdf"); //Close the document document.Close(true); 'Create PDF document. Dim document As New PdfDocument() Dim page As PdfPage = document.Pages.Add() 'Add the first layer. Dim layer As PdfPageLayer = page.Layers.Add("Layer1") Dim graphics As PdfGraphics = layer.Graphics graphics.TranslateTransform(100, 60) 'Draw arc. Dim pen As New PdfPen(System.Drawing.Color.Red, 50) Dim bounds As New RectangleF(0, 0, 50, 50) graphics.DrawArc(pen, bounds, 360, 360) 'Add another layer on the page. Dim layer2 As PdfPageLayer = page.Layers.Add("Layer2") graphics = layer2.Graphics graphics.TranslateTransform(100, 180) 'Draw ellipse. graphics.DrawEllipse(pen, bounds) 'Save the document. document.Save("Sample.pdf") 'Close the document document.Close(True) Parent page of the layer. Graphics context of the layer. Content of the object. Graphics state of the Graphics. Indicates whether the layer should clip page template dimensions or not. Indicates if the graphics stream was saved. Local Variable to store the colorspace of the document. Local Variable to store the layer id Local Variable to store the name Local Variable to set visiblity Collection of the layers of the page. Indicates if Sublayer is present. Local variable to store length of the graphics. Stores the print Option dictionary Stores the usage dictionary Indicates printing state Indicates the current layer have end state or not. Internal variable to store dictionary. Internal variable to store reference holder. Indicates layer presented in xObject resources Adds a new PDF Page layer. The Initializes a new instance of the class with specified PDF page. The ,parent page of the layer. Initializes a new instance of the class. The page. The stream. Creates a new layer. Parent page of the layer. Indicates whether the layer should clip page template dimensions or not. Initializes Graphics context of the layer. The page. Clears PdfPageLayer. set visibilty of layer layer visibility Catches BeforeSave of the content event. Sender of the event. event arguments. Gets the Reference holder. The reference holder. Gets the dictionary. The dictionary. Get or set the Colorspace. Gets parent page of the layer. //Create PDF document. PdfDocument document = new PdfDocument(); PdfPage page = document.Pages.Add(); //Add the first layer. PdfPageLayer layer = page.Layers.Add("Layer1"); PdfGraphics graphics = layer.Graphics; graphics.TranslateTransform(100, 60); //Draw arc. PdfPen pen = new PdfPen(System.Drawing.Color.Red, 50); RectangleF bounds = new RectangleF(0, 0, 50, 50); graphics.DrawArc(pen, bounds, 360, 360); //Add another layer on the page. PdfPageLayer layer2 = page.Layers.Add("Layer2"); graphics = layer2.Graphics; graphics.TranslateTransform(100, 180); //Draw ellipse. graphics.DrawEllipse(pen, bounds); //Save the document. document.Save("Sample.pdf"); //Close the document document.Close(true); 'Create PDF document. Dim document As New PdfDocument() Dim page As PdfPage = document.Pages.Add() 'Add the first layer. Dim layer As PdfPageLayer = page.Layers.Add("Layer1") Dim graphics As PdfGraphics = layer.Graphics graphics.TranslateTransform(100, 60) 'Draw arc. Dim pen As New PdfPen(System.Drawing.Color.Red, 50) Dim bounds As New RectangleF(0, 0, 50, 50) graphics.DrawArc(pen, bounds, 360, 360) 'Add another layer on the page. Dim layer2 As PdfPageLayer = page.Layers.Add("Layer2") graphics = layer2.Graphics graphics.TranslateTransform(100, 180) 'Draw ellipse. graphics.DrawEllipse(pen, bounds) 'Save the document. document.Save("Sample.pdf") 'Close the document document.Close(True) Gets or sets the name of the layer specifies whether visibility of the layer Gets Graphics context of the layer, used to draw various graphical content on layer. The used to draw various graphical content //Create PDF document. PdfDocument document = new PdfDocument(); PdfPage page = document.Pages.Add(); //Add the first layer. PdfPageLayer layer = page.Layers.Add("Layer1"); PdfGraphics graphics = layer.Graphics; graphics.TranslateTransform(100, 60); //Draw arc. PdfPen pen = new PdfPen(System.Drawing.Color.Red, 50); RectangleF bounds = new RectangleF(0, 0, 50, 50); graphics.DrawArc(pen, bounds, 360, 360); //Add another layer on the page. PdfPageLayer layer2 = page.Layers.Add("Layer2"); graphics = layer2.Graphics; graphics.TranslateTransform(100, 180); //Draw ellipse. graphics.DrawEllipse(pen, bounds); //Save the document. document.Save("Sample.pdf"); //Close the document document.Close(true); 'Create PDF document. Dim document As New PdfDocument() Dim page As PdfPage = document.Pages.Add() 'Add the first layer. Dim layer As PdfPageLayer = page.Layers.Add("Layer1") Dim graphics As PdfGraphics = layer.Graphics graphics.TranslateTransform(100, 60) 'Draw arc. Dim pen As New PdfPen(System.Drawing.Color.Red, 50) Dim bounds As New RectangleF(0, 0, 50, 50) graphics.DrawArc(pen, bounds, 360, 360) 'Add another layer on the page. Dim layer2 As PdfPageLayer = page.Layers.Add("Layer2") graphics = layer2.Graphics graphics.TranslateTransform(100, 180) 'Draw ellipse. graphics.DrawEllipse(pen, bounds) 'Save the document. document.Save("Sample.pdf") 'Close the document document.Close(True) Gets and sets printing state of the PDF page layer Gets the collection of , this collection handle by the class The used to handle collection of Gets the wrapped element. The class provides methods and properties to handle the collections of //Create PDF document. PdfDocument document = new PdfDocument(); PdfPage page = document.Pages.Add(); //Add the first layer. PdfPageLayer layer = page.Layers.Add("Layer1"); PdfGraphics graphics = layer.Graphics; graphics.TranslateTransform(100, 60); //Draw arc. PdfPen pen = new PdfPen(System.Drawing.Color.Red, 50); RectangleF bounds = new RectangleF(0, 0, 50, 50); graphics.DrawArc(pen, bounds, 360, 360); //Add another layer on the page. PdfPageLayer layer2 = page.Layers.Add("Layer2"); graphics = layer2.Graphics; graphics.TranslateTransform(100, 180); //Draw ellipse. graphics.DrawEllipse(pen, bounds); //Save the document. document.Save("Sample.pdf"); //Close the document document.Close(true); 'Create PDF document. Dim document As New PdfDocument() Dim page As PdfPage = document.Pages.Add() 'Add the first layer. Dim layer As PdfPageLayer = page.Layers.Add("Layer1") Dim graphics As PdfGraphics = layer.Graphics graphics.TranslateTransform(100, 60) 'Draw arc. Dim pen As New PdfPen(System.Drawing.Color.Red, 50) Dim bounds As New RectangleF(0, 0, 50, 50) graphics.DrawArc(pen, bounds, 360, 360) 'Add another layer on the page. Dim layer2 As PdfPageLayer = page.Layers.Add("Layer2") graphics = layer2.Graphics graphics.TranslateTransform(100, 180) 'Draw ellipse. graphics.DrawEllipse(pen, bounds) 'Save the document. document.Save("Sample.pdf") 'Close the document document.Close(True) Parent page. Indicates if Sublayer is present. Stores the number of first level layers in the document. Stores the optional content dictionary Stores the layer id and helps to avoid the duplicate entries. Indicates if the loaded layers have resource dictionary. Helps to lock Adding layers to page in multi threading BeginMarkContent count variable used to maintain layers in loaded document Initializes a new instance of the class Initializes a new instance of the class with PDF page Parent page for the layers in the collection. Creates a new and adds it to the end of the collection. Created Creates a new with name and Boolean flag to set the visibility of layer, and adds it to the end of the collection. Layer Name. Layer Visibility. Created . Creates a new with name and adds it to the end of the collection. Layer Name. Created . Adds to the collection. The object. The layers belonging to the same page can be added to the collection only. Creates a Optional Content Properties and adds it to Catalog. Layer. Creates Usage Dictionary and adds it to OCG dictionary creates a pdf page layer from loaded page Inserts into the collection at specified index Index of the layer. object. The layers belonging to the same page can be added to the collection only. Creates a Optional Content Groups and adds it to OC Properties. Layer. primitive as pdfarray. Creates a Optional Content Groups and adds it to OC Properties. Layer. primitive as pdfarray. Writes End of Marked Content in Content Stream Creates Optional Content Views and adds it to OC Properties. Layer. m_dictionary. Creates Optional Content Views and adds it to OC Properties. Layer. m_dictionary. Removes layer from the collection. object. Removes from the collection by its name. Name of the layer. Removes layer by its index from collections Index of the layer. Checks whether collection contains . object. True - if collection contains layer, False otherwise. Returns index of the in the collection if exists, -1 otherwise. object. Returns index of the layer in the collection if exists, -1 otherwise. Clears layers from the . Combines the content into the specified stream. The stream. Combine page content into specified stream Registers layer at the page. Index of the layer in the collection. The new layer. Removes layer from the page. The layer. Remove layer reference from ocg, order, on and off array Remove layer reference from ocg, order, on and off array Registers layer at the page. Index of the layer in the collection. The new layer. Parses the layers. The loaded page. Check visibilty of loaded layer Make layers as correct order, based on Optical content group Check whether page contains any layer Add layer to page Parse resouces contains layer Remove Layer content from page Find Operator Rewrite PDFLayer content stream Process Begin Mark Content to remove layer content Process layer content Gets or sets by its index from The layers belonging to the same page can be added to the collection only. Skip Operators The used to create layers in PDF document. Layers refers to sections of content in a PDF document that can be selectively viewed or hidden by document authors or consumers Parent page of the layer. Graphics context of the layer. Content of the object. Graphics state of the Graphics. Indicates whether the layer should clip page template dimensions or not. Indicates if the graphics stream was saved. Local Variable to store the colorspace of the document. Local Variable to store the layer id Local Variable to store the name Local Variable to set visiblity Stores the print Option dictionary Stores the usage dictionary Indicates printing state Indicates the current layer have end state or not. Internal variable to store dictionary. Internal variable to store reference holder. Internal variable to store layer Indicates document of layer Indicates to store list of pages used for same layer Indicates collection of layer Indicates if Sublayer is present. indicates the poisition of sublayer indicates variable to store sublayer of PDF layer Indicates Lock State internal variable to store locked array internal variable to maintain list of parent layers internal variable to maintain child layers internal variable to maintain parent layer Dictionary to maintain all graphics content of current layer Dictionary to maintain all graphics content of current layer belong to page internal varible helps to parse the layer page onces varible helps to parse and get content stream collection helps to maintain layer contains in xobject resources Initializes a new instance of the Initializes Graphics context of the layer. The page. Clears PdfLayer. set visibilty of the layer layer visibility Set lock state for layer Set PrintState for layer Catches BeforeSave of the content event. Sender of the event. event arguments. Write Begin Mark Content of layer Create new content stream for PdfLayer Parsing PdfPagelayer and set the content stream to Pdflayer Parsing all pages and set page information to required layer Parse the dictionary that contains required layer Set the page information to layer Gets or sets the Reference holder. The reference holder. Gets or sets the dictionary. The dictionary. Get or set the Colorspace. Gets or sets page of the layer. Gets or sets the document of layer Gets or sets the layerId Gets or sets the layer Gets or sets the name of the layer Gets or sets the visible of the layer Gets Graphics context of the layer, used to draw various graphical content on layer. The used to draw various graphical content Gets or sets printing state of the layer Gets the collection of child The used to handle collection of Gets or sets a lock state of a layer //Create new PDF document PdfDocument document = new PdfDocument(); //Add page PdfPage page = document.Pages.Add(); //Add the layer PdfLayer layer = document.Layers.Add("Layer"); //Set a lock state layer.Locked = true; //Create graphics for layer PdfGraphics graphics = layer.CreateGraphics(page); //Draw ellipse graphics.DrawEllipse(PdfPens.Red, new RectangleF(50, 50, 40, 40)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create new PDF document Dim document As PdfDocument = New PdfDocument() 'Add page Dim page As PdfPage = document.Pages.Add() 'Add the layer Dim layer As PdfLayer = document.Layers.Add("Layer") 'Set a lock state layer.Locked = True 'Create graphics for layer Dim graphics As PdfGraphics = layer.CreateGraphics(page) 'Draw ellipse graphics.DrawEllipse(PdfPens.Red, New RectangleF(50, 50, 40, 40)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets the layer content stream Gets the wrapped element. The class provides methods and properties to handle the collections of Indicates if Sublayer is present. Stores the optional content dictionary Indicates if the loaded layers have resource dictionary. Helps to lock Adding layers to page in multi threading Indicates document to create layer in PDF document Indicates sublayer of layers in PDF layer Indicates a dictionary to store all layer in PDF document BeginMarkContent count Initializes a new instance of the class Initializes a new instance of the class Initializes a new instance of the class Creates a new with name and Boolean flag to set the visibility of layer, and adds it to the end of the collection. Layer Name. Layer Visibility. Created . Creates a new with name and adds it to the end of the collection. Layer Name. Created . Add layer in list collection of PDFLayer index of created layer Creates a Optional Content Properties and adds it to Catalog. Layer. Creates Usage Dictionary and adds it to OCG dictionary Creates a pdf layer from loaded PDF document Move into the collection at specified index Index of the layer. object. Creates a Optional Content Groups and adds it to OC Properties. Layer. primitive as pdfarray. Creates a Optional Content Groups and adds it to OC Properties. Layer. primitive as pdfarray. Creating Nested/Sublayer layer for parent layer Creates Optional Content Views and adds it to OC Properties. Layer. m_dictionary. Creates Optional Content Views and adds it to OC Properties. Layer. m_dictionary. Removes layer from the collection of Layer. object. Removes layer from the collection and remove graphical content, If removeGraphicalContent is true. object. Removes from the collection by its name. If document have muliple layer with same name, it removes all PdfLayers from document. Name of the layer. Remove layer from its collection by its name and remove graphical content, If removeGraphicalContent is true Removes layer by its index from collections Index of the layer. Removes layer by its index from collections and remove graphical content if removeGraphicalContent is true Index of the layer. Checks whether collection contains . object. True - if collection contains layer, False otherwise. Checks whether collection contains by layer name. True - if collection contains layer, False otherwise. Returns index of the in the collection if exists, -1 otherwise. object. Returns index of the layer in the collection if exists, -1 otherwise. Clears layers from the . Remove layer from document and remove graphics if remove content is true Registers layer at specified index in layer collection Index of the layer in the collection. Pdf layer. Check and set layer visible Check and set layer lock Remove layer reference from OCGroup Remove layer reference from usage application Remove layer reference from Order Remove layer reference from On and Off Remove layer reference from locked Remove graphics content for PDF layer Check parent layer Parsing order array to get parent layer Find Operator Rewrite PDFLayer content stream Process Begin Mark Content to remove layer content Create layer with respective hierarchical Add child layers Gets or sets by its index from Skip Operators The class provides various setting related with PDF pages //Create a new document. PdfDocument doc = new PdfDocument(); //Set page settings. doc.PageSettings.Orientation = PdfPageOrientation.Landscape; doc.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle180; //Create a new page. PdfPage page = doc.Pages.Add(); doc.Save("output.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Set page settings doc.PageSettings.Orientation = PdfPageOrientation.Landscape doc.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle180 'Create a new page Dim page As PdfPage = doc.Pages.Add() doc.Save("output.pdf") doc.Close(True) Class Internal variable to store transition. Initializes a new instance of the class. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for document margin. PdfMargins margin = new PdfMargins(); margin.All = 20; //Create new instance for page settings. PdfPageSettings setting = new PdfPageSettings(); //Set document margin. setting.Margins = margin; doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for document margin. Dim margin As PdfMargins = New PdfMargins() margin.All = 20 'Create new instance for page settings. Dim setting As PdfPageSettings = New PdfPageSettings() 'Set document margin. setting.Margins = margin doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with size. The size. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for document margin. PdfMargins margin = new PdfMargins(); margin.All = 20; //Create new instance for page settings with predefined page size. PdfPageSettings setting = new PdfPageSettings(new SizeF(300,300)); //Set document margin. setting.Margins = margin; doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for document margin. Dim margin As PdfMargins = New PdfMargins() margin.All = 20 'Create new instance for page settings with predefined page size. Dim setting As PdfPageSettings = New PdfPageSettings(New SizeF(300, 300)) 'Set document margin. setting.Margins = margin doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with page orientation. The . //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for document margin. PdfMargins margin = new PdfMargins(); margin.All = 20; //Create new instance for page settings with predefined page orientation. PdfPageSettings setting = new PdfPageSettings(PdfPageOrientation.Landscape); //Set document margin. setting.Margins = margin; doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for document margin. Dim margin As PdfMargins = New PdfMargins() margin.All = 20 'Create new instance for page settings with predefined page orientation. Dim setting As PdfPageSettings = New PdfPageSettings(PdfPageOrientation.Landscape) 'Set document margin. setting.Margins = margin doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with size and page orientation. The size. The page orientation. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for document margin. PdfMargins margin = new PdfMargins(); margin.All = 20; //Create new instance for page settings with predefined page orientation. PdfPageSettings setting = new PdfPageSettings(new SizeF(300, 600), PdfPageOrientation.Landscape); //Set document margin. setting.Margins = margin; doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for document margin. Dim margin As PdfMargins = New PdfMargins() margin.All = 20 'Create new instance for page settings with predefined page size and orientation. Dim setting As PdfPageSettings = New PdfPageSettings(New SizeF(300, 600), PdfPageOrientation.Landscape) 'Set document margin. setting.Margins = margin doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with margins. The margins. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for page settings with margin value. PdfPageSettings setting = new PdfPageSettings(50f); doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for page settings with predefined margin value. Dim setting As PdfPageSettings = New PdfPageSettings(50F) doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with left margin,top margin,right margin. The left margin. The top margin. The right margin. The bottom margin. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for page settings with left margin,top margin,right margin. PdfPageSettings setting = new PdfPageSettings(20f, 50f, 20f, 50f); doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for page settings with left margin,top margin,right margin. Dim setting As PdfPageSettings = New PdfPageSettings(20F, 50F, 20F, 50F) doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with size and margins The size of the page. The margins. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for page settings with predefined page size and margin value. PdfPageSettings setting = new PdfPageSettings(new SizeF(300, 600),20f); doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for page settings with predefined page size and margin value. Dim setting As PdfPageSettings = New PdfPageSettings(New SizeF(300, 600), 20F) doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with size left,top,right,bottom margins. The size. The left margin. The top margin. The right margin. The bottom margin. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for page settings with predefined page size and margin value. PdfPageSettings setting = new PdfPageSettings(new SizeF(300, 600), 20f, 50f, 20f, 50f); doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for page settings with predefined page size and margin value. Dim setting As PdfPageSettings = New PdfPageSettings(New SizeF(300, 600), 20F, 50F, 20F, 50F) doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with size,page orientation,margins The size. The page orientation. The margins. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for page settings with predefined page size , orientation and margin value. PdfPageSettings setting = new PdfPageSettings(new SizeF(300, 600), PdfPageOrientation.Landscape, 20f); doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for page settings with predefined page size , orientation and margin value. Dim setting As PdfPageSettings = New PdfPageSettings(New SizeF(300, 600), PdfPageOrientation.Landscape,20F) doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Initializes a new instance of the class with size page orientation,left,top,right,bottom margins. The size. The page orientation. The left margin. The top margin. The right margin. The bottom margin. //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for page settings with predefined page size , orientation and left,top,right,bottom margins. PdfPageSettings setting = new PdfPageSettings(new SizeF(300, 600), PdfPageOrientation.Landscape, 20f, 50f, 20f, 50f); doc.PageSettings = setting; //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for page settings with predefined page size , orientation and left,top,right,bottom margins. Dim setting As PdfPageSettings = New PdfPageSettings(New SizeF(300, 600), PdfPageOrientation.Landscape,20F, 50F, 20F, 50F) doc.PageSettings = setting 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Sets the margins to the page. The margins. //Create a new document. PdfDocument doc = new PdfDocument(); //Set margins for pdf document. doc.PageSettings.SetMargins(10); //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Set margins for pdf document. doc.PageSettings.SetMargins(10) 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Sets the left right and top bottom margins. The left right margin. The top bottom margin. //Create a new document. PdfDocument doc = new PdfDocument(); //Set margins for pdf document. doc.PageSettings.SetMargins(10, 10); //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Set margins for pdf document. doc.PageSettings.SetMargins(10, 10) 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Sets the left,top,right,bottom margins. The left margin. The top margin. The right margin. The bottom margin. //Create a new document. PdfDocument doc = new PdfDocument(); //Set margins for pdf document. doc.PageSettings.SetMargins(10, 10, 10, 10); //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("Output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Set margins for pdf document. doc.PageSettings.SetMargins(10, 10, 10, 10) 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Class Class Class Creates a clone of the object. Cloned object. Returns size, shrinked by the margins. Returns size, shrinked by the margins. Gets the transition. Update page size depending on orientation. Page orientation settings. Sets size to the page aaccording to the orientation. /// Size of the page. Sets orientation to the page based on its size. Gets or sets the page orientation. The , provides the orientation of the PDF page //Create a new document. PdfDocument doc = new PdfDocument(); //Set page settings. doc.PageSettings.Orientation = PdfPageOrientation.Landscape; doc.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle180; //Create a new page. PdfPage page = doc.Pages.Add(); doc.Save("output.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Set page settings doc.PageSettings.Orientation = PdfPageOrientation.Landscape doc.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle180 'Create a new page Dim page As PdfPage = doc.Pages.Add() doc.Save("output.pdf") doc.Close(True) Class Gets or sets the size of the page. Default value: 595 * 842 pixels //Create a new document. PdfDocument doc = new PdfDocument(); //Set page size. doc.PageSettings.Size = new SizeF(600, 600); //Create a new page. PdfPage page = doc.Pages.Add(); doc.Save("output.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Set page size doc.PageSettings.Size = New SizeF(600, 600) 'Create a new page Dim page As PdfPage = doc.Pages.Add() doc.Save("output.pdf") doc.Close(True) Class Gets or sets the width of the page. Default value: 595 pixels //Create a new document. PdfDocument doc = new PdfDocument(); //Set page width. doc.PageSettings.Width = 300; //Create a new page. PdfPage page = doc.Pages.Add(); doc.Save("output.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Set page width doc.PageSettings.Width = 300 'Create a new page Dim page As PdfPage = doc.Pages.Add() doc.Save("output.pdf") doc.Close(True) Class Gets or sets the height of the page. Default value: 842 pixels //Create a new document. PdfDocument doc = new PdfDocument(); //Set page size. doc.PageSettings.Height = 300; //Create a new page. PdfPage page = doc.Pages.Add(); doc.Save("output.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Set page size doc.PageSettings.Height = 300 'Create a new page Dim page As PdfPage = doc.Pages.Add() doc.Save("output.pdf") doc.Close(True) Class Gets or sets the margins of the page. The , provides margins to the PDF page //Create a new document. PdfDocument doc = new PdfDocument(); //Create new instance for document margin. PdfMargins margin = new PdfMargins(); margin.All = 20; //Set document margin. doc.PageSettings.Margins = margin //Create a new page. PdfPage page = doc.Pages.Add(); //Create new PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Courier, 12); //Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, new PointF(100, 100)); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() 'Create new instance for document margin. Dim margin As PdfMargins = New PdfMargins() margin.All = 20 'Set document margin. doc.PageSettings.Margins = margin 'Create a new page. Dim page As PdfPage = doc.Pages.Add() 'Create new PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Courier, 12) 'Draw the text. page.Graphics.DrawString("Hello world", font, PdfBrushes.Blue, New PointF(100, 100)) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Gets or sets the number of degrees by which the page should be rotated clockwise when displayed or printed. The ,provides number of degrees by which the page should be rotated clockwise when displayed or printed Default value: RotateAngle0 //Create a new document. PdfDocument doc = new PdfDocument(); //Set page settings. doc.PageSettings.Orientation = PdfPageOrientation.Landscape; //Set rotation angle. doc.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle180; //Create a new page. PdfPage page = doc.Pages.Add(); doc.Save("output.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() 'Set page settings doc.PageSettings.Orientation = PdfPageOrientation.Landscape 'Set rotation angle doc.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle180 'Create a new page Dim page As PdfPage = doc.Pages.Add() doc.Save("output.pdf") doc.Close(True) Class Gets or sets the transition, it determines how to display the page in the presentation mode The determines how to display the page in the presentation mode. //Create a new document. PdfDocument doc = new PdfDocument(); doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; //create a page transition. PdfPageTransition transition = new PdfPageTransition(); transition.Direction = PdfTransitionDirection.TopLeftToBottomRight; transition.Dimension = PdfTransitionDimension.Vertical; transition.Motion = PdfTransitionMotion.Outward; transition.PageDuration = 3; //Set page transition. doc.PageSettings.Transition = transition; //Create a new page PdfPage page = doc.Pages.Add(); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen 'create a page transition. Dim transition As PdfPageTransition = New PdfPageTransition() transition.Direction = PdfTransitionDirection.TopLeftToBottomRight transition.Dimension = PdfTransitionDimension.Vertical transition.Motion = PdfTransitionMotion.Outward transition.PageDuration = 3 'Set page transition. doc.PageSettings.Transition = transition Dim page As PdfPage = doc.Pages.Add() 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Gets or sets the type of default user space units. For PDF 1.6 and later versions. Gets or sets the origin of the page Describes a page template object that can be used as header/footer, watermark or stamp. To know more about refer this link . //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); //Add a page to the PDF document. PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, pdfDocument.Pages[0].GetClientSize().Width, 50); PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Logo.png"); //Draw the image in the header. header.Graphics.DrawImage(image, new PointF(0, 0), new SizeF(100, 50)); //Add the header at the top. pdfDocument.Template.Top = header; //Create a Page template that can be used as footer. PdfPageTemplateElement footer = new PdfPageTemplateElement(bounds); //Create new instance for PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 7); //Create new brush for PDF brush. PdfBrush brush = new PdfSolidBrush(Color.Black); //Create page number field. PdfPageNumberField pageNumber = new PdfPageNumberField(font, brush); //Create page count field. PdfPageCountField count = new PdfPageCountField(font, brush); //Add the fields in composite fields. PdfCompositeField compositeField = new PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count); compositeField.Bounds = footer.Bounds; //Draw the composite field in footer. compositeField.Draw(footer.Graphics, new PointF(470, 40)); //Add the footer template at the bottom. pdfDocument.Template.Bottom = footer; //Save and close the document. pdfDocument.Save("Output.pdf"); pdfDocument.Close(true); 'Create new document. Dim pdfDocument As PdfDocument = New PdfDocument() 'Add a page to the PDF document. Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a header and draw the image. Dim header As PdfPageTemplateElement = New PdfPageTemplateElement(0, 0, pdfDocument.Pages(0).GetClientSize().Width, 50) Dim image As PdfImage = New PdfBitmap("in.png") 'Draw the image in the header. header.Graphics.DrawImage(image, New PointF(0, 0), New SizeF(100, 50)) 'Add the header at the top. pdfDocument.Template.Top = header Dim footer As PdfPageTemplateElement = New PdfPageTemplateElement(0, 0, pdfDocument.Pages(0).GetClientSize().Width, 50) 'Create new instance for PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 7) 'Create new instance for PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Create page number field. Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font, brush) 'Create page count field. Dim count As PdfPageCountField = New PdfPageCountField(font, brush) 'Add the fields in composite fields. Dim compositeField As PdfCompositeField = New PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count) compositeField.Bounds = footer.Bounds 'Draw the composite field in footer. compositeField.Draw(footer.Graphics, New PointF(470, 40)) 'Add the footer template at the bottom. pdfDocument.Template.Bottom = footer 'Save and close the document. pdfDocument.Save("Output.pdf") pdfDocument.Close(True) Class Class Class Class Class Layer type of the template. Docking style. Alignment style. PdfTemplate object. Usage type of this template. Location of the template on the page. Initializes a new instance of the class with specified value. Bounds of the template. //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); //Add a page to the PDF document. PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, pdfDocument.Pages[0].GetClientSize().Width, 50); PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Logo.png"); //Draw the image in the header. header.Graphics.DrawImage(image, new PointF(0, 0), new SizeF(100, 50)); //Add the header at the top. pdfDocument.Template.Top = header; //Create a Page template that can be used as footer. PdfPageTemplateElement footer = new PdfPageTemplateElement(bounds); //Create new instance for PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 7); //Create new brush for PDF brush. PdfBrush brush = new PdfSolidBrush(Color.Black); //Create page number field. PdfPageNumberField pageNumber = new PdfPageNumberField(font, brush); //Create page count field. PdfPageCountField count = new PdfPageCountField(font, brush); //Add the fields in composite fields. PdfCompositeField compositeField = new PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count); compositeField.Bounds = footer.Bounds; //Draw the composite field in footer. compositeField.Draw(footer.Graphics, new PointF(470, 40)); //Add the footer template at the bottom. pdfDocument.Template.Bottom = footer; //Save and close the document. pdfDocument.Save("Output.pdf"); pdfDocument.Close(true); 'Create new document. Dim pdfDocument As PdfDocument = New PdfDocument() 'Add a page to the PDF document. Dim pdfPage As PdfPage = pdfDocument.Pages.Add() Dim bounds As RectangleF = New RectangleF(0, 0, pdfDocument.Pages(0).GetClientSize().Width, 50) 'Create a header and draw the image. Dim header As PdfPageTemplateElement = New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("in.png") 'Draw the image in the header. header.Graphics.DrawImage(image, New PointF(0, 0), New SizeF(100, 50)) 'Add the header at the top. pdfDocument.Template.Top = header Dim footer As PdfPageTemplateElement = New PdfPageTemplateElement(bounds) 'Create new instance for PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 7) 'Create new instance for PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Create page number field. Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font, brush) 'Create page count field. Dim count As PdfPageCountField = New PdfPageCountField(font, brush) 'Add the fields in composite fields. Dim compositeField As PdfCompositeField = New PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count) compositeField.Bounds = footer.Bounds 'Draw the composite field in footer. compositeField.Draw(footer.Graphics, New PointF(470, 40)) 'Add the footer template at the bottom. pdfDocument.Template.Bottom = footer 'Save and close the document. pdfDocument.Save("Output.pdf") pdfDocument.Close(True) Class Class Class Class Class Initializes a new instance of the class with specified value and . The bounds. The page. Creates a new page template. Location of the template. Size of the template. Initializes a new instance of the class. The location. The size. The page. Creates new page template object. Size of the template. Creates a new page template. Width of the template. Height of the template. Creates a new page template. Width of the template. Height of the template. The Current Page object. Creates a new page template. X co-ordinate of the template. Y co-ordinate of the template. Width of the template. Height of the template. //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); //Add a page to the PDF document. PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a header and draw the image. PdfPageTemplateElement header = new PdfPageTemplateElement(0, 0, pdfDocument.Pages[0].GetClientSize().Width, 50); PdfImage image = new PdfBitmap(@"Logo.png"); //Draw the image in the header. header.Graphics.DrawImage(image, new PointF(0, 0), new SizeF(100, 50)); //Add the header at the top. pdfDocument.Template.Top = header; //Create a Page template that can be used as footer. PdfPageTemplateElement footer = new PdfPageTemplateElement(0, 0, pdfDocument.Pages[0].GetClientSize().Width, 50); //Create new instance for PDF font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 7); //Create new brush for PDF brush. PdfBrush brush = new PdfSolidBrush(Color.Black); //Create page number field. PdfPageNumberField pageNumber = new PdfPageNumberField(font, brush); //Create page count field. PdfPageCountField count = new PdfPageCountField(font, brush); //Add the fields in composite fields. PdfCompositeField compositeField = new PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count); compositeField.Bounds = footer.Bounds; //Draw the composite field in footer. compositeField.Draw(footer.Graphics, new PointF(470, 40)); //Add the footer template at the bottom. pdfDocument.Template.Bottom = footer; //Save and close the document. pdfDocument.Save("Output.pdf"); pdfDocument.Close(true); 'Create new document. Dim pdfDocument As PdfDocument = New PdfDocument() 'Add a page to the PDF document. Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a header and draw the image. Dim header As PdfPageTemplateElement = New PdfPageTemplateElement(0, 0, pdfDocument.Pages(0).GetClientSize().Width, 50) Dim image As PdfImage = New PdfBitmap("in.png") 'Draw the image in the header. header.Graphics.DrawImage(image, New PointF(0, 0), New SizeF(100, 50)) 'Add the header at the top. pdfDocument.Template.Top = header Dim footer As PdfPageTemplateElement = New PdfPageTemplateElement(0, 0, pdfDocument.Pages(0).GetClientSize().Width, 50) 'Create new instance for PDF font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 7) 'Create new instance for PDF brush. Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) 'Create page number field. Dim pageNumber As PdfPageNumberField = New PdfPageNumberField(font, brush) 'Create page count field. Dim count As PdfPageCountField = New PdfPageCountField(font, brush) 'Add the fields in composite fields. Dim compositeField As PdfCompositeField = New PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count) compositeField.Bounds = footer.Bounds 'Draw the composite field in footer. compositeField.Draw(footer.Graphics, New PointF(470, 40)) 'Add the footer template at the bottom. pdfDocument.Template.Bottom = footer 'Save and close the document. pdfDocument.Save("Output.pdf") pdfDocument.Close(True) Class Class Class Class Class Creates a new page template. X co-ordinate of the template. Y co-ordinate of the template. Width of the template. Height of the template. The Current Page object. Draws the template. Parent layer. Parent document. Updates Dock property if template is used as header/footer. Type of the template. Resets alignment of the template. Sets alignment of the template. Alignment style. Calculates bounds of the page template. Parent page. Parent document. Bounds of the page template. Calculates bounds according to the alignment. Parent page. Parent document. Bounds according to the alignment. Calculates bounds according to the alignment. Parent page. Parent document. Bounds according to the alignment. Calculates bounds according to the alignment. Parent page. Parent document. Bounds according to the alignment. Calculates bounds according to the docking. Parent page. Parent document. Bounds according to the docking. Calculates template bounds basing on docking if template is not page template. Parent page. Parent document. Calculates template bounds basing on docking if template is a page template. Parent page. Parent document. Gets or sets the dock style of the page template element. //Create new document. PdfDocument document = new PdfDocument(); //Set margin for document. document.PageSettings.SetMargins(25f); //Add new page. PdfPage page = document.Pages.Add(); RectangleF rect = new RectangleF(0, 0, 100, 100); //Create new instance of PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.LightBlue); //Create new instance of PDF pen. PdfPen pen = new PdfPen(Color.Orange, 3f); //Create new instance for PDF page template element. PdfPageTemplateElement custom = new PdfPageTemplateElement(rect); document.Template.Stamps.Add(custom); //Set dock style custom.Dock = PdfDockStyle.Right; //Draw template into pdf page. custom.Graphics.DrawRectangle(pen, brush, rect); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set margin for document. document.PageSettings.SetMargins(25.0F) 'Add new page. Dim page As PdfPage = document.Pages.Add() Dim rect As RectangleF = New RectangleF(0, 0, 100, 100) 'Create new instance of PDF solid brush. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.LightBlue) 'Create new instance of PDF pen. Dim pen As PdfPen = New PdfPen(Color.Orange, 3.0F) 'Create new instance for PDF page template element. Dim custom As PdfPageTemplateElement = New PdfPageTemplateElement(rect) document.Template.Stamps.Add(custom) 'Set dock style custom.Dock = PdfDockStyle.Right 'Draw template into pdf page. custom.Graphics.DrawRectangle(pen, brush, rect) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Gets or sets alignment of the page template element. //Create new document. PdfDocument document = new PdfDocument(); //Set margin for document. document.PageSettings.SetMargins(25f); //Add new page. PdfPage page = document.Pages.Add(); RectangleF rect = new RectangleF(0, 0, 100, 100); //Create new instance of PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.LightBlue); //Create new instance of PDF pen. PdfPen pen = new PdfPen(Color.Orange, 3f); //Create new instance for PDF page template element. PdfPageTemplateElement custom = new PdfPageTemplateElement(rect); document.Template.Stamps.Add(custom); //Set alignment style custom.Alignment = PdfAlignmentStyle.TopCenter; //Draw template into pdf page. custom.Graphics.DrawRectangle(pen, brush, rect); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set margin for document. document.PageSettings.SetMargins(25.0F) 'Add new page. Dim page As PdfPage = document.Pages.Add() Dim rect As RectangleF = New RectangleF(0, 0, 100, 100) 'Create new instance of PDF solid brush. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.LightBlue) 'Create new instance of PDF pen. Dim pen As PdfPen = New PdfPen(Color.Orange, 3.0F) 'Create new instance for PDF page template element. Dim custom As PdfPageTemplateElement = New PdfPageTemplateElement(rect) document.Template.Stamps.Add(custom) 'Set alignment style custom.Alignment = PdfAlignmentStyle.TopCenter 'Draw template into pdf page. custom.Graphics.DrawRectangle(pen, brush, rect) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Indicates whether the page template is located in front of the page layers or behind of it. If false, the page template will be located behind of page layer. //Create new document. PdfDocument document = new PdfDocument(); //Set margin for document. document.PageSettings.SetMargins(25f); //Add new page. PdfPage page = document.Pages.Add(); RectangleF rect = new RectangleF(0, 0, 100, 100); //Create new instance of PDF solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.LightBlue); //Create new instance of PDF pen. PdfPen pen = new PdfPen(Color.Orange, 3f); //Create new instance for PDF page template element. PdfPageTemplateElement custom = new PdfPageTemplateElement(rect); document.Template.Stamps.Add(custom); //Set alignment style custom.Dock = PdfDockStyle.Left; //Set foreground custom.Foreground = false; //Draw template into pdf page. custom.Graphics.DrawRectangle(pen, brush, rect); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set margin for document. document.PageSettings.SetMargins(25.0F) 'Add new page. Dim page As PdfPage = document.Pages.Add() Dim rect As RectangleF = New RectangleF(0, 0, 100, 100) 'Create new instance of PDF solid brush. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.LightBlue) 'Create new instance of PDF pen. Dim pen As PdfPen = New PdfPen(Color.Orange, 3.0F) 'Create new instance for PDF page template element. Dim custom As PdfPageTemplateElement = New PdfPageTemplateElement(rect) document.Template.Stamps.Add(custom) 'Set dock style custom.Dock = PdfDockStyle.Left 'Set foreground custom.Foreground = True 'Draw template into pdf page. custom.Graphics.DrawRectangle(pen, brush, rect) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Indicates whether the page template is located behind of the page layers or in front of it. Gets or sets location of the page template element. Gets or sets X co-ordinate of the template element on the page. Gets or sets Y co-ordinate of the template element on the page. Gets or sets size of the page template element. Gets or sets width of the page template element. Gets or sets height of the page template element. Gets or sets bounds of the page template element. Gets graphics context of the page template element. Gets Pdf template object. Gets or sets type of the usage of this page template. Gets or sets the tag for the element Represents parameters how to display the page in the presentation mode. //Create a new document PdfDocument doc = new PdfDocument(); doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; //create a page transition PdfPageTransition transition = new PdfPageTransition(); transition.Direction = PdfTransitionDirection.TopLeftToBottomRight; transition.Dimension = PdfTransitionDimension.Vertical; transition.Motion = PdfTransitionMotion.Outward; transition.PageDuration = 3; doc.PageSettings.Transition = transition; //Create a new page PdfPage page = doc.Pages.Add(); doc.Save("output.pdf"); doc.Close(true); 'Create a new document Dim doc As New PdfDocument() doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen 'create a page transition Dim transition As New PdfPageTransition() transition.Direction = PdfTransitionDirection.TopLeftToBottomRight transition.Dimension = PdfTransitionDimension.Vertical transition.Motion = PdfTransitionMotion.Outward transition.PageDuration = 3 doc.PageSettings.Transition = transition 'Create a new page Dim page As PdfPage = doc.Pages.Add() doc.Save("output.pdf") doc.Close(True) Internal variable to store dictionary. Internal variable to store transition style. Internal value to store transtion duration. Internal variable to store transition dimension. Internal variable to store transition motion. Internal variable to store transition motion. Internal variable to store scale. Internal variable to store page duration. Initializes a new instance of the class. //Create a new document. PdfDocument doc = new PdfDocument(); doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; //create a page transition. PdfPageTransition transition = new PdfPageTransition(); transition.Direction = PdfTransitionDirection.TopLeftToBottomRight; transition.Dimension = PdfTransitionDimension.Vertical; transition.Motion = PdfTransitionMotion.Outward; transition.PageDuration = 3; //Set page transition. doc.PageSettings.Transition = transition; //Create a new page PdfPage page = doc.Pages.Add(); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen 'create a page transition. Dim transition As PdfPageTransition = New PdfPageTransition() transition.Direction = PdfTransitionDirection.TopLeftToBottomRight transition.Dimension = PdfTransitionDimension.Vertical transition.Motion = PdfTransitionMotion.Outward transition.PageDuration = 3 'Set page transition. doc.PageSettings.Transition = transition Dim page As PdfPage = doc.Pages.Add() 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Converts transition motion to string. The motion. Converts transition dimension to string. The dimension. Converts style to string. The style. Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. Gets or sets the transition style to use when moving to this page from another during a presentation. The , handles the various transition styles Gets or sets the duration of the transition effect, in seconds. The transition duration. Gets or sets the dimension in which the specified transition effect occurs. The handles the dimensions . //Create a new document. PdfDocument doc = new PdfDocument(); doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; //create a page transition. PdfPageTransition transition = new PdfPageTransition(); transition.Direction = PdfTransitionDirection.TopLeftToBottomRight; transition.Dimension = PdfTransitionDimension.Vertical; transition.Motion = PdfTransitionMotion.Outward; transition.PageDuration = 3; //Set page transition. doc.PageSettings.Transition = transition; //Create a new page PdfPage page = doc.Pages.Add(); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen 'create a page transition. Dim transition As PdfPageTransition = New PdfPageTransition() transition.Direction = PdfTransitionDirection.TopLeftToBottomRight transition.Dimension = PdfTransitionDimension.Vertical transition.Motion = PdfTransitionMotion.Outward transition.PageDuration = 3 'Set page transition. doc.PageSettings.Transition = transition Dim page As PdfPage = doc.Pages.Add() 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Gets or sets the the direction of motion for the specified transition effect. The handles the various transition motions //Create a new document. PdfDocument doc = new PdfDocument(); doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; //create a page transition. PdfPageTransition transition = new PdfPageTransition(); transition.Direction = PdfTransitionDirection.TopLeftToBottomRight; transition.Dimension = PdfTransitionDimension.Vertical; transition.Motion = PdfTransitionMotion.Outward; transition.PageDuration = 3; //Set page transition. doc.PageSettings.Transition = transition; //Create a new page PdfPage page = doc.Pages.Add(); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen 'create a page transition. Dim transition As PdfPageTransition = New PdfPageTransition() transition.Direction = PdfTransitionDirection.TopLeftToBottomRight transition.Dimension = PdfTransitionDimension.Vertical transition.Motion = PdfTransitionMotion.Outward transition.PageDuration = 3 'Set page transition. doc.PageSettings.Transition = transition Dim page As PdfPage = doc.Pages.Add() 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class The direction in which the specified transition effect moves, expressed in degrees counter clockwise starting from a left-to-right direction. (This differs from the page object�s Rotate property, which is measured clockwise from the top.) The handles the various directions //Create a new document. PdfDocument doc = new PdfDocument(); doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; //create a page transition. PdfPageTransition transition = new PdfPageTransition(); transition.Direction = PdfTransitionDirection.TopLeftToBottomRight; transition.Dimension = PdfTransitionDimension.Vertical; transition.Motion = PdfTransitionMotion.Outward; transition.PageDuration = 3; //Set page transition. doc.PageSettings.Transition = transition; //Create a new page PdfPage page = doc.Pages.Add(); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen 'create a page transition. Dim transition As PdfPageTransition = New PdfPageTransition() transition.Direction = PdfTransitionDirection.TopLeftToBottomRight transition.Dimension = PdfTransitionDimension.Vertical transition.Motion = PdfTransitionMotion.Outward transition.PageDuration = 3 'Set page transition. doc.PageSettings.Transition = transition Dim page As PdfPage = doc.Pages.Add() 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Gets or sets the starting or ending scale at which the changes are drawn. If Motion property specifies an inward transition, the scale of the changes drawn progresses from Scale to 1.0 over the course of the transition. If Motion specifies an outward transition, the scale of the changes drawn progresses from 1.0 to Scale over the course of the transition. This property has effect for Fly transition style only. The scale. Gets or sets The page�s display duration (also called its advance timing): the maximum length of time, in seconds, that the page is displayed during presentations before the viewer application automatically advances to the next page. By default, the viewer does not advance automatically. The page duration. //Create a new document. PdfDocument doc = new PdfDocument(); doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen; //create a page transition. PdfPageTransition transition = new PdfPageTransition(); transition.Direction = PdfTransitionDirection.TopLeftToBottomRight; transition.Dimension = PdfTransitionDimension.Vertical; transition.Motion = PdfTransitionMotion.Outward; transition.PageDuration = 3; //Set page transition. doc.PageSettings.Transition = transition; //Create a new page PdfPage page = doc.Pages.Add(); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Create a new document. Dim doc As PdfDocument = New PdfDocument() doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen 'create a page transition. Dim transition As PdfPageTransition = New PdfPageTransition() transition.Direction = PdfTransitionDirection.TopLeftToBottomRight transition.Dimension = PdfTransitionDimension.Vertical transition.Motion = PdfTransitionMotion.Outward transition.PageDuration = 3 'Set page transition. doc.PageSettings.Transition = transition Dim page As PdfPage = doc.Pages.Add() 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Class Gets the element. Represents a section entity. A section it's a set of the pages with similar page settings. To know more about PdfSection refer this link. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Get the document section collection. PdfSectionCollection sections = document.Sections; //Add the section. PdfSection section = sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Get the document section collection. Dim sections As PdfSectionCollection = document.Sections 'Add the section. Dim section As PdfSection = sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Page settings of the pages in the section. Page template for the section. An instance of the class manipulating with a page label. Indicates if the progress is turned on. Internal variable to store initial page settings. Internal variable to store cached saved settings. Internal variable to store whether transition has been saved already. A virtual collection of pages. Initializes a new instance of the class. Initializes a new instance of the class. The page settings. Creates a new instance of PDfSection class. Parent document for the section. Creates a page and adds it to the collection. Created page. Adds the specified page. The page. Inserts a page at the specified index. The index of the page in the section. The page. Inserts a page at the specified index. The index of the page in the section. The page to be inserted. Get the index of the page. The page. The index of the page. Determines whether the page in within the section. The page. true if the specified page is within the section; otherwise, false. Removes the page from the section. The page that should be removed from the section. Removes the page by its index in the section. Zero-based index of the page in the section. Removes all the pages from the section. If the document contains one section only, this section should contain at least one page. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Checks whether any template should be printed on this layer. Parent document. The parent page. Layer z-order. True - if some content should be printed on the layer, False otherwise. draws page templates on the page. The page. Page layer where the templates should be drawn. Parent document. Foreground layer if True, False otherwise. Calculates actual bounds of the page. Page where the bounds should be calculated. If true - take into consideration Margins. Actual bounds of the page. Calculates actual bounds of the page. Parent document. Page where the bounds should be calculated. If true - take into consideration Margins. Actual bounds of the page. Calculates width of the left indent. Parent document. Page where the bounds should be calculated. If true - take into consideration Margins. Width of the left indent. Calculates Height of the top indent. Parent document. Page where the bounds should be calculated. If true - take into consideration Margins. Height of the top indent. Calculates width of the right indent. Parent document. Page where the bounds should be calculated. If true - take into consideration Margins. Width of the right indent. Calculates Height of the bottom indent. Parent document. Page where the bounds should be calculated. If true - take into consideration Margins. Height of the top indent. Translates point into native coordinates of the page. The parent page. Point to translate. Point in native page coordinates. Draws an array of the templates. Parent layer. PArent document. Array of templates. Returns array of the document templates. Parent document. the parent page. If true - return headers/footers, if false - return simple templates. If true - return foreground templates, if false - return background templates. Returns array of the document templates. Returns array of the section templates. The parent page. If true - return headers/footers, if false - return simple templates. If true - return foreground templates, if false - return background templates. Returns array of the document templates. Called when the page has been added Event arguments. Sets the progress. Resets the progress. Called when a page is being saved. The page. Checks the presence. The page. Infills dictionary by the data from Page settings. Pdf container of the data. Parent page settings. Initializes the object. Gets the transition settings. Transition settings of the section. Resets crop box to the default one. Call two event's methods Added page Catches the Save event of the dictionary. Sender of the event. Event arguments. End save event handler. The sender. The instance containing the event data. Gets the collection of pages in a section (Read only). //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section PdfSection section = document.Sections.Add(); //Get the page collection from a section. PdfSectionPageCollection pageCollection = document.Sections[0].Pages; //Add the page PdfPage page = pageCollection.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Get the page collection from a section. Dim pageCollection As PdfSectionPageCollection = document.Sections(0).Pages 'Add the page. Dim page As PdfPage = pageCollection.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Gets or sets the of the section. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create the page label. PdfPageLabel label = new PdfPageLabel(); label.NumberStyle = PdfNumberStyle.LowerRoman; label.StartNumber = 2; section.PageLabel = label; //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create the page label. Dim label As New PdfPageLabel() label.NumberStyle = PdfNumberStyle.LowerRoman label.StartNumber = 2 section.PageLabel = label 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Gets or sets the of the section. To know more about refer this link . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Add another section. PdfSection section1 = document.Sections.Add(); //Add the pages to section1. PdfPage page1 = section1.Pages.Add(); //Set the page settings. section.PageSettings.Orientation = PdfPageOrientation.Landscape; //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add another section. Dim section1 As PdfSection = document.Sections.Add() 'Add the pages to section1. Dim page1 As PdfPage = section1.Pages.Add() 'Set the page settings. section.PageSettings.Orientation = PdfPageOrientation.Landscape 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Gets or sets the for the pages in the section. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentTopTemplate = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentTopTemplate = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Class Gets the at the specified index. Gets the count of the pages in the section. Gets or sets the parent. The parent. Gets the resources. The resources. Gets the document. The document. Gets the parent document. Event rises when the new page has been added //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Set page size. document.PageSettings = new PdfPageSettings(new SizeF(300, 400)); //Add the event. section.PageAdded += new PageAddedEventHandler(sec_PageAdded); //Add new page to section. section.Pages.Add(); //Add new page document. document.Pages.Add(); //Save and close the document. document.Save("PageCreatedTest.pdf"); document.Close(true); //Event handler for PageAdded event void sec_PageAdded(object sender, PageAddedEventArgs args) { PdfPage page = args.Page; PdfSection section = (sender as PdfSection); //Get page graphics. PdfGraphics graphics = page.Graphics; //Create new font instance. PdfStandardFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 14f); //Create new brush instance. PdfSolidBrush brush = new PdfSolidBrush(Color.Blue); string text = String.Format("Page number : {0} added to Section", section.Pages.Count); //Draw the text. graphics.DrawString(text, font, brush, PointF.Empty); } 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Set page size. document.PageSettings = New PdfPageSettings(New SizeF(300, 400)) 'Add the event. section.PageAdded += New PageAddedEventHandler(sec_PageAdded) 'Add new page to section. section.Pages.Add() 'Add new page document. document.Pages.Add() 'Save and close the document. document.Save("PageCreatedTest.pdf") document.Close(True) 'Event handler for PageAdded event Private Sub sec_PageAdded(sender As Object, args As PageAddedEventArgs) Dim page As PdfPage = args.Page Dim section As PdfSection = (TryCast(sender, PdfSection)) Dim graphics As PdfGraphics = page.Graphics Dim font As PdfStandardFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 14.0F) Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Blue) Dim text As String = String.Format("Page number : {0} added to Section", section.Pages.Count) graphics.DrawString(text, font, brush, PointF.Empty) End Sub Class Class Class Class Class Gets the wrapped element. Initializes a new instance of the class. The section. Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Checks the index. Gets the current. Represents the collection of the . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Get the document section collection. PdfSectionCollection sections = document.Sections; //Add the section. PdfSection section = sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Get the document section collection. Dim sections As PdfSectionCollection = document.Sections 'Add the section. Dim section As PdfSection = sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Class Class Rotate factor for page rotation. Initializes a new instance of the class. Creates a new and adds it to the collection. Created section object. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Add another section. PdfSection section1 = document.Sections.Add(); //Add the pages to section1. PdfPage page1 = section1.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add another section. Dim section1 As PdfSection = document.Sections.Add() 'Add the pages to section1. Dim page1 As PdfPage = section1.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Determines the index of the specified . The section which is to be found the index. The index of the specified section. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Add another section. PdfSection section1 = document.Sections.Add(); //Add pages to the section1. PdfPage page1 = section1.Pages.Add(); //Get the index of the specified section. int index = document.Sections.IndexOf(section); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add another section. Dim section1 As PdfSection = document.Sections.Add() 'Add pages to the section1. Dim page1 As PdfPage = section1.Pages.Add() 'Get the index of the specified section. Dim index As Integer = document.Sections.IndexOf(section) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Inserts the at the specified index. The index of the section to be added. The section to be added. Index value should start from zero. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Add the section. PdfSection section1 = document.Sections.Add(); //Add pages to the section1. PdfPage page1 = section1.Pages.Add(); //insert the section at specified index. document.Sections.Insert(0, section1); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add the section. Dim section1 As PdfSection = document.Sections.Add() 'Add pages to the section1. Dim page1 As PdfPage = section1.Pages.Add() 'insert the section at specified index. document.Sections.Insert(0, section1) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Checks whether the collection contains the specified section. The True - if the sections belongs to the collection, False otherwise. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section PdfSection section = document.Sections.Add(); //Add pages to the section PdfPage page = section.Pages.Add(); //Add the section PdfSection section1 = document.Sections.Add(); //Add pages to the section1 PdfPage page1 = section1.Pages.Add(); //Check whether the specified section is in the collection bool isExists = document.Sections.Contains(section1); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section Dim section As PdfSection = document.Sections.Add() 'Add pages to the section Dim page As PdfPage = section.Pages.Add() 'Add the section Dim section1 As PdfSection = document.Sections.Add() 'Add pages to the section1 Dim page1 As PdfPage = section1.Pages.Add() 'Check whether the specified section is in the collection Dim isExists As Boolean = document.Sections.Contains(section1) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Informs the section collection that the page labels were set. Resets the progress. Sets the progress. Called when a page is saving. The page. Infills dictionary by the data from Page settings. Pdf container of the data. Page settings. Checks if the section is within the collection. The section. The reference holder of the section. Throws ArgumentException if the section is within the collection. Counts the pages. Adds the specified section. The section. Index of the section in the collection. Adds the specified section. The section. Initializes the object. Clears section collection of the document. Catches the Save event of the dictionary. Sender of the event. Event arguments. Gets the at the specified index.Read only. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section1. PdfPage page = section.Pages.Add(); //Get the section from collection. PdfSection section2 = document.Sections[0]; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section1. Dim page As PdfPage = section.Pages.Add() 'Get the section from collection. Dim section2 As PdfSection = document.Sections(0) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets the total number of in a document.Read only. The count of the sections. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Add another section. PdfSection section1 = document.Sections.Add(); //Add pages to the section1. PdfPage page1 = section1.Pages.Add(); //Get the sections count. int count = document.Sections.Count; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add another section. Dim section1 As PdfSection = document.Sections.Add() 'Add pages to the section1. Dim page1 As PdfPage = section1.Pages.Add() 'Get the sections count. Dim count As Integer = document.Sections.Count 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets a parent document. Gets the wrapped element. Section collection enumerator. Initializes a new instance of the class. The section collection. Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Checks the index. Gets the current section. Represents the collection of pages in a . //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Get the page collection from a section. PdfSectionPageCollection pageCollection = document.Sections[0].Pages; //Add the page. PdfPage page = pageCollection.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Get the page collection from a section. Dim pageCollection As PdfSectionPageCollection = document.Sections(0).Pages 'Add the page. Dim page As PdfPage = pageCollection.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Initializes a new instance of the class. Initializes a new instance of the class. The section. Creates a new page and adds it into the collection. The new page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Add the section. PdfSection section1 = document.Sections.Add(); //Add pages to the section1. PdfPage page1 = section1.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add the section. Dim section1 As PdfSection = document.Sections.Add() 'Add pages to the section1. Dim page1 As PdfPage = section1.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Adds a page into collection. The page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Create a new pdf page. PdfPage page = new PdfPage(); //Add the page into section. document.Sections[0].Pages.Add(page); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Create a new pdf page. Dim page As New PdfPage() 'Add the page into section. document.Sections(0).Pages.Add(page) 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Inserts a page at the specified index. The index of the page to be added. The page to be added. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a page. PdfPage page1 = new PdfPage(); //Insert a page at specified index. document.Sections[0].Pages.Insert(0, page); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a page. Dim page1 As New PdfPage() 'Insert a page at specified index. document.Sections(0).Pages.Insert(0, page) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Returns the index of the specified page. The Index of the page if the collection contains the specified page; otherwise, -1. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a page. PdfPage page1 = new PdfPage(); //Get index of the page from Pdf section page collections. int index = document.Sections[0].Pages.IndexOf(page); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a page. Dim page1 As PdfPage = New PdfPage() 'Get index of the page from Pdf section page collections. Dim index As Integer = document.Sections(0).Pages.IndexOf(page) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Determines whether the specified page is within the collection. The true if the collection contains the specified page; otherwise, false. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add page to the section. PdfPage page = section.Pages.Add(); //Add the section. PdfSection section1 = document.Sections.Add(); //Add page to the section1. PdfPage page1 = section1.Pages.Add(); //check whether the specified page is in collection. bool isExists = document.Sections[0].Pages.Contains(page1); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add page to the section. Dim page As PdfPage = section.Pages.Add() 'Add the section. Dim section1 As PdfSection = document.Sections.Add() 'Add page to the section1. Dim page1 As PdfPage = section1.Pages.Add() 'check whether the specified page is in collection. Dim isExists As Boolean = document.Sections(0).Pages.Contains(page1) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Removes the specified page from collection. The page. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a page. PdfPage page1 = section.Pages.Add(); //Remove the page from Pdf section page collections. document.Sections[0].Pages.Remove(page); //Get page count, it will be one int count = document.Sections[0].Pages.Count; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a page. Dim page1 As PdfPage = section.Pages.Add() 'Remove the page from Pdf section page collections. document.Sections(0).Pages.Remove(page) 'Get page count, it will be one Dim count As Integer = document.Sections(0).Pages.Count 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Removes a page at the specified index. The index of the page to be removed. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section PdfPage page = section.Pages.Add(); //Add the section. PdfSection section1 = document.Sections.Add(); //Add pages to the section1. PdfPage page1 = section1.Pages.Add(); //Remove the page at specified index. document.Sections[0].Pages.RemoveAt(0); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add the section. Dim section1 As PdfSection = document.Sections.Add() 'Add pages to the section1. Dim page1 As PdfPage = section1.Pages.Add() 'Remove the page at specified index. document.Sections(0).Pages.RemoveAt(0) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Clears this collection. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add first page to the section. PdfPage page = section.Pages.Add(); //Add second page to the section. PdfPage page1 = section.Pages.Add(); //Clear all the pages from first section of pdf document. document.Sections[0].Pages.Clear(); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add first page to the section. Dim page As PdfPage = section.Pages.Add() 'Add second page to the section. Dim page1 As PdfPage = section.Pages.Add() 'Clear all the pages from first section of pdf document. document.Sections(0).Pages.Clear() 'Save and close the document. document.Save("Output.pdf") document.Close(True) Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Gets the at the specified index. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Get the page collection from a section. PdfSectionPageCollection pageCollection = document.Sections[0].Pages; //Add the page. PdfPage page = pageCollection.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Set the font. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Get the page collection from a section. Dim pageCollection As PdfSectionPageCollection = document.Sections(0).Pages 'Add the page. Dim page As PdfPage = pageCollection.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Set the font. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Gets the count of the pages. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Add the section. PdfSection section1 = document.Sections.Add(); //Add pages to the section1. PdfPage page1 = section1.Pages.Add(); //Get the page count in a section. int count = document.Sections[0].Pages.Count; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Add the section. Dim section1 As PdfSection = document.Sections.Add() 'Add pages to the section1. Dim page1 As PdfPage = section1.Pages.Add() 'Get the page count in a section. Dim count As Integer = document.Sections(0).Pages.Count 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Represents a page template for all the pages in the section. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentTopTemplate = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentTopTemplate = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Left settings. Top settings. Right settings. Bottom settings. Other templates settings Creates a new object. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentTopTemplate = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentTopTemplate = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets or sets value indicating whether parent Left page template should be used or not. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentLeftTemplate = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentLeftTemplate = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets or sets value indicating whether parent Top page template should be used or not. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentTopTemplate = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentTopTemplate = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets or sets value indicating whether parent Right page template should be used or not. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentRightTemplate = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentRightTemplate = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets or sets value indicating whether parent Bottom page template should be used or not. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentBottomTemplate = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentBottomTemplate = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Gets or sets value indicating whether the parent stamp elements should be used or not. /// //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add the section. PdfSection section = document.Sections.Add(); //Add pages to the section. PdfPage page = section.Pages.Add(); //Create a header and draw the image. RectangleF bounds = new RectangleF(0, 0, document.Pages[0].GetClientSize().Width, 50); PdfSectionTemplate template = new PdfSectionTemplate(); template.ApplyDocumentStamps = true; //Create a page template. PdfPageTemplateElement header = new PdfPageTemplateElement(bounds); PdfImage image = new PdfBitmap(@"Input.jpg"); //Draw the image in the header. header.Graphics.DrawImage(image, bounds); template.Top = header; //Add the header at the top of the section section.Template = template; //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add the section. Dim section As PdfSection = document.Sections.Add() 'Add pages to the section. Dim page As PdfPage = section.Pages.Add() 'Create a header and draw the image. Dim bounds As New RectangleF(0, 0, document.Pages(0).GetClientSize().Width, 50) Dim template As New PdfSectionTemplate() template.ApplyDocumentStamps = True 'Create a page template. Dim header As New PdfPageTemplateElement(bounds) Dim image As PdfImage = New PdfBitmap("Input.jpg") 'Draw the image in the header. header.Graphics.DrawImage(image, bounds) template.Top = header 'Add the header at the top of the section. section.Template = template 'Save the document. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class A collection of stamps that are applied to the page templates. It is used only on PdfPageTemplateElement. Creates a new instance of the class. Adds a stamp element to the collection. The used here to create stamp element. The index of the stamp element. Creates a stamp element and adds it to the collection. X co-ordinate of the stamp. Y co-ordinate of the stamp. Width of the stamp. Height of the stamp. The created stamp element. Checks whether the stamp element exists in the collection. The used here to create stamp element. True - if stamp element exists in the collection, False otherwise. Inserts a stamp element to the collection at the specified position. The index of the stamp in the collection. The . Removes the stamp element from the collection. The . Removes a stamp element from the specified position in the collection. The index of the stamp in the collection. Clears the collection. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Gets a stamp element by its index. The describes a page template object PdfPageTemplate enumerator. Stamps collection Current index of the enumerator. Initializes a new instance of the class. The stanps collection. Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Checks the index. Gets the current section. Enumerator that represents the PDF page orientations. Default value is Portrait. To know more about document settings refer this link. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Set the page size. document.PageSettings.Size = PdfPageSize.A4; //Change the page orientation to landscape. document.PageSettings.Orientation = PdfPageOrientation.Landscape; //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create the PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Set the page size.' document.PageSettings.Size = PdfPageSize.A4 'Change the page orientation to landscape. document.PageSettings.Orientation = PdfPageOrientation.Landscape 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create the PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save document to disk. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Class Portrait orientation. Landscape orientation. The number of degrees by which the page should be rotated clockwise when displayed or printed. To know more details about document settings refer this link. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Set rotation angle. document.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle90; //Add a page to the document. PdfPage page = document.Pages.Add(); //Create PDF graphics for the page. PdfGraphics graphics = page.Graphics; //Create the PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 20); //Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, new PointF(0, 0)); //Save the document to disk. document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Set rotation angle. document.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle90 'Add a page to the document. Dim page As PdfPage = document.Pages.Add() 'Create PDF graphics for the page. Dim graphics As PdfGraphics = page.Graphics 'Create the PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 20) 'Draw the text. graphics.DrawString("Hello World!!!", font, PdfBrushes.Black, New PointF(0, 0)) 'Save the document to disk. document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class The page is rotated as 0 angle. The page is rotated as 90 angle. The page is rotated as 180 angle. The page is rotated as 270 angle. Specifies numbering style of page labels. //Create new document. PdfDocument document = new PdfDocument(); //Create new true type font. PdfTrueTypeFont font = new PdfTrueTypeFont(new Font("Times New Roman", 12f)); //Create new solid brush. PdfSolidBrush brush = new PdfSolidBrush(Color.Green); //Create new section. PdfSection sec = document.Sections.Add(); //Declare new page. PdfPage page; //Creates page number field. PdfDestinationPageNumberField dest = new PdfDestinationPageNumberField(); //Add pages to the section. page = sec.Pages.Add(); //Set page for pagenumber field. dest.Page = page; //Set Number style. dest.NumberStyle = PdfNumberStyle.LowerRoman; //Set font for pagenumber field. dest.Font = font; //Set brush for pagenumber field. dest.Brush = brush; //Set size for the page number field. dest.Size = new SizeF(50, 20); //Draws the page number on page. dest.Draw(page.Graphics); //Save the document. document.Save("NumberStyle.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Create new true type font. Dim font As PdfTrueTypeFont = New PdfTrueTypeFont(New Font("Times New Roman", 12.0F)) 'Create new solid brush. Dim brush As PdfSolidBrush = New PdfSolidBrush(Color.Green) 'Create new section. Dim sec As PdfSection = document.Sections.Add() 'Declare new page. Dim page As PdfPage 'Creates page number field. Dim dest As PdfDestinationPageNumberField = New PdfDestinationPageNumberField() 'Add pages to the section. page = sec.Pages.Add() 'Set page for pagenumber field. dest.Page = page 'Set Number style. dest.NumberStyle = PdfNumberStyle.LowerRoman 'Set font for pagenumber field. dest.Font = font 'Set brush for pagenumber field. dest.Brush = brush 'Set size for the page number field. dest.Size = New SizeF(50, 20) 'Draws the page number on page. dest.Draw(page.Graphics) 'Save document to disk. document.Save("NumberStyle.pdf") 'Close the document. document.Close(True) Class Class Class Class Class Class No numbering at all. Decimal arabic numerals. Lowercase letters a-z. Lowercase roman numerals. Uppercase letters A-Z. Uppercase roman numerals. Specifies the docking style of the page template. This enumeration is used in class. To know more details about refer this link. //Create a PDF document PdfDocument doc = new PdfDocument(); //Create a page PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height); //Create a page template PdfPageTemplateElement footer = new PdfPageTemplateElement(rect); //set the dock style footer.Dock = PdfDockStyle.Right; //Set the template alignment as top right footer.Alignment = PdfAlignmentStyle.TopRight; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); PdfSolidBrush brush = new PdfSolidBrush(Color.Gray); //Create page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font, brush); //Create page count field PdfPageCountField count = new PdfPageCountField(font, brush); PdfCompositeField compositeField = new PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count); compositeField.Bounds = footer.Bounds; compositeField.Draw(footer.Graphics, new PointF(40, footer.Height - 50)); //Add the footer template at the bottom doc.Template.Right = footer; //Save the document doc.Save("Template.pdf"); //Close the document doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height) 'Create a page template Dim footer As New PdfPageTemplateElement(rect) 'set the dock style footer.Dock = PdfDockStyle.Right 'Set the template alignment as top right footer.Alignment = PdfAlignmentStyle.TopRight Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) Dim brush As New PdfSolidBrush(Color.Gray) 'Create page number field Dim pageNumber As New PdfPageNumberField(font, brush) 'Create page count field Dim count As New PdfPageCountField(font, brush) Dim compositeField As New PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count) compositeField.Bounds = footer.Bounds compositeField.Draw(footer.Graphics, New PointF(40, footer.Height - 50)) 'Add the footer template at the bottom doc.Template.Right = footer 'Save the document doc.Save("Template.pdf") 'Close the document doc.Close(True) Class Class Class Class Class Class Class Class The page template is not docked. The page template edge is docked to the bottom page's side. The page template edge is docked to the top page's side. The page template edge is docked to the left page's side. The page template edge is docked to the right page's side. The page template stretch on full page. Specifies how the page template is aligned relative to the template area. //Create a PDF document PdfDocument doc = new PdfDocument(); //Create a page PdfPage page = doc.Pages.Add(); RectangleF rect = new RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height); //Create a page template PdfPageTemplateElement footer = new PdfPageTemplateElement(rect); //set the dock style footer.Dock = PdfDockStyle.Right; //Set the template alignment as top right footer.Alignment = PdfAlignmentStyle.TopRight; PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); PdfSolidBrush brush = new PdfSolidBrush(Color.Gray); //Create page number field PdfPageNumberField pageNumber = new PdfPageNumberField(font, brush); //Create page count field PdfPageCountField count = new PdfPageCountField(font, brush); PdfCompositeField compositeField = new PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count); compositeField.Bounds = footer.Bounds; compositeField.Draw(footer.Graphics, new PointF(40, footer.Height - 50)); //Add the footer template at the bottom doc.Template.Right = footer; doc.Save("Template.pdf"); doc.Close(true); 'Create a PDF document Dim doc As New PdfDocument() 'Create a page Dim page As PdfPage = doc.Pages.Add() Dim rect As New RectangleF(0, 0, page.GetClientSize().Width, page.GetClientSize().Height) 'Create a page template Dim footer As New PdfPageTemplateElement(rect) 'set the dock style footer.Dock = PdfDockStyle.Right 'Set the template alignment as top right footer.Alignment = PdfAlignmentStyle.TopRight Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) Dim brush As New PdfSolidBrush(Color.Gray) 'Create page number field Dim pageNumber As New PdfPageNumberField(font, brush) 'Create page count field Dim count As New PdfPageCountField(font, brush) Dim compositeField As New PdfCompositeField(font, brush, "Page {0} of {1}", pageNumber, count) compositeField.Bounds = footer.Bounds compositeField.Draw(footer.Graphics, New PointF(40, footer.Height - 50)) 'Add the footer template at the bottom doc.Template.Right = footer doc.Save("Template.pdf") doc.Close(True) This enumeration is used in class. Class Class Class Class Class Class Class Class Specifies no alignment. The template is top left aligned. The template is top center aligned. The template is top right aligned. The template is middle left aligned. The template is middle center aligned. The template is middle right aligned. The template is bottom left aligned. The template is bottom center aligned. The template is bottom right aligned. A name object specifying the page layout to be used when the document is opened. //Source document. PdfLoadedDocument lDoc = new PdfLoadedDocument("input.pdf"); //Create a new document. PdfDocument document = new PdfDocument(); //Appending the document with source document. document.Append(lDoc); //Set page layout. document.ViewerPreferences.PageLayout = PdfPageLayout.TwoColumnRight; //Save the document. document.Save("Output.pdf"); //Close the documents. document.Close(true); lDoc.Close(true); 'Source document. Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Appending the document with source document. document.Append(lDoc) 'Set page layout. document.ViewerPreferences.PageLayout = PdfPageLayout.TwoColumnRight 'Save the document. document.Save("Output.pdf") 'Close the documents. document.Close(True) lDoc.Close(True) Class Class Class Class Default Value. Display one page at a time. Display the pages in one column. Display the pages in two columns, with odd numbered pages on the left. Display the pages in two columns, with odd numbered pages on the right. Display the pages two at a time, with odd-numbered pages on the left Display the pages two at a time, with odd-numbered pages on the right The paper handling option to use when printing the file from the print dialog. //Source document. PdfLoadedDocument lDoc = new PdfLoadedDocument("input.pdf"); //Create a new document. PdfDocument document = new PdfDocument(); //Appending the document with source document. document.Append(lDoc); //Set page layout. document.ViewerPreferences.Duplex = DuplexMode.DuplexFlipShortEdge; //Save the document. document.Save("Output.pdf"); //Close the documents. document.Close(true); lDoc.Close(true); 'Source document. Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Appending the document with source document. document.Append(lDoc) 'Set page layout. document.ViewerPreferences.Duplex = DuplexMode.DuplexFlipShortEdge 'Save the document. document.Save("Output.pdf") 'Close the documents. document.Close(True) lDoc.Close(True) Class Class Class Class Print single-sided. Duplex and flip on the short edge of the sheet. Duplex and flip on the long edge of the sheet. Default Value Represents mode of document displaying. //Create a new document. PdfDocument document = new PdfDocument(); //Set page mode. document.ViewerPreferences.PageMode = PdfPageMode.UseOC; //Add a page in the PDF document. PdfPage page = document.Pages.Add(); //Create the PDF font instance. PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 12f, PdfFontStyle.Bold); //Draw the text in PDF page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, new PointF(10, 10)); //Save the document. document.Save("Output.pdf"); //Close the documents. document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set page mode. document.ViewerPreferences.PageMode = PdfPageMode.UseOC 'Add a page in the PDF document. Dim page As PdfPage = document.Pages.Add() 'Create the PDF font instance. Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 12.0F, PdfFontStyle.Bold) 'Draw the text in PDF page. page.Graphics.DrawString("Essential PDF", font, PdfBrushes.Black, New PointF(10, 10)) 'Save the document. document.Save("Output.pdf") 'Close the documents. document.Close(True) Class Class Class Class Default value. Neither document outline nor thumbnail images visible. Document outline visible. Thumbnail images visible. Full-screen mode, with no menu bar, window controls, or any other window visible. Optional content group panel visible. Attachments are visible. TemplateArea can be header/footer on of the following types. Page template is not used as header. Page template is used as Top. Page template is used as Bottom. Page template is used as Left. Page template is used as Right. Two lines sweep across the screen, revealing the new page. The lines may be either horizontal or vertical and may move inward from the edges of the page or outward from the center. Multiple lines, evenly spaced across the screen, synchronously sweep in the same direction to reveal the new page. The lines may be either horizontal or vertical. Horizontal lines move downward; vertical lines move to the right. A rectangular box sweeps inward from the edges of the page or outward from the center, revealing the new page. A single line sweeps across the screen from one edge to the other, revealing the new page. The old page dissolves gradually to reveal the new one. Similar to Dissolve, except that the effect sweeps across the page in a wide band moving from one side of the screen to the other. The new page simply replaces the old one with no special transition effect. Changes are flown out or in, to or from a location that is offscreen. The old page slides off the screen while the new page slides in, pushing the old page out. The new page slides on to the screen, covering the old page. The old page slides off the screen, uncovering the new page. The new page gradually becomes visible through the old one. Enumeration of transition dimensions. Horizontal effect. Vertical effect. Enumeration of transition motions. Inward motion from the edges of the page to center.. Outward motion from the center of the page to edges. Enumeration of transition directions. Left to Right direction. Bottom to Top direction. Right to Left direction. Top to Bottom direction. TopLeft to BottomRight direction. Used to represent the print state of . The visble PDF page layers get print The PDF page layer never get print The PDF pageLayers always get print Specifies tab order types for form fields Default value is None. //Create a new document. PdfDocument document = new PdfDocument(); //Create a new page. PdfPage page = document.Pages.Add(); //Set form fields tab order. page.FormFieldsTabOrder = PdfFormFieldsTabOrder.Manual; //Create new text box field. PdfTextBoxField field = new PdfTextBoxField(page, "Hello"); //Set field tab index as 3. field.TabIndex = 3; //Set field bounds. field.Bounds = new RectangleF(0, 0, 100, 30); //Create new text box field. PdfTextBoxField field1 = new PdfTextBoxField(page, "Hello1"); //Set field tab index as 2. field.TabIndex = 2; //Set field bounds. field1.Bounds = new RectangleF(200, 0, 100, 30); //Create new text box field. PdfTextBoxField field2 = new PdfTextBoxField(page, "Hello2"); //Set field tab index as 1. field.TabIndex = 1; //Set field bounds. field2.Bounds = new RectangleF(0, 50, 100, 30); //Create new text box field. PdfTextBoxField field3 = new PdfTextBoxField(page, "Hello3"); //Set field tab index as 0. field.TabIndex = 0; //Set field bounds. field3.Bounds = new RectangleF(200, 50, 100, 30); //Adds the form field to the document. document.Form.Fields.Add(field); document.Form.Fields.Add(field1); document.Form.Fields.Add(field2); document.Form.Fields.Add(field3); //Save the pdf document. document.Save("TabOrder.pdf"); //Close the document. document.Close(true); 'Create a new PDF document. Dim document As PdfDocument = New PdfDocument() 'Creates a new page. Dim page As PdfPage = document.Pages.Add() 'Set form fields tab order. page.FormFieldsTabOrder = PdfFormFieldsTabOrder.Manual 'Create new text box field. Dim field As PdfTextBoxField = New PdfTextBoxField(page, "Hello") 'Set field tab index as 3. field.TabIndex = 3 'Set field bounds. field.Bounds = New RectangleF(0, 0, 100, 30) 'Create new text box field. Dim field1 As PdfTextBoxField = New PdfTextBoxField(page, "Hello1") 'Set field tab index as 2. field.TabIndex = 2 'Set field bounds. field1.Bounds = New RectangleF(200, 0, 100, 30) 'Create new text box field. Dim field2 As PdfTextBoxField = New PdfTextBoxField(page, "Hello2") 'Set field tab index as 1. field.TabIndex = 1 'Set field bounds. field2.Bounds = New RectangleF(0, 50, 100, 30) 'Create new text box field. Dim field3 As PdfTextBoxField = New PdfTextBoxField(page, "Hello3") 'Set field tab index as 0. field.TabIndex = 0 'Set field bounds. field3.Bounds = New RectangleF(200, 50, 100, 30) 'Adds the form field to the document. document.Form.Fields.Add(field) document.Form.Fields.Add(field1) document.Form.Fields.Add(field2) document.Form.Fields.Add(field3) 'Save document to disk. document.Save("TabOrder.pdf") 'Close the document. document.Close(True) Class Class Namespace Form fields are visited default order Form fields are visited rows running horizontally across the page Form fields are visited column running vertically up and down the page Form fields are visited based on the structure tree Form fields are visited manual order The class provides methods and properties to handle the collection of . //Load an existing PDF document. PdfLoadedDocument document = new PdfLoadedDocument(@"Annotations.pdf"); //Get the annotation collection. PdfLoadedAnnotationCollection annotationCollection=document.Pages[0].Annotations; //Get the sound annotation. PdfLoadedSoundAnnotation soundAnnotation = annotationCollection[5] as PdfLoadedSoundAnnotation; //Set the sound annotation border. soundAnnotation.Border.Width = 4; soundAnnotation.Border.HorizontalRadius = 20; soundAnnotation.Border.VerticalRadius = 30; //Set the PDF sound. PdfSound sound = new PdfSound("Startup.wav"); soundAnnotation.Sound=sound; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing PDF document. Dim document As New PdfLoadedDocument("Annotations.pdf") 'Gets the annotation collection. Dim annotationCollection As PdfLoadedAnnotationCollection = document.Pages(0).Annotations 'Get the PDF sound annotation. Dim soundAnnotation As PdfLoadedSoundAnnotation = dannotationCollection(5) 'Set the sound annotation border. soundAnnotation.Border.Width = 4 soundAnnotation.Border.HorizontalRadius = 20 soundAnnotation.Border.VerticalRadius = 30 'Set the PDF sound. Dim sound As PdfSound = New PdfSound("Startup.wav") soundAnnotation.Sound=sound 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Loaded page, wich collection belongs to. Indicates annotation is flatten or not. Initializes a new instance of the class. The page. NameChanged evant handler. New Name of the annotation. Adds annotation to the collection. Annotation to be added to collection. Position of the annotation in collection. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"Annotations.pdf"); //Get the annotation collection PdfLoadedAnnotationCollection annotationCollection = document.Pages[0].Annotations; //Create a new rectangle RectangleF rectangle = new RectangleF(10, 40, 30, 30); //Create a new Uri Annotation. PdfUriAnnotation uriAnnotation = new PdfUriAnnotation(rectangle, "http://www.google.com"); //Set Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation"; annotationCollection.Add(uriAnnotation); //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("Annotations.pdf") 'Get the annotation collection Dim annotationCollection As PdfLoadedAnnotationCollection = document.Pages(0).Annotations 'Create a new rectangle Dim rectangle As RectangleF = New RectangleF(10, 40, 30, 30) 'Create a new Uri Annotation. Dim uriAnnotation As PdfUriAnnotation = New PdfUriAnnotation(rectangle, "http://www.google.com") 'Set the Text to uriAnnotation. uriAnnotation.Text = "Uri Annotation" annotationCollection.Add(uriAnnotation) 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) To update comment state on PdfArray from annotation To update review state from PdfAnnotaion into PdfArray To udapte the Annoation review state and comments on PdfArray Adds a annotation to collection. The annotation. Gets the new name of the annotation. The name. The annotation name. Check whether the annotation with the same name already exists. The name. true if there are no annotation with the same name within the collection; otherwise false. Gets the index of the annotation. The name. The index of the annotation. Gets the annotation. The index. The created annotation. Gets the type of the annotation. The name. The dictionary. The cross table. The annotation type. Create file remotegoto link annotation The created file remotegoto link annotation Creates the text web link annotation. The dictionary. The cross table. The created file link annotation. Creates the file link annotation. The dictionary. The cross table. The created file link annotation. Creates the document link annotation. The dictionary. The cross table. The created widget annotation. Creates the widget annotation. The created the widget annotation. Creates the Ink annotation. Created the Ink annotation. Creates the watermark annotation. The dictionary. The cross table. The created watermark annotation. Creates the Trap Network Annotation. The dictionary. The cross table. The created Trap Network Annotation. Creates the Text Markup Annotation. The dictionary. The cross table. The created Text Markup Annotation. Creates the Text Annotation. The dictionary. The cross table. The created Text Annotation. Creates the Square and Circle Annotation. The dictionary. The cross table. The created Square and Circle Annotation. Creates the Sound Annotation. The dictionary. The cross table. The RectangleF. The Filename. The created Sound Annotation. Creates the Screen Annotation. The dictionary. The cross table. The created Screen Annotation. Creates the Rubber Stamp Annotation. The dictionary. The cross table. The created Rubber Stamp Annotation. Creates the Printer Mark Annotation. The dictionary. The cross table. The created Printer Mark Annotation. Creates the Popup Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Popup Annotation. Creates the Polygon and Polyline Annotation. The dictionary. The cross table. The created Polygon and Polyline Annotation. Creates the Movie Annotation. The dictionary. The cross table. The created Movie Annotation. Creates the Markup Annotation. The dictionary. The cross table. The RectangleF. The created Markup Annotation. Creates the Lnk Annotation. The dictionary. The cross table. The RectangleF. The Filename. The created Lnk Annotation. Creates the Link Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Link Annotation. Creates the Line Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Line Annotation. Creates the Circle Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Circle Annotation. Creates the Ellipse Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Ellipse Annotation. Creates the Square Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Square Annotation. Creates the Rectangle Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Rectangle Annotation. Creates the Polygon Annotation. The dictionary. The cross table. The RectangleF. The Text. The created Polygon Annotation. Creates the PolyLine Annotation. The dictionary. The cross table. The RectangleF. The Text. The created PolyLine Annotation. Creates the Free Text Annotation. The dictionary. The cross table. The created Free Text Annotation. Creates the Redaction Annotation. The dictionary. The cross table. The created Redaction Annotation. Creates the File Attachment Annotation. The dictionary. The cross table. The RectangleF. The Filename. The created File Attachment Annotation. Creates the Caret Annotation. The dictionary. The cross table. The created Caret Annotation. Creates the Annotation States. The dictionary. The cross table. The created Annotation States. Inserts a annotation into collection. The index. The annotation. Clears the collection. Removes the annotation at the specified position. The index. Removes the annotation from collection. The annotation. Find the annotation from collection. The annotation. Gets the at the specified index. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"Annotations.pdf"); //Get the annotation collection. PdfLoadedAnnotationCollection annotationCollection=document.Pages[0].Annotations; //Get the PDF sound annotation. PdfLoadedSoundAnnotation soundAnnotation = annotationCollection[5] as PdfLoadedSoundAnnotation; //Set the sound annotation border soundAnnotation.Border.Width = 4; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("Annotations.pdf") 'Get the annotation from loaded document. Dim annotationCollection As PdfLoadedAnnotationCollection = document.Pages(0).Annotations 'Get the PDF sound annotation. Dim soundAnnotation As PdfLoadedSoundAnnotation = dannotationCollection(5) 'Set the sound annotation border. soundAnnotation.Border.Width = 4 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Gets the using specified annotation name. The specified annotation name. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"Annotations.pdf"); //Get the annotation collection. PdfLoadedAnnotationCollection annotationCollection=document.Pages[0].Annotations; //Get the pfd sound annotation. PdfLoadedSoundAnnotation soundAnnotation = annotationCollection["SoundAnnotation"] as PdfLoadedSoundAnnotation; //Set the sound annotation border soundAnnotation.Border.Width = 4; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("Annotations.pdf") 'Get the annotation collection. Dim annotationCollection As PdfLoadedAnnotationCollection = document.Pages(0).Annotations 'Get the pfd sound annotation. Dim soundAnnotation As PdfLoadedSoundAnnotation = dannotationCollection("SoundAnnotation") 'Set the sound annotation border soundAnnotation.Border.Width = 4 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Gets and sets the where the annotation is present. The of the existing PDF document //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"Annotations.pdf"); //Get the annotation collection PdfLoadedAnnotationCollection annotationCollection=document.Pages[0].Annotations; //Get the PDF sound annotation. PdfLoadedSoundAnnotation soundAnnotation = annotationCollection[5] as PdfLoadedSoundAnnotation; 'Get the sound PDF loaded page. PdfLoadedPage page =soundAnnotation.Page; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("Annotations.pdf") 'Get the annotation collection Dim annotationCollection As PdfLoadedAnnotationCollection = document.Pages(0).Annotations 'Get the PDF sound annotation. Dim soundAnnotation As PdfLoadedSoundAnnotation = dannotationCollection(5) 'Get the PDF loaded page. Dim page As PdfLoadedPage=soundAnnotation.Page 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Gets or sets the boolean flag to flatten the annotations. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"Annotations.pdf"); //Get the annotation collection PdfLoadedAnnotationCollection annotationCollection=document.Pages[0].Annotations; //Set flatten. annotationCollection.Flatten = true; //Save the document. document.Save("output.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("Annotations.pdf") 'Get the annotation collection Dim annotationCollection As PdfLoadedAnnotationCollection = document.Pages(0).Annotations 'Set flatten. annotationCollection.Flatten = True 'Save the document. document.Save("output.pdf") document.Close(True) Represents the collection of . //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = free.ReviewHistory; foreach (PdfLoadedPopupAnnotation popup in reviewCollection){ //Gets the annotation state PdfAnnotationState state = popup.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popup.AnnotationStateModel; } //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = free.ReviewHistory For Each popup As PdfLoadedPopupAnnotation In reviewCollection 'Get the annotation state Dim state As PdfAnnotationState = popup.AnnotationState 'Get the annotation state model Dim model As PdfAnnotationStateModel = popup.AnnotationStateModel Next 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Initializes a new instance of the class. The page. The annotDictionary. Gets the review history of the annotation. The page. The annotDictionary. To add comments or reviews on the Annotation. //Load the PDF document PdfLoadedDocument ldoc = new PdfLoadedDocument("MutipleReview_Edit.pdf"); //Load the PDF document page PdfLoadedPage lpage = ldoc.Pages[0] as PdfLoadedPage; PdfLoadedAnnotationCollection annots = lpage.Annotations; //Load the annotation PdfLoadedLineAnnotation loadedLine = annots[0] as PdfLoadedLineAnnotation; //Get annoatation review history PdfLoadedPopupAnnotationCollection review = loadedLine.ReviewHistory; PdfLoadedPopupAnnotationCollection comments = loadedLine.Comments; //Add new review and comments PdfPopupAnnotation newReview = new PdfPopupAnnotation(); newReview.Author = "NewpopupAuthor"; newReview.State = PdfAnnotationState.Completed; newReview.StateModel = PdfAnnotationStateModel.Review; //Add review history loadedLine.ReviewHistory.Add(newReview); PdfPopupAnnotation newComment = new PdfPopupAnnotation(); newComment.Author = "Comment1"; newComment.Text = "comment1Text"; loadedLine.Comments.Add(newComment); //Save the document ldoc.Save("Output.pdf"); //Close the document ldoc.Close(true); Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("MutipleReview_Edit.pdf") Dim lpage As PdfLoadedPage = CType(ldoc.Pages(0), PdfLoadedPage) Dim annots As PdfLoadedAnnotationCollection = lpage.Annotations Dim loadedLine As PdfLoadedLineAnnotation = CType(annots(0), PdfLoadedLineAnnotation) Dim review As PdfLoadedPopupAnnotationCollection = loadedLine.ReviewHistory Dim comments As PdfLoadedPopupAnnotationCollection = loadedLine.Comments Dim newComment As PdfPopupAnnotation = New PdfPopupAnnotation newComment.Author = "Comment1" newComment.Text = "comment1Text" loadedLine.Comments.Add(newComment) Dim newReview As PdfPopupAnnotation = New PdfPopupAnnotation newReview.Author = "NewpopupAuthor" newReview.State = PdfAnnotationState.Completed newReview.StateModel = PdfAnnotationStateModel.Review 'Add review history loadedLine.ReviewHistory.Add(newReview) 'Save the document ldoc.Save("EditState.pdf") 'Close the document ldoc.Close(true) Removes the reviews or comments //Load the PDF document PdfLoadedDocument ldoc = new PdfLoadedDocument("MutipleReview_Edit.pdf"); //Load the PDF document page PdfLoadedPage lpage = ldoc.Pages[0] as PdfLoadedPage; PdfLoadedAnnotationCollection annots = lpage.Annotations; //Load the annotation PdfLoadedLineAnnotation loadedLine = annots[0] as PdfLoadedLineAnnotation; //Get annoatation review history PdfLoadedPopupAnnotationCollection review = loadedLine.ReviewHistory; PdfLoadedPopupAnnotationCollection comments = loadedLine.Comments; PdfPopupAnnotation newComment = new PdfPopupAnnotation(); newComment.Author = "Comment1"; newComment.Text = "comment1Text"; loadedLine.Comments.Add(newComment); //Create new review history PdfPopupAnnotation newReview = new PdfPopupAnnotation(); newReview.Author = "NewpopupAuthor"; newReview.State = PdfAnnotationState.Completed; newReview.StateModel = PdfAnnotationStateModel.Review; //Add review history loadedLine.ReviewHistory.Add(newReview); //Remove review and comments loadedLine.ReviewHistory.Remove(newReview); loadedLine.Comments.Remove(newComment); //Save the document ldoc.Save("Output.pdf"); //Close the document ldoc.Close(true); Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("MutipleReview_Edit.pdf") Dim lpage As PdfLoadedPage = CType(ldoc.Pages(0), PdfLoadedPage) Dim annots As PdfLoadedAnnotationCollection = lpage.Annotations Dim loadedLine As PdfLoadedLineAnnotation = CType(annots(0), PdfLoadedLineAnnotation) Dim review As PdfLoadedPopupAnnotationCollection = loadedLine.ReviewHistory Dim comments As PdfLoadedPopupAnnotationCollection = loadedLine.Comments Dim newComment As PdfPopupAnnotation = New PdfPopupAnnotation newComment.Author = "Comment1" newComment.Text = "comment1Text" loadedLine.Comments.Add(newComment) Dim newReview As PdfPopupAnnotation = New PdfPopupAnnotation newReview.Author = "NewpopupAuthor" newReview.State = PdfAnnotationState.Completed newReview.StateModel = PdfAnnotationStateModel.Review 'Add review history loadedLine.ReviewHistory.Add(newReview) 'Remove review and comments loadedLine.ReviewHistory.Remove(newReview) loadedLine.Comments.Remove(newComment) 'Save the document ldoc.Save("Output.pdf") 'Close the document ldoc.Close(true) Removes the annotation comments or reviews at the specified index //Load the PDF document PdfLoadedDocument ldoc = new PdfLoadedDocument("MutipleReview_Edit.pdf"); //Load the PDF document page PdfLoadedPage lpage = ldoc.Pages[0] as PdfLoadedPage; PdfLoadedAnnotationCollection annots = lpage.Annotations; //Load the annotation PdfLoadedLineAnnotation loadedLine = annots[0] as PdfLoadedLineAnnotation; //Get annoatation review history PdfLoadedPopupAnnotationCollection review = loadedLine.ReviewHistory; PdfLoadedPopupAnnotationCollection comments = loadedLine.Comments; PdfPopupAnnotation newComment = new PdfPopupAnnotation(); newComment.Author = "Comment1"; newComment.Text = "comment1Text"; loadedLine.Comments.Add(newComment); //Create new review history PdfPopupAnnotation newReview = new PdfPopupAnnotation(); newReview.Author = "NewpopupAuthor"; newReview.State = PdfAnnotationState.Completed; newReview.StateModel = PdfAnnotationStateModel.Review; //Add review history loadedLine.ReviewHistory.Add(newReview); //Remove review and comments loadedLine.ReviewHistory.RemoveAt(0); loadedLine.Comments.RemoveAt(0); //Save the document ldoc.Save("Output.pdf"); //Close the document ldoc.Close(true); Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("MutipleReview_Edit.pdf") Dim lpage As PdfLoadedPage = CType(ldoc.Pages(0), PdfLoadedPage) Dim annots As PdfLoadedAnnotationCollection = lpage.Annotations Dim loadedLine As PdfLoadedLineAnnotation = CType(annots(0), PdfLoadedLineAnnotation) Dim review As PdfLoadedPopupAnnotationCollection = loadedLine.ReviewHistory Dim comments As PdfLoadedPopupAnnotationCollection = loadedLine.Comments Dim newComment As PdfPopupAnnotation = New PdfPopupAnnotation newComment.Author = "Comment1" newComment.Text = "comment1Text" loadedLine.Comments.Add(newComment) Dim newReview As PdfPopupAnnotation = New PdfPopupAnnotation newReview.Author = "NewpopupAuthor" newReview.State = PdfAnnotationState.Completed newReview.StateModel = PdfAnnotationStateModel.Review 'Add review history loadedLine.ReviewHistory.Add(newReview) 'Remove review and comments loadedLine.ReviewHistory.RemoveAt(0) loadedLine.Comments.RemoveAt(0) 'Save the document ldoc.Save("Output.pdf") 'Close the document ldoc.Close(true) Check to avoid should not create child review state. To update comment state on PdfArray from annotation To update review state from PdfAnnotaion into PdfArray Gets the at the specified index.[Read-Only] Load an existing document PdfLoadedDocument document = new PdfLoadedDocument(@"../../Annotation.pdf"); //Load the existing Page on document PdfLoadedPage lpage = document.Pages[0] as PdfLoadedPage; //load the annotation collection on this page PdfLoadedAnnotationCollection annotations = lpage.Annotations; //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation freeText = annotations[0] as PdfLoadedFreeTextAnnotation; //Gets the review collection PdfLoadedPopupAnnotationCollection reviewCollection = freeText.ReviewHistory; PdfLoadedPopupAnnotation popupAnnot = reviewCollection[0]; //Gets the annotation state PdfAnnotationState state = popupAnnot.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popupAnnot.AnnotationStateModel; //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Load an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument("../../Annotation.pdf") 'Load the existing Page on document Dim lpage As PdfLoadedPage = document.Pages(0) 'load the annotation collection on this page Dim annotations As PdfLoadedAnnotationCollection = lpage.Annotations 'Load the existing PdfFreeTextAnnotation Dim freeText As PdfLoadedFreeTextAnnotation = annotations(0) 'Gets the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = freeText.ReviewHistory Dim popupAnnot As PdfLoadedPopupAnnotation = reviewCollection(0) 'Gets the annotation state Dim state As PdfAnnotationState = popupAnnot.AnnotationState 'Gets the annotation state model Dim model As PdfAnnotationStateModel = popupAnnot.AnnotationStateModel 'Save the document document.Save("Output.pdf") 'Close the document document.Close(true) The represents the attachment annotation loaded from the existing PDF document, it provides methods and properties to modify the attachment. //Load an existing PDF document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Get the annotation from loaded document. PdfLoadedAttachmentAnnotation attchmentAnnotation = document.Pages[1].Annotations[3] as PdfLoadedAttachmentAnnotation; //Get the annotation flags PdfAnnotationFlags flag = attchmentAnnotation.AnnotationFlags; //Get the attachment annotation border. PdfAnnotationBorder border = attchmentAnnotation.Border; //Save the document. document.Save("LoadedAttachmentAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Get the annotation from loaded document. Dim attchmentAnnotation As PdfLoadedAttachmentAnnotation = document.Pages(1).Annotations(3) as PdfLoadedAttachmentAnnotation 'Get the annotation flags Dim flag As PdfAnnotationFlags = attchmentAnnotation.AnnotationFlags 'Get the attachment annotation border. Dim border As PdfAnnotationBorder = attchmentAnnotation.Border 'Save the document. document.Save("LoadedAttachmentAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets the Icon Gets the annotation review history. The review collection of the attachment annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfAttachmentAnnotation PdfLoadedAttachmentAnnotation attachment = document.Pages[0].Annotations[0] as PdfLoadedAttachmentAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = attachment.ReviewHistory; //save the document document.Save("AttachmentAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfAttachmentAnnotation Dim attachment As PdfLoadedAttachmentAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = attachment.ReviewHistory 'save the document document.Save("AttachmentAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the attachment annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfAttachmentAnnotation PdfLoadedAttachmentAnnotation attachment = document.Pages[0].Annotations[0] as PdfLoadedAttachmentAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = attachment.Comments; //save the document document.Save("AttachmentAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfAttachmentAnnotation Dim attachment As PdfLoadedAttachmentAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = attachment.Comments 'save the document document.Save("AttachmentAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets or sets the icon of the attachment annotation. The used to set the icon to the attachment annotation //Load an existing PDF document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Get the annotation from loaded document. PdfLoadedAttachmentAnnotation attchmentAnnotation = document.Pages[1].Annotations[3] as PdfLoadedAttachmentAnnotation; attchmentAnnotation.Icon=PdfAttachmentIcon.PushPin; //Save the document. document.Save("LoadedAttachmentAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Get the annotation from loaded document. Dim attchmentAnnotation As PdfLoadedAttachmentAnnotation = document.Pages(1).Annotations(3) as PdfLoadedAttachmentAnnotation attchmentAnnotation.Icon=PdfAttachmentIcon.PushPin 'Save the document. document.Save("LoadedAttachmentAnnotation.pdf") document.Close(True) The name of the file to be attached. //Load an existing PDF document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Get the annotation from loaded document. PdfLoadedAttachmentAnnotation attchmentAnnotation = document.Pages[1].Annotations[3] as PdfLoadedAttachmentAnnotation; //Get the attached file name string fileName = attchmentAnnotation.FileName; //Save and close the document. document.Save("LoadedAttachmentAnnotation.pdf"); document.Close(true); 'Load an existing PDF document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Get the annotation from loaded document. Dim attchmentAnnotation As PdfLoadedAttachmentAnnotation = TryCast(document.Pages(1).Annotations(3), PdfLoadedAttachmentAnnotation) 'Get the attached file name Dim fileName As String = attchmentAnnotation.FileName 'Save and close the document. document.Save("LoadedAttachmentAnnotation.pdf") document.Close(True) Get the data bytes from the attached file. The array of data bytes of the attached file /// //Load an existing PDF document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Get the annotation from loaded document. PdfLoadedAttachmentAnnotation attchmentAnnotation = document.Pages[1].Annotations[3] as PdfLoadedAttachmentAnnotation; //Get the attached file name string fileName = attchmentAnnotation.FileName; //Get the array of data bytes of the attached file. byte[] data = attchmentAnnotation.Data; //Save and close the document. document.Save("LoadedAttachmentAnnotation.pdf"); document.Close(true); 'Load an existing PDF document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Get the annotation from loaded document. Dim attchmentAnnotation As PdfLoadedAttachmentAnnotation = TryCast(document.Pages(1).Annotations(3), PdfLoadedAttachmentAnnotation) 'Get the attached file name Dim fileName As String = attchmentAnnotation.FileName 'Get the array of data bytes of the attached file. Dim data As Byte() = attchmentAnnotation.Data 'Save and close the document. document.Save("LoadedAttachmentAnnotation.pdf") document.Close(True) Represents the loaded document link annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedDocumentLinkAnnotation documentLinkAnnotation = document.Pages[1].Annotations[4] as PdfLoadedDocumentLinkAnnotation; //Gets the annotation flags PdfAnnotationFlags flag = documentLinkAnnotation.AnnotationFlags; //Sets the PDF destination. documentLinkAnnotation.Destination = new PdfDestination(document.Pages[0], new PointF(10, 10)); //Gets the document link annotation border. PdfAnnotationBorder border = documentLinkAnnotation.Border; //Gets the document link annotation bounds. RectangleF rectangle = documentLinkAnnotation.Bounds; //Gets the document link annotation color. PdfColor color = documentLinkAnnotation.Color; //Gets the document link annotation location. PointF point = documentLinkAnnotation.Location; //Gets the document link annotation size. SizeF size = documentLinkAnnotation.Size; //Gets the document link annotation text. string text = documentLinkAnnotation.Text; //Save the document. document.Save("documentLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim documentLinkAnnotation As PdfLoadedDocumentLinkAnnotation = document.Pages(1).Annotations(4) as PdfLoadedDocumentLinkAnnotation 'Sets the destination. documentLinkAnnotation.Destination = New PdfDestination(document.Pages[0], New PointF(10, 10)); 'Gets the annotation flags Dim flag As PdfAnnotationFlags = documentLinkAnnotation.AnnotationFlags 'Gets the document link annotation border. Dim border As PdfAnnotationBorder = documentLinkAnnotation.Border 'Gets the document link annotation bounds. Dim rectangle As RectangleF = documentLinkAnnotation.Bounds 'Gets the document link annotation color. Dim color As PdfColor = documentLinkAnnotation.Color 'Gets the document link annotation location. Dim point As PointF = documentLinkAnnotation.Location 'Gets the document link annotation size. Dim size As SizeF = documentLinkAnnotation.Size 'Gets the document link annotation text. Dim text As string = documentLinkAnnotation.Text 'Save the document. document.Save("documentLinkAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class Cross Table Initializes a new instance of the class. The dictionary. The cross table. The rectangle Gets the destination of the document link annotation The provides destination page and bounds Sets the destination of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedDocumentLinkAnnotation documentLinkAnnotation = document.Pages[1].Annotations[4] as PdfLoadedDocumentLinkAnnotation; //Gets the annotation flags PdfAnnotationFlags flag = documentLinkAnnotation.AnnotationFlags; //Sets the destination. documentLinkAnnotation.Destination = new PdfDestination(document.Pages[0], new PointF(10, 10)); //Save the document. document.Save("documentLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim documentLinkAnnotation As PdfLoadedDocumentLinkAnnotation = document.Pages(1).Annotations(4) as PdfLoadedDocumentLinkAnnotation 'Sets the destination. documentLinkAnnotation.Destination = New PdfDestination(document.Pages[0], New PointF(10, 10)); 'Save the document. document.Save("documentLinkAnnotation.pdf") document.Close(True) Class Class Class Represents the loaded file link annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Gets the annotation flags PdfAnnotationFlags flag = attchmentAnnotation.AnnotationFlags; //Sets the file name. fileLinkAnnotation.FileName = @"..\..\Data\Manual.txt"; //Gets the file link annotation border. PdfAnnotationBorder border = fileLinkAnnotation.Border; //Gets the file link annotation bounds. RectangleF rectangle = fileLinkAnnotation.Bounds; //Gets the file link annotation bounds. PdfColor color = fileLinkAnnotation.Color; //Gets the file link annotation location. PointF point = fileLinkAnnotation.Location; //Gets the file link annotation size. SizeF size = fileLinkAnnotation.Size; //Gets the file link annotation text. string text = fileLinkAnnotation.Text; //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the file name. fileLinkAnnotation.FileName = "..\..\Data\Manual.txt" 'Gets the annotation flags Dim flag As PdfAnnotationFlags = fileLinkAnnotation.AnnotationFlags 'Gets the file link annotation border. Dim border As PdfAnnotationBorder = fileLinkAnnotation.Border 'Gets the file link annotation bounds. Dim rectangle As RectangleF = fileLinkAnnotation.Bounds 'Gets the file link annotation bounds. Dim color As PdfColor = fileLinkAnnotation.Color 'Gets the file link annotation location. Dim point As PointF = fileLinkAnnotation.Location 'Gets the file link annotation size. Dim size As SizeF = fileLinkAnnotation.Size 'Gets the file link annotation text. Dim text As string = fileLinkAnnotation.Text 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class Interger array of destination CrossTable Action of the page Destination array Gets the filename. File name Initializes a new instance of the class. The dictionary. The cross table. The rectangle The File name Initializes a new instance of the class. The dictionary. The cross table. The destination The rectangle The File name Gets the destination array integer destination array //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation fileLinkAnnotation = document.Pages[1].Annotations[6] as PdfLoadedFileLinkAnnotation; //Gets the annotation flags PdfAnnotationFlags flag = attchmentAnnotation.AnnotationFlags; //Sets the file name. fileLinkAnnotation.FileName = @"..\..\Data\Manual.txt"; //Gets the file link annotation border. //Save the document. document.Save("fileLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim fileLinkAnnotation As PdfLoadedFileLinkAnnotation = document.Pages(1).Annotations(6) as PdfLoadedFileLinkAnnotation 'Sets the file name. fileLinkAnnotation.FileName = "..\..\Data\Manual.txt" 'Save the document. document.Save("fileLinkAnnotation.pdf") document.Close(True) Gets or sets the destination of the filelinkannotation. Gets or sets the destination array of the annotation, the destination array contains page number and positions. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedFileLinkAnnotation linkAnnotation = lDoc.Pages[1].Annotations[2] as PdfLoadedFileLinkAnnotation; //Assign DestinationArray[pagenumber,xaxis,yaxis] int[] array = new int[3] { 2, 750, 0 }; linkAnnotation.DestinationArray = array; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim linkAnnotation As PdfLoadedFileLinkAnnotation = lDoc.Pages(1).Annotations(2) as PdfLoadedFileLinkAnnotation 'Assign DestinationArray[pagenumber,xaxis,yaxis] Dim array As Integer() = New Integer(2) {2, 750, 0} linkAnnotation.DestinationArray = array 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Represents the loaded document PdfFreeText annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing Page on document PdfLoadedPage lPage = document.Pages[0] as PdfLoadedPage; //load the annotation collection on this page PdfLoadedAnnotationCollection collection = lPage.Annotations; //Get the Annotation from the loaded page PdfLoadedFreeTextAnnotation free = collection[0] as PdfLoadedFreeTextAnnotation; //Get the Annotation position RectangleF rectangle = free.Bounds; //Set a new position free.Bounds = new RectangleF(200, 100, 150, 50); //Set Annotation Border free.Border= new PdfAnnotationBorder(3f); //save the document document.Save("FreetextAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing Page on document Dim lPage As PdfLoadedPage = document.Pages(0) 'load the annotation collection on this page Dim collection As PdfLoadedAnnotationCollection = lPage.Annotations 'Get the Annotation from the loaded page Dim free As PdfLoadedFreeTextAnnotation = collection(0) 'Get the Annotation position Dim rectangle As RectangleF = free.Bounds 'Set a new position free.Bounds = new RectangleF(200, 100, 150, 50) 'Set Annotation Border free.Border= new PdfAnnotationBorder(3f) 'save the document document.Save("FreetextAnnotation.pdf") document.Close(True) Class Class function :GetFontDetais To call function update font details on Font type,size and colour using ContentParser from APContent stream Saves an annotation. Flatten annotation Create annotation appearance Draw arrow for callout line Draw Free text annotation appearance Obtain style from annotation Calculate arrow points Obtain appearance bounds for free text annotation Draw Free text rectangle Draw Free mark text in appearance Set rectangle differance Draw Callouts line for annotation Clone Callout lines Gets the textAlignment to freetext annotation Gets the annotation review history. The review collection of the free text annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = free.ReviewHistory; foreach (PdfLoadedPopupAnnotation popup in reviewCollection){ //Gets the annotation state PdfAnnotationState state = popup.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popup.AnnotationStateModel; } //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = free.ReviewHistory For Each popup As PdfLoadedPopupAnnotation In reviewCollection 'Get the annotation state Dim state As PdfAnnotationState = popup.AnnotationState 'Get the annotation state model Dim model As PdfAnnotationStateModel = popup.AnnotationStateModel Next 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the free text annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = free.Comments; foreach (PdfLoadedPopupAnnotation popup in reviewCollection){ //Gets the annotation state PdfAnnotationState state = popup.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popup.AnnotationStateModel; } //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = free.Comments For Each popup As PdfLoadedPopupAnnotation In reviewCollection 'Get the annotation state Dim state As PdfAnnotationState = popup.AnnotationState 'Get the annotation state model Dim model As PdfAnnotationStateModel = popup.AnnotationStateModel Next 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Class Class //Get or set the Line Ending style for the free text annotation //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the line ending style PdfLineEndingStyle style = free.LineEndingStyle; //Set the line ending style free.LineEndingStyle = PdfLineEndingStyle.OpenArrow; //save the document document.Save("FreetextAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the line ending style Dim style As PdfLineEndingStyle = free.LineEndingStyle 'Set the line ending style free.LineEndingStyle = PdfLineEndingStyle.OpenArrow 'save the document document.Save("FreetextAnnotation.pdf") document.Close(True) Class Class //Get or set the MarkUp text for the free text annotation //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the MarkUpText string text= free.MarkUpText; //Set the MarkUpText free.MarkUpText = "This is Free Text Annotation"; //save the document document.Save("FreetextAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the MarkUpText Dim text As string = free.MarkUpText 'Set the MarkUpText free.MarkUpText = "This is Free Text Annotation" 'save the document document.Save("FreetextAnnotation.pdf") document.Close(True) Class Class Gets or sets whether getting text from stream //Get or set the Annotation Intent for the free text annotation //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the PdfAnnotation Intent PdfAnnotationIntent intent = free.AnnotationIntent; //Set the PdfAnnotation Intent free.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout; //save the document document.Save("FreetextAnnotation.pdf"); //Close the document document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the PdfAnnotation Intent Dim intent As PdfAnnotationIntent = free.AnnotationIntent 'Set the PdfAnnotation Intent free.AnnotationIntent = PdfAnnotationIntent.FreeTextCallout 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document document.Close(True) Class Class //Get or set the Font for the free text annotation //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the Font PdfFont font = free.Font; //Set the Font free.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 15f); //save the document document.Save("FreetextAnnotation.pdf"); //Close the document document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the Font Dim font As PdfFont = free.Font 'Set the Font free.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 15f) 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document document.Close(True) Class Class //Get or set the TextMarkupColor for the free text annotation The text markup color of the free text annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the TextMarkupColor PdfColor markupColor = free.TextMarkupColor; //Set the TextMarkupColor free.TextMarkupColor = new PdfColor(Color.Red); //save the document document.Save("FreetextAnnotation.pdf"); //Close the document. document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) as PdfLoadedFreeTextAnnotation 'Get the TextMarkupColor Dim markupColor As PdfColor = free.TextMarkupColor 'Set the TextMarkupColor free.TextMarkupColor = new PdfColor(Color.Red) 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Class Class //Get or set the CelloutLines for the free text annotation //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the CelloutLines PointF[] celloutLines = free.CalloutLines; //Set the CelloutLines free.CalloutLines = new PointF[] { new PointF(107.234f, 550.15f), new PointF(130.023f, 811.707f), new PointF(142.023f, 811.707f) }; //save the document document.Save("FreetextAnnotation.pdf"); //Close the document document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) as PdfLoadedFreeTextAnnotation 'Get the CelloutLines Dim celloutLines As PointF() = free.CalloutLines 'Set the CelloutLines free.CalloutLines = New PointF() {New PointF(107.234F, 550.15F), New PointF(130.023F, 811.707F), New PointF(142.023F, 811.707F)} 'save the document document.Save("FreetextAnnotation.pdf") document.Close(True) Class Class //Get or set the BorderColor for the free text annotation The border color of the free text annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the BorderColor PdfColor borderColor = free.BorderColor; //Set the BorderColor free.BorderColor = new PdfColor(Color.Blue); //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the BorderColor Dim borderColor As PdfColor = free.BorderColor 'Set the BorderColor free.BorderColor = new PdfColor(Color.Blue) 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets or sets the complex script to add different languages texts in free text annotation. /// //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Set the Complex script free.ComplexScript = true; //Set the text free.Text = "पत्र‍ांक दिनांक"; //Set Appearance free.SetAppearance(true); //Set the font free.Font = new PdfTrueTypeFont(new Font("Nirmala UI", 14), true); //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Set the Complex script free.ComplexScript = True 'Set the text free.Text = "पत्र‍ांक दिनांक" 'Set Appearance free.SetAppearance(True) //Set the font free.Font = New PdfTrueTypeFont(New Font("Nirmala UI", 14), True) 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Class Class //Gets or sets the text alignment to free text annotations. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Sets the text alignment of the text annotation. free.TextAlignment = PdfTextAlignment.Right; free.setAppearance(true); //save the document document.Save("FreetextAnnotation.pdf"); //Close the document document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Sets the text alignment of the text annotation. free.TextAlignment = PdfTextAlignment.Right free.setAppearance(true) 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document document.Close(True) //Gets or sets the text direction to free text annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Sets the text alignment of the text annotation. free.TextAlignment = PdfTextAlignment.Right; free.TextDirection = PdfTextDirection.RightToLeft; free.setAppearance(true); //save the document document.Save("FreetextAnnotation.pdf"); //Close the document document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Sets the text alignment of the text annotation. free.TextAlignment = PdfTextAlignment.Right free.TextDirection = PdfTextDirection.RightToLeft free.setAppearance(true) 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document document.Close(True) Represent Loaded ink annotation, Ink annotation represents freehand scribble comprising one or more disjoint paths. //Load a PDF document. PdfLoadedDocument document = new PdfLoadedDocument("InkAnnot.pdf"); //Load a page PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Load a ink annotation PdfLoadedInkAnnotation inkAnnotation = page.Annotations[2] as PdfLoadedInkAnnotation; List(float) linePoints = new List(float) { 40, 300, 60, 100, 40, 50, 40, 300 }; //Set the line points inkAnnotation.InkList = linePoints; inkAnnotation.Color = new PdfColor(Color.Red); //Save the document to disk. document.Save("InkAnnot.pdf"); document.Close(true); 'Load a PDF document. Dim document As New PdfLoadedDocument("InkAnnot.pdf") 'Load a page Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Load a ink annotation Dim inkAnnotation As PdfLoadedInkAnnotation = TryCast(page.Annotations(2), PdfLoadedInkAnnotation) Dim linePoints As New List(Of Single)() From {40, 300, 60, 100, 40, 50, 40,300} 'Set the line points inkAnnotation.InkList = linePoints inkAnnotation.Color = New PdfColor(Color.Red) 'Save the document to disk. document.Save("InkAnnot.pdf") document.Close(True) Class Class Cross table Indicate the path of the ink annotation Indicate multiple path of the ink annotation Internal variable to store Border Dash. border width Border line width Indicate the border Dictionary Indicat the border style Initializes a new instance of the class The Dictionary The Crosstable the Rectangle Get the Path of the Ink annotation the line InkList Get the Path collection of the Ink annotation the line InkList Get the border width The border width Get the Dash array value The dashArray Saves an annotation. Create appearance for annotation Flatten annotation Add ink points Calculates control points for all the path points input given by Beizer spline curve control points calculation. Calculates single control point for the vector input given. Gets the annotation review history. The review collection of the ink annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfinkAnnotation PdfLoadedInkAnnotation ink = document.Pages[0].Annotations[0] as PdfLoadedInkAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = ink.ReviewHistory; //save the document document.Save("InkAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfInkAnnotation Dim ink As PdfLoadedInkAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = ink.ReviewHistory 'save the document document.Save("InkAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation comments history. The Comments collection of the ink annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfinkAnnotation PdfLoadedInkAnnotation ink = document.Pages[0].Annotations[0] as PdfLoadedInkAnnotation; //Get the comments collection PdfLoadedPopupAnnotationCollection commentsCollection = ink.Comments; //save the document document.Save("InkAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfInkAnnotation Dim ink As PdfLoadedInkAnnotation = document.Pages(0).Annotations(0) 'Get the comments collection Dim commentsCollection As PdfLoadedPopupAnnotationCollection = ink.Comments 'save the document document.Save("InkAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets or sets mutiple points of the InkList value. Get or sets the border width of the ink annotation. The default value of border width is 1. //Load a PDF document. PdfLoadedDocument document = new PdfLoadedDocument("InkAnnot.pdf"); //Load a page PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Load a ink annotation PdfLoadedInkAnnotation inkAnnotation = page.Annotations[2] as PdfLoadedInkAnnotation; List(float) linePoints = new List(float) { 40, 300, 60, 100, 40, 50, 40, 300 }; //Set the line points inkAnnotation.InkList = linePoints; //Set the color of the annotation. inkAnnotation.Color = new PdfColor(Color.Red); //Set the Border width of the annotation. inkAnnotation.BorderWidth = 3; //Set the border style inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed; //Set the value for dash border of the annotation inkAnnotation.DashArray = new int[] { 2, 2 }; //Save the document to disk. document.Save("InkAnnot.pdf"); document.Close(true); 'Load a PDF document. Dim document As New PdfLoadedDocument("InkAnnot.pdf") 'Load a page Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Load a ink annotation Dim inkAnnotation As PdfLoadedInkAnnotation = TryCast(page.Annotations(2), PdfLoadedInkAnnotation) Dim linePoints As New List(Of Single)() From {40, 300, 60, 100, 40, 50, 40,300} 'Set the line points inkAnnotation.InkList = linePoints 'Set the color of the annotation. inkAnnotation.Color = New PdfColor(Color.Red) 'Set the Border width of the annotation. inkAnnotation.BorderWidth = 3 'Set the border style inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed 'Set the value for dash border of the annotation inkAnnotation.DashArray = New Integer() {2, 2} 'Save the document to disk. document.Save("InkAnnot.pdf") document.Close(True) Class Class Gets or sets the border line width of an ink annotation. get or sets the border style of the ink annotation, default value is PdfLineBorderStyle.Solid The , provides various type of borders //Load a PDF document. PdfLoadedDocument document = new PdfLoadedDocument("InkAnnot.pdf"); //Load a page PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Load a ink annotation PdfLoadedInkAnnotation inkAnnotation = page.Annotations[2] as PdfLoadedInkAnnotation; List(float) linePoints = new List(float) { 40, 300, 60, 100, 40, 50, 40, 300 }; //Set the line points inkAnnotation.InkList = linePoints; //Set the color of the annotation. inkAnnotation.Color = new PdfColor(Color.Red); //Set the Border width of the annotation. inkAnnotation.BorderWidth = 3; //Set the border style inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed; //Set the value for dash border of the annotation inkAnnotation.DashArray = new int[] { 2, 2 }; //Save the document to disk. document.Save("InkAnnot.pdf"); document.Close(true); 'Load a PDF document. Dim document As New PdfLoadedDocument("InkAnnot.pdf") 'Load a page Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Load a ink annotation Dim inkAnnotation As PdfLoadedInkAnnotation = TryCast(page.Annotations(2), PdfLoadedInkAnnotation) Dim linePoints As New List(Of Single)() From {40, 300, 60, 100, 40, 50, 40,300} 'Set the line points inkAnnotation.InkList = linePoints 'Set the color of the annotation. inkAnnotation.Color = New PdfColor(Color.Red) 'Set the Border width of the annotation. inkAnnotation.BorderWidth = 3 'Set the border style inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed 'Set the value for dash border of the annotation inkAnnotation.DashArray = New Integer() {2, 2} 'Save the document to disk. document.Save("InkAnnot.pdf") document.Close(True) Class Class Gets or sets the value for dashed border of ink annotation. //Load a PDF document. PdfLoadedDocument document = new PdfLoadedDocument("InkAnnot.pdf"); //Load a page PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Load a ink annotation PdfLoadedInkAnnotation inkAnnotation = page.Annotations[2] as PdfLoadedInkAnnotation; List(float) linePoints = new List(float) { 40, 300, 60, 100, 40, 50, 40, 300 }; //Set the line points inkAnnotation.InkList = linePoints; //Set the color of the annotation. inkAnnotation.Color = new PdfColor(Color.Red); //Set the Border width of the annotation. inkAnnotation.BorderWidth = 3; //Set the border style inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed; //Set the value for dash border of the annotation inkAnnotation.DashArray = new int[] { 2, 2 }; //Save the document to disk. document.Save("InkAnnot.pdf"); document.Close(true); 'Load a PDF document. Dim document As New PdfLoadedDocument("InkAnnot.pdf") 'Load a page Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Load a ink annotation Dim inkAnnotation As PdfLoadedInkAnnotation = TryCast(page.Annotations(2), PdfLoadedInkAnnotation) Dim linePoints As New List(Of Single)() From {40, 300, 60, 100, 40, 50, 40,300} 'Set the line points inkAnnotation.InkList = linePoints 'Set the color of the annotation. inkAnnotation.Color = New PdfColor(Color.Red) 'Set the Border width of the annotation. inkAnnotation.BorderWidth = 3 'Set the border style inkAnnotation.BorderStyle = PdfLineBorderStyle.Dashed 'Set the value for dash border of the annotation inkAnnotation.DashArray = New Integer() {2, 2} 'Save the document to disk. document.Save("InkAnnot.pdf") document.Close(True) Class Class Represents the loaded line annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; int[] points = new int[] { 100, 100, 200, 100 }; //Create a new PDF line border. LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.DashArray = 1; lineBorder.BorderWidth =3; lineBorder.DashArray = 8; //Sets the line border. lineAnnotation.LineBorder = lineBorder; //Sets the line indent. lineAnnotation.LineIntent = PdfLineIntent.LineArrow; //Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Slash; lineAnnotation.EndLineStyle = PdfLineEndingStyle.Circle; lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Locked; //Assign the line color lineAnnotation.InnerLineColor = new PdfColor(Color.Blue); lineAnnotation.BackColor = new PdfColor(Color.Red); //Assign the leader line lineAnnotation.LeaderExt = 20; lineAnnotation.LeaderLine = 20; lineAnnotation.Size = new SizeF(100, 200); //Assign the line caption lineAnnotation.LineCaption = true; lineAnnotation.Text = "Syncfusion"; lineAnnotation.CaptionType = PdfLineCaptionType.Top; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) Dim points As Integer() = { 100, 100, 200, 100 } 'Create a new pdf line border. Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.DashArray = 1 lineBorder.BorderWidth = 3 lineBorder.DashArray = 8 'Sets the line border lineAnnotation.LineBorder = lineBorder 'Sets the line indent lineAnnotation.LineIntent = PdfLineIntent.LineArrow 'Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Slash lineAnnotation.EndLineStyle = PdfLineEndingStyle.Circle lineAnnotation.AnnotationFlags = PdfAnnotationFlags.Locked 'Assign the line color lineAnnotation.InnerLineColor = New PdfColor(Color.Blue) lineAnnotation.BackColor = New PdfColor(Color.Red) 'Assign the leader line lineAnnotation.LeaderExt = 20 lineAnnotation.LeaderLine = 20 lineAnnotation.Size = New SizeF(100, 200) 'Assign the line caption lineAnnotation.LineCaption = True lineAnnotation.Text = "Syncfusion" lineAnnotation.CaptionType = PdfLineCaptionType.Top 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class Cross Table Indicates the back color. Indicates the line border. Internal variable to store field's font. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets the line intent of the annotation. The line intent. Gets line style of the annotation. The line style. Gets line style of the annotation. choice The line style. Gets line style of the annotation. Type of line style The line style. Get the inner line color Gets back color of the annotation. The back color. Gets caption type of the annotation. The caption type. Gets caption type of the annotation. caption type The caption type. Gets line caption of the annotation. The line caption. Gets leader line of the annotation. The leader line. Gets leader ext of the annotation. The leader ext. Gets leader offset of the annotation. The leader offset. Gets line border of the annotation. The line border. Gets line points of the annotation. Line Points The Line Points. Gets border style of the annotation. border style The border style. Saves an annotation . Flatten annotation Obtain Line Bounds Create appearance for annotation Gets the annotation review history. The review collection of the line annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLineAnnotation PdfLoadedLineAnnotation line = document.Pages[0].Annotations[0] as PdfLoadedLineAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = line.ReviewHistory; //save the document document.Save("LineAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim line As PdfLoadedLineAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = line.ReviewHistory 'save the document document.Save("LineAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the line annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfLineAnnotation PdfLoadedLineAnnotation line = document.Pages[0].Annotations[0] as PdfLoadedLineAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = line.Comments; //save the document document.Save("LineAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim line As PdfLoadedLineAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = line.Comments 'save the document document.Save("LineAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets or sets the back color of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Sets the line annotation back color. lineAnnotation.BackColor = new PdfColor(Color.Red); //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Sets the line annotation back color lineAnnotation.BackColor = New PdfColor(Color.Red) 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the begin line style of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Slash; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Assign the line ending style lineAnnotation.BeginLineStyle = PdfLineEndingStyle.Slash 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the caption type of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Sets the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Top; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Sets the line caption type. lineAnnotation.CaptionType = PdfLineCaptionType.Top 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the end line style of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Assign the line ending style lineAnnotation.EndLineStyle = PdfLineEndingStyle.Circle; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Assign the line ending style lineAnnotation.EndLineStyle = PdfLineEndingStyle.Circle 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the inner line color of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Assign the line color lineAnnotation.InnerLineColor = new PdfColor(Color.Blue); //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Assign the line color lineAnnotation.InnerLineColor = New PdfColor(Color.Blue) 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the leader line of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Sets the leader line. lineAnnotation.LeaderLine = 20; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Sets the leader line. lineAnnotation.LeaderLine = 20 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the leader ext of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Assign the leader line lineAnnotation.LeaderExt = 20; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Assign the leader line lineAnnotation.LeaderExt = 20 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the leader offset of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Assign the leader Offset lineAnnotation.LeaderOffset = 20; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Assign the leader Offset lineAnnotation.LeaderOffset = 20 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets the line border of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Create a new pdf line border. LineBorder lineBorder = new LineBorder(); lineBorder.BorderStyle = PdfBorderStyle.Solid; lineBorder.DashArray = 1; lineBorder.BorderWidth =3; lineBorder.DashArray = 8; lineAnnotation.LineBorder = lineBorder; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Create a new pdf line border. Dim lineBorder As New LineBorder() lineBorder.BorderStyle = PdfBorderStyle.Solid lineBorder.DashArray = 1 lineBorder.BorderWidth = 3 lineBorder.DashArray = 8 lineAnnotation.LineBorder = lineBorder 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True); Class Class Gets or sets the line points of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Get the line points int[] linePoints = lineAnnotation.LinePoints; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Get the line points Dim linePoints As Integer() = lineAnnotation.LinePoints 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the line caption of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; //Assign the line caption lineAnnotation.LineCaption = true; lineAnnotation.CaptionType = PdfLineCaptionType.Top; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) 'Assign the line caption lineAnnotation.LineCaption = True lineAnnotation.CaptionType = PdfLineCaptionType.Top 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Gets or sets the line intent of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedLineAnnotation lineAnnotation = document.Pages[1].Annotations[5] as PdfLoadedLineAnnotation; lineAnnotation.LineIntent = PdfLineIntent.LineArrow; //Save the document. document.Save("lineAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim lineAnnotation As PdfLoadedLineAnnotation = document.Pages(1).Annotations(5) lineAnnotation.LineIntent = PdfLineIntent.LineArrow 'Save the document. document.Save("lineAnnotation.pdf") document.Close(True) Class Class Represents the loaded pop up annotation class. This class is used to load the pop up annotation from the PDF document. Please refer the UG docuemntation link for more details. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedPopupAnnotation popupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedPopupAnnotation; //Sets the popup annotation border popupAnnotation.Border.Width = 4; popupAnnotation.Border.HorizontalRadius = 20; popupAnnotation.Border.VerticalRadius = 30; //Set the popup icon popupAnnotation.Icon = PdfPopupIcon.Key; //Save the document. document.Save("popupAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim popupAnnotation As PdfLoadedPopupAnnotation = document.Pages(1).Annotations(5) 'Sets the popup annotation border popupAnnotation.Border.Width = 4 popupAnnotation.Border.HorizontalRadius = 20 popupAnnotation.Border.VerticalRadius = 30 'Set the popup icon popupAnnotation.Icon = PdfPopupIcon.Key 'Save the document. document.Save("popupAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class CroosTable Indicates the open the popup window or not. Indicates the icon name. Indicate annotation state Indicate annotation state model Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets the boolean value ( if it's true popup window is opened otherwise closed. Gets the popup icon type. Gets the popup icon name Icon name Icon type Saves an annotation. Set the popup comment window bounds The bounds of the popup comment window. Gets the annotation review history. The review collection of the popup annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfPopupAnnotation PdfLoadedPopupAnnotation popup = document.Pages[0].Annotations[0] as PdfLoadedPopupAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = popup.ReviewHistory; //save the document document.Save("PopupAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfPopupAnnotation Dim popup As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = popup.ReviewHistory 'save the document document.Save("PopupAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the popup annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfPopupAnnotation PdfLoadedPopupAnnotation popup = document.Pages[0].Annotations[0] as PdfLoadedPopupAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = popup.Comments; //save the document document.Save("PopupAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfPopupAnnotation Dim popup As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = popup.Comments 'save the document document.Save("PopupAnnotation.pdf") 'Close the document. document.Close(True) Class Class Get or sets the annotation State. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = free.ReviewHistory; foreach (PdfLoadedPopupAnnotation popup in reviewCollection){ //Gets the annotation state PdfAnnotationState state = popup.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popup.AnnotationStateModel; } //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = free.ReviewHistory For Each popup As PdfLoadedPopupAnnotation In reviewCollection 'Get the annotation state Dim state As PdfAnnotationState = popup.AnnotationState 'Get the annotation state model Dim model As PdfAnnotationStateModel = popup.AnnotationStateModel Next 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Get or sets the annotation State Model. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfFreeTextAnnotation PdfLoadedFreeTextAnnotation free = document.Pages[0].Annotations[0] as PdfLoadedFreeTextAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = free.ReviewHistory; foreach (PdfLoadedPopupAnnotation popup in reviewCollection){ //Gets the annotation state PdfAnnotationState state = popup.AnnotationState; //Gets the annotation state model PdfAnnotationStateModel model = popup.AnnotationStateModel; } //save the document document.Save("FreetextAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfFreeTextAnnotation Dim free As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = free.ReviewHistory For Each popup As PdfLoadedPopupAnnotation In reviewCollection 'Get the annotation state Dim state As PdfAnnotationState = popup.AnnotationState 'Get the annotation state model Dim model As PdfAnnotationStateModel = popup.AnnotationStateModel Next 'save the document document.Save("FreetextAnnotation.pdf") 'Close the document. document.Close(True) Gets or sets the open option of the popup annotation. if true open,otherwise not open //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedPopupAnnotation popupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedPopupAnnotation; //Set the popup annotation open option popupAnnotation.Open = true //Save the document. document.Save("popupAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim popupAnnotation As PdfLoadedPopupAnnotation = document.Pages(1).Annotations(5) 'Set the popup annotation open option popupAnnotation.Open = True 'Save the document. document.Save("popupAnnotation.pdf") document.Close(True) Gets or sets the icon of the annotation. The , provides icons to the annotation //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedPopupAnnotation popupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedPopupAnnotation; //Set the PDF popup icon popupAnnotation.Icon = PdfPopupIcon.Key; //Save the document. document.Save("popupAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim popupAnnotation As PdfLoadedPopupAnnotation = document.Pages(1).Annotations(5) 'Set the PDF popup icon popupAnnotation.Icon = PdfPopupIcon.Key 'Save the document. document.Save("popupAnnotation.pdf") document.Close(True) Represents the loaded rubber stamp annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedRubberStampAnnotation rubberStampAnnotation = document.Pages[1].Annotations[5] as PdfLoadedRubberStampAnnotation; //Sets the rubber stamp annotation border rubberStampAnnotation.Border.Width = 4; rubberStampAnnotation.Border.HorizontalRadius = 20; rubberStampAnnotation.Border.VerticalRadius = 30; //Set the PDF rubber stamp annotation icon rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Approved; //Save the document. document.Save("RubberStampAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim popupAnnotation As PdfLoadedRubberStampAnnotation = document.Pages(1).Annotations(5) as PdfLoadedRubberStampAnnotation 'Sets the rubber stamp annotation border rubberStampAnnotation.Border.Width = 4 rubberStampAnnotation.Border.HorizontalRadius = 20 rubberStampAnnotation.Border.VerticalRadius = 30 'Set the PDF rubber stamp annotation icon rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Approved 'Save the document. document.Save("RubberStampAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class Crosstable Rubber and Stamp Annotation name. internal variable for Icon name to draw graphically internal variable to store rotation value, if page have rotation internal variable to width size for rubber stamp boolean variable indicates need to create appearance for Standard ICON internal variable to set rotation angle. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets the popup icon type. Gets the popup icon name Icon name Icon type Obtain the background color for stamp PdfColor type Obtain the border color for stamp PdfColor type Saves an Annotation Flatten annotation Flatten annotation appearance Create appearance for annotation Create standard stamp appearance Draw rubber stamp Draw rubber stamp Modify rubber stamp appearance Set matrix for annotation appearance Gets the annotation review history. The review collection of the rubber stamp annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfRubberStampAnnotation PdfLoadedRubberStampAnnotation rubber = document.Pages[0].Annotations[0] as PdfLoadedRubberStampAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = rubber.ReviewHistory; //save the document document.Save("PdfRubberStampAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfRubberStampAnnotation Dim rubber As PdfLoadedRubberStampAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = rubber.ReviewHistory 'save the document document.Save("PdfRubberStampAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the rubber stamp annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfRubberStampAnnotation PdfLoadedRubberStampAnnotation rubber = document.Pages[0].Annotations[0] as PdfLoadedRubberStampAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = rubber.Comments; //save the document document.Save("PdfRubberStampAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfRubberStampAnnotation Dim rubber As PdfLoadedRubberStampAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = rubber.Comments 'save the document document.Save("PdfRubberStampAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets or sets the icon of the annotation. The used to set icon to the rubber stamp annotation //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedRubberStampAnnotation rubberStampAnnotation = document.Pages[1].Annotations[5] as PdfLoadedRubberStampAnnotation; //Set the PDF rubber stamp annotation icon rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Approved; //Save the document. document.Save("RubberStampAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim popupAnnotation As PdfLoadedRubberStampAnnotation = document.Pages(1).Annotations(5) as PdfLoadedRubberStampAnnotation 'Set the PDF rubber stamp annotation icon rubberStampAnnotation.Icon = PdfRubberStampAnnotationIcon.Approved 'Save the document. document.Save("RubberStampAnnotation.pdf") document.Close(True) Gets the background color for stamp Gets the border color for stamp Gets the Font to draw ICON Represents the loaded sound annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Sets the sound annotation border soundAnnotation.Border.Width = 4; soundAnnotation.Border.HorizontalRadius = 20; soundAnnotation.Border.VerticalRadius = 30; //Set the PDF sound annotation icon. soundAnnotation.Icon = PdfSoundIcon.Speaker; //Sets the PDF sound. PdfSound sound = new PdfSound("Startup.wav"); soundAnnotation.Sound=sound; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Sets the sound annotation border soundAnnotation.Border.Width = 4 soundAnnotation.Border.HorizontalRadius = 20 soundAnnotation.Border.VerticalRadius = 30 'Set the PDF sound annotation icon. soundAnnotation.Icon = PdfSoundIcon.Speaker Sets the PDF sound. Dim sound As PdfSound = New PdfSound("Startup.wav") soundAnnotation.Sound=sound 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class CrossTable Internal variable to store sound. Dictionary Indicates the sound icon of the annotation. Indicates the appearance of the annotation. Gets the filename. File name Gets the sound annotation icon. Sound annotation icon Gets the icon name Icon type Sound icon Gets the sound file. Sound file Gets the sound annottation encoding type Encoding type Encoding type Initializes a new instance of the class. The dictionary. The cross table. The rectangle The filename Gets the annotation review history. The review collection of the sound annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfSoundAnnotation PdfLoadedSoundAnnotation sound = document.Pages[0].Annotations[0] as PdfLoadedSoundAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = sound.ReviewHistory; //save the document document.Save("PdfSoundAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfSoundAnnotation Dim sound As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = sound.ReviewHistory 'save the document document.Save("PdfSoundAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation Comments history. The Comments collection of the sound annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfSoundAnnotation PdfLoadedSoundAnnotation sound = document.Pages[0].Annotations[0] as PdfLoadedSoundAnnotation; //Get the Comments collection PdfLoadedPopupAnnotationCollection CommentsCollection = sound.Comments; //save the document document.Save("PdfSoundAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfSoundAnnotation Dim sound As PdfLoadedFreeTextAnnotation = document.Pages(0).Annotations(0) 'Get the Comments collection Dim CommentsCollection As PdfLoadedPopupAnnotationCollection = sound.Comments 'save the document document.Save("PdfSoundAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets or sets the sound of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Sets the PDF sound. PdfSound sound = new PdfSound("Startup.wav"); soundAnnotation.Sound=sound; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation Sets the PDF sound. Dim sound As PdfSound = New PdfSound("Startup.wav") soundAnnotation.Sound=sound 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True) //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; 'Gets the file name string filename =soundAnnotation.FileName; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Gets the file name Dim filename As String=soundAnnotation.FileName 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True); Gets or sets the icon of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedSoundAnnotation soundAnnotation = document.Pages[1].Annotations[5] as PdfLoadedSoundAnnotation; //Set the pdfsound icon soundAnnotation.Icon = PdfSoundIcon.Speaker; //Save the document. document.Save("SoundAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim soundAnnotation As PdfLoadedSoundAnnotation = document.Pages(1).Annotations(5) as PdfLoadedSoundAnnotation 'Set the pdfsound icon soundAnnotation.Icon = PdfSoundIcon.Speaker 'Save the document. document.Save("SoundAnnotation.pdf") document.Close(True); Represents the loaded text markup annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedTextMarkupAnnotation textMarkupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextMarkupAnnotation; //Sets the PDF text markup annotation type textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight //Sets the text markup color textMarkupAnnotation.TextMarkupColor=new PdfColor(Color.Blue); //Save the document. document.Save("TextMarkupAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim textMarkupAnnotation As PdfLoadedTextMarkupAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextMarkupAnnotation 'Sets the PDF text markup annotation type textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight 'Sets the text markup color textMarkupAnnotation.TextMarkupColor=New PdfColor(Color.Blue) 'Save the document. document.Save("TextMarkupAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class CrossTable Dictionary Type of the annotation Indicates the color. To indicate collection of rectagle bounds of annotation Indicate the border Dictionary Indicat the border style Initializes a new instance of the class. The dictionary. The cross table. The rectangle Sets the name of the field. New name of the field. Gets back color of the annotation. The back color. Saves an annotation . Flatten annotation Create appearance for annotation Draw Squiggly line Gets the annotation review history. /// The review history collection of the text markup annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfTextMarkupAnnotation PdfLoadedTextMarkupAnnotation markup = document.Pages[0].Annotations[0] as PdfLoadedTextMarkupAnnotation; //Get the review collection PdfLoadedPopupAnnotationCollection reviewCollection = markup.ReviewHistory; //save the document document.Save("TextMarkupAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfTextMarkupAnnotation Dim markup As PdfLoadedTextMarkupAnnotation = document.Pages(0).Annotations(0) 'Get the review collection Dim reviewCollection As PdfLoadedPopupAnnotationCollection = markup.ReviewHistory Next 'save the document document.Save("TextMarkupAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets the annotation comments history. The Comments collection of the text markup annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Load the existing PdfTextMarkupAnnotation PdfLoadedTextMarkupAnnotation markup = document.Pages[0].Annotations[0] as PdfLoadedTextMarkupAnnotation; //Get the comments collection PdfLoadedPopupAnnotationCollection commentsCollection = markup.Comments; //save the document document.Save("TextMarkupAnnotation.pdf"); //Close the docuemnt document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Load the existing PdfTextMarkupAnnotation Dim markup As PdfLoadedTextMarkupAnnotation = document.Pages(0).Annotations(0) 'Get the comments collection Dim commentsCollection As PdfLoadedPopupAnnotationCollection = markup.Comments Next 'save the document document.Save("TextMarkupAnnotation.pdf") 'Close the document. document.Close(True) Class Class Gets or sets the markup annotation Type. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedTextMarkupAnnotation textMarkupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextMarkupAnnotation; //Sets the PDF text markup annotation type textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight //Save the document. document.Save("TextMarkupAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim textMarkupAnnotation As PdfLoadedTextMarkupAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextMarkupAnnotation 'Sets the PDF text markup annotation type textMarkupAnnotation.TextMarkupAnnotationType=PdfTextMarkupAnnotationType.Highlight 'Save the document. document.Save("TextMarkupAnnotation.pdf") document.Close(True) Gets or sets the markup color //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedTextMarkupAnnotation textMarkupAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextMarkupAnnotation; //Sets the text markup color textMarkupAnnotation.TextMarkupColor=new PdfColor(Color.Blue); //Save the document. document.Save("TextMarkupAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim textMarkupAnnotation As PdfLoadedTextMarkupAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextMarkupAnnotation 'Sets the text markup color textMarkupAnnotation.TextMarkupColor=New PdfColor(Color.Blue) 'Save the document. document.Save("TextMarkupAnnotation.pdf") document.Close(True) Represents the loaded text web link annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedTextWebLinkAnnotation textWeblinkAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextWebLinkAnnotation; //Sets the text web link annotation URI textWeblinkAnnotation.Url="http://www.syncfusion.com"; //Save the document. document.Save("TextWebLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim textWeblinkAnnotation As PdfLoadedTextWebLinkAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextWebLinkAnnotation 'Sets the text web link annotation URI textWeblinkAnnotation.Url="http://www.syncfusion.com" 'Save the document. document.Save("TextWebLinkAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class Crosstable Gets the web link. Web link Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets or sets the Url. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedTextWebLinkAnnotation textWeblinkAnnotation = document.Pages[1].Annotations[5] as PdfLoadedTextWebLinkAnnotation; //Sets the text web link annotation URI textWeblinkAnnotation.Url="http://www.syncfusion.com"; //Save the document. document.Save("TextWebLinkAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim textWeblinkAnnotation As PdfLoadedTextWebLinkAnnotation = document.Pages(1).Annotations(5) as PdfLoadedTextWebLinkAnnotation 'Sets the text web link annotation URI textWeblinkAnnotation.Url="http://www.syncfusion.com" 'Save the document. document.Save("TextWebLinkAnnotation.pdf") document.Close(True) Represents the loaded unique resource identifier annotation class. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedUriAnnotation UriAnnotation = document.Pages[1].Annotations[5] as PdfLoadedUriAnnotation; //Sets the uri annotation URI UriAnnotation.Url="http://www.syncfusion.com"; //Save the document. document.Save("UriAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim UriAnnotation As PdfLoadedUriAnnotation = document.Pages(1).Annotations(5) as PdfLoadedUriAnnotation 'Sets the uri annotation URI UriAnnotation.Url="http://www.syncfusion.com" 'Save the document. document.Save("UriAnnotation.pdf") document.Close(True) Class Class Class Class Class Class Class Class Class CrossTable Indicates the unique resource identifier text. Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text Gets the unique resource identifier text The unique resource identifier text Gets or sets the unique resource identifier text of the annotation. //Load an existing document. PdfLoadedDocument document = new PdfLoadedDocument(@"..\..\Annotations.pdf"); //Gets the annotation from loaded document. PdfLoadedUriAnnotation UriAnnotation = document.Pages[1].Annotations[5] as PdfLoadedUriAnnotation; //Sets the uri annotation URI UriAnnotation.Url="http://www.syncfusion.com"; //Save the document. document.Save("UriAnnotation.pdf"); document.Close(true); 'Load an existing document. Dim document As New PdfLoadedDocument("..\..\Annotations.pdf") 'Gets the annotation from loaded document. Dim UriAnnotation As PdfLoadedUriAnnotation = document.Pages(1).Annotations(5) as PdfLoadedUriAnnotation 'Sets the uri annotation URI UriAnnotation.Url="http://www.syncfusion.com" 'Save the document. document.Save("UriAnnotation.pdf") document.Close(True) Represents the loaded web link annotation class. CrossTable Initializes a new instance of the class. The dictionary. The cross table. The rectangle The text The class used to represent a loaded widget annotations Internal cross table Internal Annotation flags Internal variable to store extended appearance. Internal variable to store border parameters. Internal variable to store appearance of the widget. Internal variable to store highlighting mode. Internal variable to store default appearance. Internal variable to store annotation's actions. Annotation's appearance. Internal variable to store alignment. Internal variable to store default appearance state value. Internal variable to store field's font. Initializes a new instance of the class. Highlightings the mode to string. The m_highlighting mode. String representation of the highlighting mode in Pdf suiatable format. Gets or sets the extended appearance. The represents extended appearance of the annotation Gets or sets the highlighting mode. The . Gets or sets the text alignment. The provides alignments of a text. Gets the actions of the annotation. The provides various actions. Gets or sets appearance of the annotation. Gets or sets default appearance name. The state of the appearance. Initializes a new instance of the class. The filename. Get or set the annotationcollection //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Initialize an instance of MemoryStream MemoryStream stream = new MemoryStream(); //Export selected annotation's data into Json format document.ExportAnnotations(stream, AnnotationDataFormat.Json, "Annotation.pdf", collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Initialize an instance of MemoryStream Dim stream As New MemoryStream() 'Export selected annotation's data into Json format document.ExportAnnotations(stream, AnnotationDataFormat.Json, "Annotation.pdf", collection) 'Close and dispose the document document.Close(true) document.Dispose() Represents a button field of an existing PDF document. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the form PdfLoadedForm form = doc.Form; // Load an existing button field. PdfLoadedButtonField buttonField = form.Fields["Submit"] as PdfLoadedButtonField; buttonField.ToolTip = "SubmitButton"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the form Dim form As PdfLoadedForm = doc.Form ' Load an existing button field. Dim buttonField As PdfLoadedButtonField = TryCast(form.Fields("Submit"), PdfLoadedButtonField) buttonField.ToolTip = "SubmitButton" doc.Save("Form.pdf") doc.Close(True) Class Class Represents loaded styled field. Class //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Represents base class for loaded fields. //Create a new document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form fields foreach (PdfLoadedField field in doc.Form.Fields) { // Flatten the form field.Flatten = true; } doc.Save("Form.pdf"); doc.Close(true); 'Create a new document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form fields For Each field As PdfLoadedField In doc.Form.Fields ' Flatten the form field.Flatten = True Next field doc.Save("Form.pdf") doc.Close(True) Class Form field identifier Cross Table. Indicates was field changed or not. Indicates was Form field changed or not for fore color, backcolor property has changed. Represents index used to default annotation. Represent's the field name. Represent's the field page. Internal variable to store form. Initializes a new instance of the class. The dictionary. The cross table. Sets the name of the field. New name of the field. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; // Sets new name of the first field field.SetName("fieldFirstName"); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) ' Sets new name of the first field field.SetName("fieldFirstName") doc.Save("Form.pdf") doc.Close(True) Searches the in parents. The dictionary. The cross table. The value. Searched primitive. Gets the value. The dictionary. The cross table. The value. if it is inheritable, set to true. The founded value. Gets the widget annotation. The dictionary. The cross table. The widget annotation dictionary. Get the annotation widget dictionary. Gets the high light. The dictionary. The cross table. The HighLIght mode. Draws this instance if it is flatten. Creates a copy of loaded field item. Applies field name specified field name Begins the save. Gets the loaded page. The loaded page in which field draw. Exports the form fields. Exports the form fields. Get the export value for radio button, check box and button fields Exports the form fields. Stream. Object identifier. Imports the form fields. Validates the string. The text1. Gets the name of the field. Raises when user manually changes the name of the field. Gets the name of the field.[Read-Only] A string value specifying the name of the field. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; // Read the field name String fieldName = field.Name; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) ' Read the field name Dim fieldName As String = field.Name doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets the mapping name to be used when exporting interactive form field data from the document. A string value specifying the mapping name of the field. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; // Sets the Mapping name as 'FirstField' field.MappingName = "FirstField"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) ' Sets the Mapping name as 'FirstField' field.MappingName = "FirstField" doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets the tool tip of the form field. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; // Sets the tooltip of the field field.ToolTip = "FirstField"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) ' Sets the tooltip of the field field.ToolTip = "FirstField" doc.Save("Form.pdf") doc.Close(True) Class Class Gets the page of the form field.[Read-Only] //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; PdfPageBase page = field.Page; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) Dim page As PdfPageBase = field.Page doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets a value indicating whether [read-only]. True if the field is read-only, false otherwise. Default is false. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; // Set the form field as read only field.ReadOnly = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) ' Set the form field as read only field.ReadOnly = True doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets a value indicating whether this is required. True if the field is required, false otherwise. Default is false. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; field.Required = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) field.Required = True doc.Save("Form.pdf") doc.Close(True) Gets or sets a value indicating whether this is export. true if export; otherwise, false. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; field.Export = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) field.Export = True doc.Save("Form.pdf") doc.Close(True) Gets or sets the flags. Gets the actual field name. This returns the field name alone, where Name property returns the field name along with its parent name. Gets the form of the .[Read-Only] //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form field PdfLoadedField field = doc.Form.Fields[0] as PdfLoadedField; PdfForm form = field.Form; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form field Dim field As PdfLoadedField = TryCast(doc.Form.Fields(0), PdfLoadedField) Dim form As PdfForm = field.Form doc.Save("Form.pdf") doc.Close(True) Gets or sets the cross table. Gets the parent. The parent. Gets or sets the changed. Gets or sets the field changed for fore color, backcolor property has changed. Gets or sets the index of the default. NameChanged event handler. New name of the field. Internal variable to store color shift value. Internal variable to store Pdf Field Actions. Internal variable to store widget of the field. Internal variable to store enter action. Internal variable to store leave action. Internal variable to store mouse down action. Internal variable to store mouse up action. Internal variable to store get focus action. Internal variable to store lost focus action. Internal variable to store border pen. Internal variable to store field's font. Represents the visibility of the field Internal variable to store rotation value. Internal variable to recreate rotation appearance. Initializes a new instance of the class. The dictionary. The cross table. Gets the graphics properties. The graphics properties. The item. Creates the border style. The bs. The border style. Sets the border style. The bs. The border style. Gets border pen. The border style. Set the back color of the Field. PdfColor Value. Gets the bounds. The dictionary. The cross table. The bounds. Gets the high light string. The mode. The highligt mode. Creates the color. The array. Gets the font colour. The default appearance. The colour of the text value. Parses the float. The text. Reading Font Name from Dictionary. Create metrics for embed font Gets the font by its name. The name. The height of the resulting font. The proper font object. Gets the font style. The font family string. The style of pdf font. Gets the font name font name Gets the font family. The font family string. The font family. Gets the Back Color of the field. Back color of the field. Gets the border style. Border style of the field. Gets DashPatern. The DashPatern. Gets border width. The boder width. Sets border width. Gets string format. The string format. Gets back brush. The back brush. Sets the back color of the Field. The brush. Gets fore brush. The fore brush. Gets shadow brush. The shadow brush. Draws this instance if it is flatten. Creates a copy of loaded field item. Begins the save. Gets the height of the font. The calculated size of font. Gets border pen. The border style. Gets the field's annotation. The array of fields annotations. Gets the visibility of the field. Creates the border pen. Defines the default appearance. Gets the checkbox style. checkbox style of the field. Create the checkbox style. Sets the CheckBox style. The bs. The CheckBox style. Styles to string. The style. String representation of the check box' style. Cloning the PdfLoadedStyledField. Gets the font. The font string. Gets or sets the action to be performed when the cursor enters the annotation�s active area. The mouse enter action. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Create a new PDF java script action instance. PdfJavaScriptAction action = new PdfJavaScriptAction("getField(\"fn\").value=\"Mouse Entered\";"); //Set the mouse enter event. ldField.MouseEnter = action; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Create a new PDF java script action instance. Dim action As New PdfJavaScriptAction("getField(""fn"").value=""Mouse Entered"";") 'Set the mouse enter event. ldField.MouseEnter = action 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the action to be performed when the mouse button is released inside the annotation�s active area. The mouse up action. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Create a new PDF java script action instance. PdfJavaScriptAction action = new PdfJavaScriptAction("getField(\"fn\").value=\"Mouse Up\";"); //Set the event. ldField.MouseUp = action; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Create a new PDF java script action instance. Dim action As New PdfJavaScriptAction("getField(""fn"").value=""Mouse Up"";") 'Set the event. ldField.MouseUp = action 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the action to be performed when the mouse button is pressed inside the annotation�s active area. The mouse down action. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Create a new PDF java script action instance. PdfJavaScriptAction action = new PdfJavaScriptAction("getField(\"fn\").value=\"Mouse Down\";"); //Set the event. ldField.MouseDown = action; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Create a new PDF java script action instance. Dim action As New PdfJavaScriptAction("getField(""fn"").value=""Mouse Down"";") 'Set the event. ldField.MouseDown = action 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the action to be performed when the cursor exits the annotation�s active area. The mouse leave action. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Create a new PDF java script action instance. PdfJavaScriptAction action = new PdfJavaScriptAction("getField(\"fn\").value=\"Mouse Leave\";"); //Set the event. ldField.MouseLeave = action; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Create a new PDF java script action instance. Dim action As New PdfJavaScriptAction("getField(""fn"").value=""Mouse Leave"";") 'Set the event. ldField.MouseLeave = action 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the action to be performed when the annotation receives the input focus. The got focus action. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Create a new PDF java script action instance. PdfJavaScriptAction action = new PdfJavaScriptAction("getField(\"fn\").value=\"Field Focused\";"); //Set the event. ldField.GotFocus = action; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Create a new PDF java script action instance. Dim action As New PdfJavaScriptAction("getField(""fn"").value=""Field Focused"";") 'Set the event. ldField.GotFocus = action 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets and Sets the fore color of the Field The color of the text. Gets or sets the action to be performed when the annotation loses the input focus. The lost focus action. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Create a new PDF java script action instance. PdfJavaScriptAction action = new PdfJavaScriptAction("getField(\"fn\").value=\"Lost Focus\";"); //Set the event. ldField.LostFocus = action; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Create a new PDF java script action instance. Dim action As New PdfJavaScriptAction("getField(""fn"").value=""Lost Focus"";") 'Set the event. ldField.LostFocus = action 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets the widget. The widget. Gets or sets the bounds. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields bounds. ldField.Bounds = new RectangleF(100, 300, 100, 30); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields bounds. ldField.Bounds = New RectangleF(100, 300, 100, 30) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the location. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset fields location. ldField.Location = new PointF(100, 300); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset fields location. ldField.Location = New PointF(100, 300) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the size. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Reset size of the field. ldField.Size = new SizeF(200, 30); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Reset size of the field. ldField.Size = New SizeF(200, 30) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets the border pen. Gets or sets the style of the border. The color of the border. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Set border width. ldField.BorderWidth = 1; //Set border color. ldField.BorderColor = Color.Red; //Set border style. ldField.BorderStyle = PdfBorderStyle.Dashed; doc.Form.SetDefaultAppearance(false); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Set border width. ldField.BorderWidth = 1 'Set border color. ldField.BorderColor = Color.Red 'Set border style. ldField.BorderStyle = PdfBorderStyle.Dashed doc.Form.SetDefaultAppearance(False) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the color of the border. The color of the border. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Set border width. ldField.BorderWidth = 1; //Set border color. ldField.BorderColor = Color.Red; //Set border style. ldField.BorderStyle = PdfBorderStyle.Dashed; doc.Form.SetDefaultAppearance(false); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Set border width. ldField.BorderWidth = 1 'Set border color. ldField.BorderColor = Color.Red 'Set border style. ldField.BorderStyle = PdfBorderStyle.Dashed doc.Form.SetDefaultAppearance(False) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets the DashPatern. Gets or Sets the width of the border. The width of the border. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Set border width. ldField.BorderWidth = 1; //Set border color. ldField.BorderColor = Color.Red; //Set border style. ldField.BorderStyle = PdfBorderStyle.Dashed; doc.Form.SetDefaultAppearance(false); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Set border width. ldField.BorderWidth = 1 'Set border color. ldField.BorderColor = Color.Red 'Set border style. ldField.BorderStyle = PdfBorderStyle.Dashed doc.Form.SetDefaultAppearance(False) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets the string format. The string format. Gets the back brush. The back brush. Gets the color of the fore. The color of the fore. Gets the shadow brush. The shadow brush. Gets or set the font. The font. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Set font. ldField.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12, PdfFontStyle.Italic); doc.Form.SetDefaultAppearance(false); //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Set font. ldField.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12, PdfFontStyle.Italic) doc.Form.SetDefaultAppearance(False) 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or set the default index. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; //Set default index. ldField.DefaultIndex = 2; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) 'Set default index. ldField.DefaultIndex = 2 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets the kids. Gets a value indicating the visibility of the field.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; bool isVisible = ldField.Visible; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) Dim isVisible As Boolean = ldField.Visible 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets the form field visibility //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.Visibility = PdfFormFieldVisibility.Hidden; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.Visibility = PdfFormFieldVisibility.Hidden 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Structure that holds graphics properties. Indicates bounds of the field. Indicates border color of the field. Indicates border style of the field. Indicates border width of the field. Indicates back brush color of the field. Indicates fore brush color of the field. Indicates shasow brush color of the field. Indicates font of the field. Indicates string format of the field. Indicates rotation angle of the field. Initializes a new instance of the struct. The field. Initializes a new instance of the struct. The item. Collection of button items. Initializes a new instance of the class. The dictionary. The cross table. Gets the text. The text of the field. Sets the text of the field. Text field. Draws this instance if it is flatten. Begins the save. Creates a copy of PdfLoadedButton field. Creates a copy of PdfLoadedButton field. Creates a copy of PdfLoadedButtonItem. Applies the appearance. The widget. The item. Draws the button. The graphics. The item. Gets the height of the font. The calculated size of font. Adds Print action to current button field. Clicking on the specified button will trigger the Print Dialog Box. //Load an existing document PdfLoadedDocument ldoc = new PdfLoadedDocument("SourceDoc.pdf"); // Load the existing form PdfLoadedForm form = ldoc.Form; // Load an existing button field. PdfLoadedButtonField buttonField = form.Fields["Submit"] as PdfLoadedButtonField; // Adding print action buttonField.AddPrintAction(); // Save the document to a disk ldoc.Save("Form.pdf"); ldoc.Close(true); 'Load an existing document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") ' Load the existing form Dim form As PdfLoadedForm = ldoc.Form ' Load an existing button field. Dim buttonField As PdfLoadedButtonField = TryCast(form.Fields("Submit"), PdfLoadedButtonField) ' Adding print action buttonField.AddPrintAction() ' Save the document to a disk ldoc.Save("Form.pdf") ldoc.Close(True) Gets or sets the complex script language support. //Load existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("form.pdf"); //Load the existing button box field. PdfLoadedButtonField button = lfied as PdfLoadedButtonField; //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Set font. button.Font = pdfFont; //Enable complex script support. button.ComplexScript = true; ldoc.Form.SetDefaultAppearance(false); //Save the document. ldoc.Save("output.pdf"); //Close the document. ldoc.Close(true); 'Load existing PDF document. Dim ldoc As New PdfLoadedDocument("form.pdf") 'Load the existing button box field. Dim button As PdfLoadedButtonField = TryCast(ldoc.Form.Fields(0), PdfLoadedButtonField) 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Set font. button.Font = pdfFont 'Enable complex script support. button.ComplexScript = True ldoc.Form.SetDefaultAppearance(False) 'Save the document. ldoc.Save("output.pdf") 'Close the document. ldoc.Close(True) Gets or sets the caption text. A string value specifying the caption of the button. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the form PdfLoadedForm form = doc.Form; // Load an existing button field. PdfLoadedButtonField buttonField = form.Fields["Submit"] as PdfLoadedButtonField; buttonField.Text = "Submit"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the form Dim form As PdfLoadedForm = doc.Form ' Load an existing button field. Dim buttonField As PdfLoadedButtonField = TryCast(form.Fields("Submit"), PdfLoadedButtonField) buttonField.Text = "Submit" doc.Save("Form.pdf") doc.Close(True) Class Class Gets the collection of button items.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Reading button collection item PdfLoadedButtonItemCollection buttonCollection = buttonField.Items; // Load an existing button item PdfLoadedButtonItem buttonItem = buttonCollection[0]; buttonItem.Bounds = new RectangleF(0, 0, 20, 30); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Reading button collection item Dim buttonCollection As PdfLoadedButtonItemCollection = buttonField.Items ' Load an existing button item Dim buttonItem As PdfLoadedButtonItem = buttonCollection(0) buttonItem.Bounds = New RectangleF(0, 0, 20, 30) doc.Save("Form.pdf") doc.Close(True) Class Class Represents button group item of an existing PDF document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button item PdfLoadedButtonItem buttonItem = buttonField.Items[0]; buttonItem.Bounds = new RectangleF(0, 0, 20, 30); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button item Dim buttonItem As PdfLoadedButtonItem = buttonField.Items(0) buttonItem.Bounds = New RectangleF(0, 0, 20, 30) doc.Save("Form.pdf") doc.Close(True) Class Class Represents base class for field's group items. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button item PdfLoadedButtonItem buttonItem = buttonField.Items[0]; buttonItem.Bounds = new RectangleF(0, 0, 20, 30); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button item Dim buttonItem As PdfLoadedButtonItem = buttonField.Items(0) buttonItem.Bounds = New RectangleF(0, 0, 20, 30) doc.Save("Form.pdf") doc.Close(True) Field which item belongs to. Item index in collection. Local variable to hold page reference. Initializes a new instance of the class. The field. The index. The dictionary. Get the current Loaded style Field. Gets the parent. Gets the cross table. Gets the dictionary. Gets or sets the bounds. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button item PdfLoadedButtonItem buttonItem = buttonField.Items[0]; buttonItem.Bounds = new RectangleF(0, 0, 20, 30); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button item Dim buttonItem As PdfLoadedButtonItem = buttonField.Items(0) buttonItem.Bounds = New RectangleF(0, 0, 20, 30) doc.Save("Form.pdf") doc.Close(True) Gets or sets the location of the field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button item PdfLoadedButtonItem buttonItem = buttonField.Items[0]; buttonItem.Location = new PointF(100, 100); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button item Dim buttonItem As PdfLoadedButtonItem = buttonField.Items(0) buttonItem.Location = New PointF(100, 100) doc.Save("Form.pdf") doc.Close(True) Gets or sets the size of the field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button item PdfLoadedButtonItem buttonItem = buttonField.Items[0]; buttonItem.Size = new SizeF(100, 30); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button item Dim buttonItem As PdfLoadedButtonItem = buttonField.Items(0) buttonItem.Size = New SizeF(100, 30) doc.Save("Form.pdf") doc.Close(True) Gets the border pen. Gets the border style. Gets the DashPatern. Gets the width of the border. Gets the string format. Gets the back brush. Gets the color of the fore. Gets the shadow brush. Gets the font. Gets the page of the field.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button item PdfLoadedButtonItem buttonItem = buttonField.Items[0]; //Get the fields page. PdfPageBase page = buttonItem.Page; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button item Dim buttonItem As PdfLoadedButtonItem = buttonField.Items(0) 'Get the fields page. Dim page As PdfPageBase = buttonItem.Page doc.Save("Form.pdf") doc.Close(True) Initializes a new instance of the class. The field. The index. The dictionary. Cloning the PdfLoadedButtonItem. Represents collection of button item. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the form PdfLoadedForm form = doc.Form; // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button collection PdfLoadedButtonItemCollection buttonCollection = buttonField.Items; // Load an existing button button item PdfLoadedButtonItem buttonItem = buttonCollection[0]; buttonItem.Bounds = new RectangleF(0, 0, 20, 30); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the form Dim form As PdfLoadedForm = doc.Form ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button collection Dim buttonCollection As PdfLoadedButtonItemCollection = buttonField.Items ' Load an existing button button item Dim buttonItem As PdfLoadedButtonItem = buttonCollection(0) buttonItem.Bounds = New RectangleF(0, 0, 20, 30) doc.Save("Form.pdf") doc.Close(True) Class Class Class Adds the specified item. The item. Cloning the PdfLoadedButtonItemCollection Gets the at the specified index.[Read-Only] //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the form PdfLoadedForm form = doc.Form; // Load an existing button field PdfLoadedButtonField buttonField = doc.Form.Fields["Submit"] as PdfLoadedButtonField; // Load an existing button collection PdfLoadedButtonItemCollection buttonCollection = buttonField.Items; // Load an existing button button item PdfLoadedButtonItem buttonItem = buttonCollection[0]; buttonItem.Bounds = new RectangleF(0, 0, 20, 30); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the form Dim form As PdfLoadedForm = doc.Form ' Load an existing button field Dim buttonField As PdfLoadedButtonField = TryCast(doc.Form.Fields("Submit"), PdfLoadedButtonField) ' Load an existing button collection Dim buttonCollection As PdfLoadedButtonItemCollection = buttonField.Items ' Load an existing button button item Dim buttonItem As PdfLoadedButtonItem = buttonCollection(0) buttonItem.Bounds = New RectangleF(0, 0, 20, 30) doc.Save("Form.pdf") doc.Close(True) Class Class Represents check box of an existing PDF document. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedCheckBoxField checkField = doc.Form.Fields["Java"] as PdfLoadedCheckBoxField; checkField.Checked = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'Load an existing Check field Dim checkField As PdfLoadedCheckBoxField = TryCast(doc.Form.Fields("Java"), PdfLoadedCheckBoxField) checkField.Checked = True doc.Save("Form.pdf") doc.Close(True) Class Class Represents the base class for loaded state field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Flatten the radio button field radiobuttonField.Flatten = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Flatten the radio button field radiobuttonField.Flatten = True doc.Save("LoadedForm.pdf") doc.Close(True) Class Initializes a new instance of the class. The dictionary. The cross table. Gets the item. The index. The item dictionary. The proper state item. Gets the state template. The state. The item. The proper PdfTemplate instance. Sets checked status of the field. Checked status. Gets the item value. The value of the item. Unchecks the others kids. The child. The value. Applies the appearance. The widget. The item. Draws the check box item. The graphics. The state. The item. Gets the items collection.[Read-Only] Class //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Radio button field collection PdfLoadedRadioButtonItemCollection radiobuttonFieldCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonFieldCollection[0]; // Set the first item as selected item radiobuttonItem.Selected = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Radio button field collection Dim radiobuttonFieldCollection As PdfLoadedRadioButtonItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonFieldCollection(0) ' Set the first item as selected item radiobuttonItem.Selected = True doc.Save("Form.pdf") doc.Close(True) Symbol for check state. Initializes a new instance of the class. The dictionary. The cross table. Gets the item. The index. The item dictionary. The proper state item. Draws this instance if it is flatten. Begins the save. Creates a copy of PdfLoadedCheckBoxField. Creates a copy of PdfLoadedCheckBoxField. Creates a copy of PdfLoadedCheckBoxItem. Get the PdfLoadedCheckBoxItem using export value from PdfLoadedCheckBoxField //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //Load an existing Check field PdfLoadedCheckBoxField checkField = doc.Form.Fields["Java"] as PdfLoadedCheckBoxField; PdfLoadedCheckBoxItem checkBoxItem = null; //Get checkbox item using an export value checkField.TryGetFieldItem("3", out checkBoxItem); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'Load an existing Check field Dim checkField As PdfLoadedCheckBoxField = TryCast(doc.Form.Fields("Java"), PdfLoadedCheckBoxField) 'Get checkbox item using an export value Dim checkBoxItem As PdfLoadedCheckBoxItem = Nothing checkField.TryGetFieldItem("3", checkBoxItem) doc.Save("Form.pdf") doc.Close(True) Gets or sets a value indicating whether this is checked. True if the check box is checked, false otherwise. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedCheckBoxField checkField = doc.Form.Fields["Java"] as PdfLoadedCheckBoxField; checkField.Checked = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim checkField As PdfLoadedCheckBoxField = TryCast(doc.Form.Fields("Java"), PdfLoadedCheckBoxField) checkField.Checked = True doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets the back color of the field Gets or sets the fore color of the field. Gets or sets the checkbox style of the field. Gets the collection of check box items.[Read-Only] //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedCheckBoxField checkField = doc.Form.Fields["Java"] as PdfLoadedCheckBoxField; // Loads the check box items collection. PdfLoadedCheckBoxItemCollection checkCollection = checkField.Items; checkCollection[0].Checked = false; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim checkField As PdfLoadedCheckBoxField = TryCast(doc.Form.Fields("Java"), PdfLoadedCheckBoxField) ' Loads the check box items collection. Dim checkCollection As PdfLoadedCheckBoxItemCollection = checkField.Items checkCollection(0).Checked = False doc.Save("Form.pdf") doc.Close(True) Class Class Represents collection of text box group items. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedCheckBoxField checkField = doc.Form.Fields["Java"] as PdfLoadedCheckBoxField; // Loads the check box items collection. PdfLoadedCheckBoxItemCollection checkCollection = checkField.Items; checkCollection[0].Checked = false; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim checkField As PdfLoadedCheckBoxField = TryCast(doc.Form.Fields("Java"), PdfLoadedCheckBoxField) ' Loads the check box items collection. Dim checkCollection As PdfLoadedCheckBoxItemCollection = checkField.Items checkCollection(0).Checked = False doc.Save("Form.pdf") doc.Close(True) Class Class Class Represents the collection of loaded state item. Class //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // State Item collection PdfLoadedStateItemCollection stateItemCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = stateItemCollection[0] as PdfLoadedRadioButtonItem; // Selected the item radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' State Item collection Dim stateItemCollection As PdfLoadedStateItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = TryCast(stateItemCollection(0), PdfLoadedRadioButtonItem) ' Selected the item radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Index of the specified item. The item. The index of specified item Adds the specified item. The item. Cloning the PdfLoadedStateItemCollection. Gets the at the specified index.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // State Item collection PdfLoadedStateItemCollection stateItemCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = stateItemCollection[0] as PdfLoadedRadioButtonItem; // Selected the item radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' State Item collection Dim stateItemCollection As PdfLoadedStateItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = TryCast(stateItemCollection(0), PdfLoadedRadioButtonItem) ' Selected the item radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Index of the specified item. The item. The index of specified item Adds the specified item. The item. Cloning the PdfLoadedCheckBoxItemCollection Gets the at the specified index.[Read-Only] //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedCheckBoxField checkField = doc.Form.Fields["Java"] as PdfLoadedCheckBoxField; // Loads the check box items collection. PdfLoadedCheckBoxItemCollection checkCollection = checkField.Items; checkCollection[0].Checked = false; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim checkField As PdfLoadedCheckBoxField = TryCast(doc.Form.Fields("Java"), PdfLoadedCheckBoxField) ' Loads the check box items collection. Dim checkCollection As PdfLoadedCheckBoxItemCollection = checkField.Items checkCollection(0).Checked = False doc.Save("Form.pdf") doc.Close(True) Represents loaded check box item. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedCheckBoxField checkField = doc.Form.Fields["Java"] as PdfLoadedCheckBoxField; // Loads the check box items collection. PdfLoadedCheckBoxItemCollection checkCollection = checkField.Items; // Read the first item of the collection PdfLoadedCheckBoxItem checkItem = checkCollection[0]; checkItem.Checked = false; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim checkField As PdfLoadedCheckBoxField = TryCast(doc.Form.Fields("Java"), PdfLoadedCheckBoxField) ' Loads the check box items collection. Dim checkCollection As PdfLoadedCheckBoxItemCollection = checkField.Items ' Read the first item of the collection Dim checkItem As PdfLoadedCheckBoxItem = checkCollection(0) checkItem.Checked = False doc.Save("Form.pdf") doc.Close(True) Class Class Class Represents the loaded state item. Class //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // State Item collection PdfLoadedStateItemCollection stateItemCollection = radiobuttonField.Items; PdfLoadedStateItem stateItem =stateItemCollection[0]; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = stateItem as PdfLoadedRadioButtonItem; // Selected the item radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' State Item collection Dim stateItemCollection As PdfLoadedStateItemCollection = radiobuttonField.Items Dim stateItem As PdfLoadedStateItem = stateItemCollection(0) ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = TryCast(stateItem, PdfLoadedRadioButtonItem) ' Selected the item radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Initializes a new instance of the class. The field. The index. The dictionary. Sets checked status of the field. Checked status. Gets the Back Color of the field. Back color of the field. Creates the color. The array. Gets or sets a value indicating whether this is checked. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // State Item collection PdfLoadedStateItemCollection stateItemCollection = radiobuttonField.Items; PdfLoadedStateItem stateItem =stateItemCollection[0]; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = stateItem as PdfLoadedRadioButtonItem; // Selected the item radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' State Item collection Dim stateItemCollection As PdfLoadedStateItemCollection = radiobuttonField.Items Dim stateItem As PdfLoadedStateItem = stateItemCollection(0) ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = TryCast(stateItem, PdfLoadedRadioButtonItem) ' Selected the item radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Gets or sets the back color of the field. Gets or sets the fore color of the field. Initializes a new instance of the class. The field. The index. The dictionary. Sets checked status of the field. Checked status. Cloning the PdfLoadedCheckBoxItem. Represents a choice field of an existing PDF document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing choice field PdfLoadedChoiceField choiceField = doc.Form.Fields["Java"] as PdfLoadedChoiceField; choiceField.SelectedIndex = 0; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim choiceField As PdfLoadedChoiceField = TryCast(doc.Form.Fields("Java"), PdfLoadedChoiceField) choiceField.SelectedIndex = 0 doc.Save("Form.pdf") doc.Close(True) Class Class Initializes a new instance of the class. The dictionary. The cross table. Gets selected index. Selected index. Sets selected index. Selected index. Gets selected value. Selected value. Sets selected value. Selected value. Gets the list item. The list item collection Gets the collection of choice items.[Read-Only] A object specifying the selected item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedChoiceField choiceField = doc.Form.Fields["Java"] as PdfLoadedChoiceField; // Change the selected item PdfLoadedListItemCollection items = choiceField.SelectedItem; items[0].Text = "New Text"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim choiceField As PdfLoadedChoiceField = TryCast(doc.Form.Fields("Java"), PdfLoadedChoiceField) ' Change the selected item Dim items As PdfLoadedListItemCollection = choiceField.SelectedItem items(0).Text = "New Text" doc.Save("Form.pdf") doc.Close(True) Gets or sets the first selected item in the list. An integer value specifying the choice item in the list. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing choice field PdfLoadedChoiceField choiceField = doc.Form.Fields["Java"] as PdfLoadedChoiceField; choiceField.SelectedIndex = new int[] { 0 }; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim choiceField As PdfLoadedChoiceField = TryCast(doc.Form.Fields("Java"), PdfLoadedChoiceField) choiceField.SelectedIndex = New Integer() {0} doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets the value of the first selected item in the list. A string value specifying the value of the selected item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing choice field PdfLoadedChoiceField choiceField = doc.Form.Fields["Java"] as PdfLoadedChoiceField; choiceField.SelectedValue = new string[] { "Employee" }; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing choice field Dim choiceField As PdfLoadedChoiceField = TryCast(doc.Form.Fields("Java"), PdfLoadedChoiceField) choiceField.SelectedValue = New String() { "Employee" } doc.Save("Form.pdf") doc.Close(True) Class Class Gets the selected items in the list.[Read-Only] A object specifying the selected item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing Check field PdfLoadedChoiceField choiceField = doc.Form.Fields["Java"] as PdfLoadedChoiceField; // Change the selected item PdfLoadedListItemCollection items = choiceField.SelectedItem; items[0].Text = "New Text"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing Check field Dim choiceField As PdfLoadedChoiceField = TryCast(doc.Form.Fields("Java"), PdfLoadedChoiceField) ' Change the selected item Dim items As PdfLoadedListItemCollection = choiceField.SelectedItem items(0).Text = "New Text" doc.Save("Form.pdf") doc.Close(True) Class Class Get or sets the back color of the field Gets or sets the fore color of the field. Represents the combo box field of an existing item. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read a combo box field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; comboField.SelectedIndex = 0; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'Read a combo box field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) comboField.SelectedIndex = 0 doc.Save("Form.pdf") doc.Close(True) Class Stores the collection of items. Initializes a new instance of the class. The dictionary. The cross table. Draws this instance if it is flatten. Begins the save. Creates a copy of PdfLoadedComboBoxField. Creates a copy of PdfLoadedComboBoxField. Creates a copy of PdfLoadedComboBoxItem. Applies the appearance. The widget. The item. Draws the combo box. The graphics. The item. Draws the combo box. The graphics. The item. Gets the height of the font. The calculated size of font. Gets or sets the complex script language support. //Load existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("form.pdf"); //Load the existing combo box field. PdfLoadedComboBoxField combo = lfied as PdfLoadedComboBoxField; //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Set font. combo.Font = pdfFont; //Enable complex script support. combo.ComplexScript = true; ldoc.Form.SetDefaultAppearance(false); //Save the document. ldoc.Save("output.pdf"); //Close the document. ldoc.Close(true); 'Load existing PDF document. Dim ldoc As New PdfLoadedDocument("form.pdf") 'Load the existing combo box field. Dim combo As PdfLoadedComboBoxField = TryCast(ldoc.Form.Fields(0), PdfLoadedComboBoxField) 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Set font. combo.Font = pdfFont 'Enable complex script support. combo.ComplexScript = True ldoc.Form.SetDefaultAppearance(False) 'Save the document. ldoc.Save("output.pdf") 'Close the document. ldoc.Close(True) check whether the combo box field is autosize. Gets or sets a value indicating whether this is editable. True if the drop down list is editable, false otherwise. Default is false. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing combo field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; comboField.Editable = false; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'Load an existing Check field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) comboField.Editable = False doc.Save("Form.pdf") doc.Close(True) Class Class Gets the collection of combo box items.[Read-Only] //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing combo field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; // Load combo field collection PdfLoadedComboBoxItemCollection comboCollection = comboField.Items; // Reading first item of the collection. PdfLoadedComboBoxItem item = comboCollection[0]; item.Location = new PointF(200, 200); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'Load an existing combo field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) 'Load combo field collection Dim comboCollection As PdfLoadedComboBoxItemCollection = comboField.Items 'Reading first item of the collection. Dim item As PdfLoadedComboBoxItem = comboCollection(0) item.Location = New PointF(200, 200) doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets the index which is to be selected. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read a combo box field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; comboField.SelectedIndex = 0; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'Read a combo box field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) comboField.SelectedIndex = 0 doc.Save("Form.pdf") doc.Close(True) Gets or sets the value which is to be selected. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read a combo box field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; comboField.SelectedValue = "Employee"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'Read a combo box field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) comboField.SelectedValue = "Employee" doc.Save("Form.pdf") doc.Close(True) Represents group for combo box field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing combo field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; // Load combo field collection PdfLoadedComboBoxItemCollection comboCollection = comboField.Items; // Load combo field item PdfLoadedComboBoxItem comboItem = comboCollection[0]; comboItem.Bounds = new RectangleF(10,20,200,300); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing combo field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) ' Load combo field collection Dim comboCollection As PdfLoadedComboBoxItemCollection = comboField.Items ' Load combo field item Dim comboItem As PdfLoadedComboBoxItem = comboCollection(0) comboItem.Bounds = New RectangleF(10,20,200,300) doc.Save("Form.pdf") doc.Close(True) Class Initializes a new instance of the class. The field. The index. The dictionary. Cloning PdfLoadedComboBoxItem. Represents collection of Combo box items. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing combo field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; // Load combo field collection PdfLoadedComboBoxItemCollection comboCollection = comboField.Items; // Load combo field item PdfLoadedComboBoxItem comboItem = comboCollection[0]; comboItem.Bounds = new RectangleF(10,20,200,300); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing combo field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) ' Load combo field collection Dim comboCollection As PdfLoadedComboBoxItemCollection = comboField.Items ' Load combo field item Dim comboItem As PdfLoadedComboBoxItem = comboCollection(0) comboItem.Bounds = New RectangleF(10,20,200,300) doc.Save("Form.pdf") doc.Close(True) Class Class Class Cloning PdfLoadedComboBoxItemCollection. Gets the at the specified index.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load an existing combo field PdfLoadedComboBoxField comboField = doc.Form.Fields["EmployeeCombo"] as PdfLoadedComboBoxField; // Load combo field collection PdfLoadedComboBoxItemCollection comboCollection = comboField.Items; // Load combo field item PdfLoadedComboBoxItem comboItem = comboCollection[0]; comboItem.Bounds = new RectangleF(10,20,200,300); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load an existing combo field Dim comboField As PdfLoadedComboBoxField = TryCast(doc.Form.Fields("EmployeeCombo"), PdfLoadedComboBoxField) ' Load combo field collection Dim comboCollection As PdfLoadedComboBoxItemCollection = comboField.Items ' Load combo field item Dim comboItem As PdfLoadedComboBoxItem = comboCollection(0) comboItem.Bounds = New RectangleF(10,20,200,300) doc.Save("Form.pdf") doc.Close(True) Class Class Class Represents a collection of state items. Class Index of the specified item. The item. The index of specified item Adds the specified item. The item. Gets the at the specified index.[Read-Only] The index of specified item. Represents Loaded form of the PDF document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; //load the form field PdfLoadedField field = form.Fields[0] as PdfLoadedField; field.Export = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'load the form field Dim field As PdfLoadedField = TryCast(form.Fields(0), PdfLoadedField) field.Export = True doc.Save("Form.pdf") doc.Close(True) Class Class Collection of fields Export and import of form fields Store crooss table. Dictionaries of tremil fields. Indicates is field modified or not. Indicates is xfa form or not. Indicates Extended feature. Initializes a new instance of the class. The form dictionary. The cross table. Initializes a new instance of the class. The cross table. Get the field Find the given document contain extended feature dictionary. Initializes the specified form dictionary. The form dictionary. The cross table. Retrieves the terminal fields. Determines whether the specified kids is node. The kids. true if the specified kids is node; otherwise, false. Export the form data to a file with the specific and form name. Name of the document which is need to export. The format of exported data. The name of the PDF file the data is exported from. // Loads an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; form.ExportData("Export.xml", DataFormat.Xml, "SourceForm.pdf"); doc.Close(true); ' Loads an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form form.ExportData("Export.xml", DataFormat.Xml, "SourceForm.pdf") doc.Close(True) Export the form data to a file with specified ExportFormSettings. // Loads an existing document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("../../Data/ChineseValue.pdf"); // Load an existing form PdfLoadedForm loadedForm = loadedDocument.Form; //Create new instance for export form settings. ExportFormSettings settings = new ExportFormSettings(); //Gets or sets the data format to export form fields. settings.DataFormat = DataFormat.Fdf; //Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname"; //Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings); //Save the PDF document loadedDocument.Save("ChineseValue.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("../../Data/ChineseValue.pdf") 'Load an existing form Dim loadedForm As PdfLoadedForm = loadedDocument.Form 'Create new instance for export form settings. Dim settings As ExportFormSettings = New ExportFormSettings() 'Gets or sets the data format to export form fields. settings.DataFormat = DataFormat.Fdf 'Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname" 'Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings) 'Save the PDF document loadedDocument.Save("ChineseValue.pdf") 'close the document loadedDocument.Close(True) Export the form data to a stream with the specific and form name. The stream where form data will be exported. The format of exported data The name of the PDF file the data is exported from // Loads an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; MemoryStream stream = new MemoryStream(); form.ExportData(stream, DataFormat.Xml, "SourceForm.pdf"); doc.Close(true); ' Loads an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form Dim stream As MemoryStream = New MemoryStream() form.ExportData(stream, DataFormat.Xml, "SourceForm.pdf") doc.Close(True) Export the form data to a stream with specified ExportFormSettings. // Load an existing document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("../../Data/ChineseValue.pdf"); // Load an existing form PdfLoadedForm loadedForm = loadedDocument.Form; //Create new instance for export form settings. ExportFormSettings settings = new ExportFormSettings(); //Gets or sets the data format to export form fields. settings.DataFormat = DataFormat.Fdf; //Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname"; MemoryStream stream = new MemoryStream(); //Export the form data to a stream with specified ExportFormSettings. loadedForm.ExportData(stream, settings); //Save the PDF document loadedDocument.Save("ChineseValue.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("../../Data/ChineseValue.pdf") 'Load an existing form Dim loadedForm As PdfLoadedForm = loadedDocument.Form 'Create new instance for export form settings. Dim settings As ExportFormSettings = New ExportFormSettings() 'Gets or sets the data format to export form fields. settings.DataFormat = DataFormat.Fdf 'Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname" 'Export the existing PDF document to FDF file Dim stream As MemoryStream = New MemoryStream() 'Export the form data to a stream with specified ExportFormSettings. loadedForm.ExportData(stream, settings) 'Save the PDF document loadedDocument.Save("ChineseValue.pdf") 'close the document loadedDocument.Close(True) PDF provides support to flatten a form field by removing the existing form field and replacing it with graphical objects that would resemble the form field and cannot be edited. Flatten the form fields. // Load an existing document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("../../Data/input.pdf"); // Load an existing form PdfLoadedForm loadedForm = loadedDocument.Form; // Flatten the form fields. loadedForm.FlattenFields(); //Save the PDF document loadedDocument.Save("output.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("../../Data/input.pdf") 'Load an existing form Dim loadedForm As PdfLoadedForm = loadedDocument.Form 'Flatten the form fields. loadedForm.FlattenFields() 'Save the PDF document loadedDocument.Save("output.pdf") 'close the document loadedDocument.Close(True) Export the form data in XML Forms Data Format file format. Stream. Name of the form. Export the form data in FDF file format. The stream where form data will be exported. The name of the PDF file the data is exported from. Exports the form data in XML file format Exports the form data in JSON file format Gets the export value for loaded list and combo box fields. Validate the XML node element name of the XML element node. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Clears PdfLoadedForm. Removes field and kids annotation from dictionaries. The field. Deletes from pages. The field. Deletes the annotation from the page dictionary. The field. Gets the new name of the field. The name. The field name. Imports the form data from the file with the specific . Name of the file. The data format. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; form.ImportData("ImportData.xml",DataFormat.Xml); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form form.ImportData("ImportData.xml",DataFormat.Xml) doc.Save("Import.pdf") doc.Close(True) Imports the form data from the file with the specified ImportFormSettings. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Load an existing form loadedForm = document.Form; //Create new instance for import form settings. ImportFormSettings settings = new ImportFormSettings(); //Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf; //Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf"; //Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("ImportFDF.fdf", settings); //Save the PDF document document.Save("WF_60299_Fdf.pdf"); //close the document document.Close(true); 'Load an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ' Load an existing form loadedForm = document.Form Dim settings As ImportFormSettings = New ImportFormSettings() 'Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf 'Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf" 'Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("ImportFDF.fdf", settings) //Save the PDF document document.Save("WF_60299_Fdf.pdf") //close the document document.Close(True) Imports the form data from the file with the specific . Array data of the file. The data format. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; byte[] array = System.IO.File.ReadAllBytes("ImportData.xml"); form.ImportData(array,DataFormat.Xml); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form Dim array as byte[] =System.IO.File.ReadAllBytes("ImportData.xml") form.ImportData(array,DataFormat.Xml) doc.Save("Import.pdf") doc.Close(True) Imports the form data from the file with the specific . Name of the file. The data format. if it is error flag, set to true. Error messages wile importing. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; form.ImportData("ImportData.xml",DataFormat.Xml, false); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form form.ImportData("ImportData.xml",DataFormat.Xml, False) doc.Save("Import.pdf") doc.Close(True) Imports the form data from the file with the specific . Array data of the file. The data format. if it is error flag, set to true. Error messages wile importing. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; byte[] array = System.IO.File.ReadAllBytes("ImportData.xml"); form.ImportData("ImportData.xml",DataFormat.Xml, false); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form Dim array as byte[] =System.IO.File.ReadAllBytes("ImportData.xml") form.ImportData(array,DataFormat.Xml, False) doc.Save("Import.pdf") doc.Close(True) Imports the data field. Name of the file. The data format. if it is continue import on error, set to true. Imports Form value from XML file Name of the imported file. The input file format False if the import should stop on the first field that generates an error, or true if the import should ignore the error and continue with the next field. Document form fields filled with data which are imported from XML. Import form data from Json file. The Json file //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Import the JSON file form.ImportDataJson("ImportJSON.json"); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form ' Import the JSON file form.ImportDataJson("ImportJSON.json") doc.Save("Import.pdf") doc.Close(True) Import form data from Json file. Array data of Json file //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; byte[] array = System.IO.File.ReadAllBytes(ImportJSON.json); // Import the JSON file form.ImportDataJson(array); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form Dim array as byte[]=System.IO.File.ReadAllBytes(ImportJSON.json) ' Import the JSON file form.ImportDataJson(array) doc.Save("Import.pdf") doc.Close(True) Import form data from Json file. The Json file stream //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Load the Json file FileStream stream = new FileStream("ImportJSON.json", FileMode.Open); // Import the JSON file stream form.ImportDataJson(stream); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form // Load the Json file Dim stream As FileStream= new FileStream("ImportJSON.json", FileMode.Open) ' Import the JSON file stream form.ImportDataJson(stream) doc.Save("Import.pdf") doc.Close(True) Import form data from FDF file. The FDF file stream //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Load the FDF file FileStream stream = new FileStream("ImportFDF.fdf", FileMode.Open); // Import the FDF stream form.ImportDataFDF(stream); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form ' Load the FDF file Dim stream As FileStream = New FileStream("ImportFDF.fdf", FileMode.Open) ' Import the FDF stream form.ImportDataFDF(stream) doc.Save("Import.pdf") doc.Close(True) Import form data from FDF file. Array data of the fdf file. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Load the FDF file byte[] array = System.IO.File.ReadAllBytes("ImportFDF.fdf"); // Import the FDF stream form.ImportDataFDF(array); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form ' Load the FDF file Dim array As byte[] = System.IO.File.ReadAllBytes("ImportFDF.fdf") ' Import the FDF stream form.ImportDataFDF(array) doc.Save("Import.pdf") doc.Close(True) Import form data from FDF file. The FDF file stream False if the import should stop on the first field that generates an error, or true if the import should ignore the error and continue with the next field. Error messages wile importing. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Load the FDF file FileStream stream = new FileStream("ImportFDF.fdf", FileMode.Open); // Import the FDF stream form.ImportDataFDF(stream,true); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form ' Load the FDF file Dim stream As FileStream = New FileStream("ImportFDF.fdf", FileMode.Open) ' Import the FDF stream form.ImportDataFDF(stream,True) doc.Save("Import.pdf") doc.Close(True) Sets or resets the form field highlight option. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; form.HighlightFields(true); doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form form.HighlightFields(True) doc.Save("output.pdf") doc.Close(True) Called when [hex in string]. The test string. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; bool isHex = form.OnlyHexInString("123456"); doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form Dim isHex As Boolean = form.OnlyHexInString("123456") doc.Save("output.pdf") doc.Close(True) Import form data Import XML Data Imports XFDF Data from the specific file. The XFDF file path. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Import the XFDF file. form.ImportDataXFDF("ImportXFDF.xfdf"); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'Import the XFDF file. form.ImportDataXFDF("ImportXFDF.xfdf") doc.Save("Import.pdf") doc.Close(True) Imports XFDF Data form the specific stream. Array data of the xfdf file. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Load the XFDF file byte[] array = System.IO.File.ReadAllBytes("ImportXFDF.xfdf"); // Import the XFDF stream form.ImportDataXFDF(array); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form ' Load the XFDF file Dim array As byte[] = System.IO.File.ReadAllBytes("ImportXFDF.xfdf") ' Import the XFDF stream form.ImportDataXFDF(array) doc.Save("Import.pdf") doc.Close(True) Imports XFDF Data form the specific stream. The XFDF file stream. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; // Load the XFDF file FileStream stream = new FileStream("ImportXFDF.xfdf", FileMode.Open); // Import the XFDF stream form.ImportDataXFDF(stream); doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form ' Load the XFDF file Dim stream As FileStream = New FileStream("ImportXFDF.xfdf", FileMode.Open) ' Import the XFDF stream form.ImportDataXFDF(stream) doc.Save("Import.pdf") doc.Close(True) Imports the form data from the stream with the specified ImportFormSettings. // Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); // Load an existing form loadedForm = document.Form; //Create new instance for import form settings. ImportFormSettings settings = new ImportFormSettings(); // Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf; //Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf"; FileStream stream = new FileStream("ImportFDF.fdf", FileMode.Open); //Imports the form data from the stream with the specified ImportFormSettings. loadedForm.ImportData(stream, settings); //Save the PDF document document.Save("WF_60299_Fdf.pdf"); //close the document document.Close(true); 'Load an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Load an existing form loadedForm = document.Form 'Create new instance for import form settings. Dim settings As ImportFormSettings = New ImportFormSettings() 'Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf 'Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf" Dim stream As FileStream = New FileStream("ImportFDF.fdf", FileMode.Open) 'Imports the form data from the stream with the specified ImportFormSettings. loadedForm.ImportData(stream, settings) //Save the PDF document document.Save("WF_60299_Fdf.pdf") //close the document document.Close(True) Gets or sets the XFA form Gets the field collection.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; //load the form field PdfLoadedField field = form.Fields[0] as PdfLoadedField; field.Export = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'load the form field Dim field As PdfLoadedField = TryCast(form.Fields(0), PdfLoadedField) field.Export = True doc.Save("Form.pdf") doc.Close(True) Class Class Enabling this property will fill both the AcroForm and XFA fields, and disabling this property will fill only AcroForm fields. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm loadedForm = doc.Form; //Set EnableXfaForm loadedForm.EnableXfaFormFill = true; PdfLoadedTextBoxField loadedTextBoxFieldDate = loadedForm.Fields[0] as PdfLoadedTextBoxField; loadedTextBoxFieldDate.Text = "PDF"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'Set the form as read only form.EnableXfaFormFill = True Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.Text = "PDF" doc.Save("Form.pdf") doc.Close(True) Gets or sets the ExportEmptyFields property, enabling this will export the empty acroform fields. //Load an existing document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); // Load an existing form PdfLoadedForm loadedForm = loadedDocument.Form; //Export empty fields loadedForm.ExportEmptyFields = true; //Export the existing PDF document to XML file loadedForm.ExportData("Output.xml", DataFormat.Xml, @"AcroForm1"); //Close the document loadedDocument.Close(true); 'Load an existing document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Load the existing form Dim loadedForm As PdfLoadedForm = loadedDocument.Form 'Export empty fields loadedForm.ExportEmptyFields = True 'Export the existing PDF document to XML file loadedForm.ExportData("Output.xml", DataFormat.Xml, "AcroForm1") loadedDocument.Close(True) Gets or sets a value indicating whether the form is read only. True if the field is read-only, false otherwise. Default is false. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; //Set the form as read only form.ReadOnly = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'Set the form as read only form.ReadOnly = True doc.Save("Form.pdf") doc.Close(True) Class Class Gets the signature flags. Gets or sets a value indicating whether need appearances. Gets the resources. Gets or sets a value indicating whether this instance is modified. Gets the cross table. Gets or sets the terminal fields. Gets or sets a value indicating whether this form is XFA Form or AcroForm. Represents node information. Parsed field count. Current kids array. Initializes a new instance of the class. The fields. The count. Gets or sets the current array. Gets or sets the count. Represents errors on importing loaded field. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; //Import PdfLoadedFieldImportError[] error = form.ImportData("out.xml", DataFormat.Xml, true); //Get the exception. Exception exception = error[0].Exception; //Get field PdfLoadedField field = error[0].Field; doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'Import Dim[error] As PdfLoadedFieldImportError() = form.ImportData("out.xml", DataFormat.Xml, True) 'Get the exception. Dim exception As Exception = [error](0).Exception 'Get field Dim field As PdfLoadedField = [error](0).Field doc.Save("Import.pdf") doc.Close(True) Gets the exception. The exception. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; //Import PdfLoadedFieldImportError[] error = form.ImportData("out.xml", DataFormat.Xml, true); //Get the exception. Exception exception = error[0].Exception; //Get field PdfLoadedField field = error[0].Field; doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'Import Dim[error] As PdfLoadedFieldImportError() = form.ImportData("out.xml", DataFormat.Xml, True) 'Get the exception. Dim exception As Exception = [error](0).Exception 'Get field Dim field As PdfLoadedField = [error](0).Field doc.Save("Import.pdf") doc.Close(True) Gets the field. The field. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = doc.Form; //Import PdfLoadedFieldImportError[] error = form.ImportData("out.xml", DataFormat.Xml, true); //Get the exception. Exception exception = error[0].Exception; //Get field PdfLoadedField field = error[0].Field; doc.Save("Import.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = doc.Form 'Import Dim[error] As PdfLoadedFieldImportError() = form.ImportData("out.xml", DataFormat.Xml, True) 'Get the exception. Dim exception As Exception = [error](0).Exception 'Get field Dim field As PdfLoadedField = [error](0).Field doc.Save("Import.pdf") doc.Close(True) Class that represents the form field export settings. // Load an existing document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("../../Data/ChineseValue.pdf"); // Load an existing form PdfLoadedForm loadedForm = loadedDocument.Form; //Create new instance for export form settings. ExportFormSettings settings = new ExportFormSettings(); //Gets or sets the data format to export form fields. settings.DataFormat = DataFormat.Fdf; //Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname"; //Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings); //Save the PDF document loadedDocument.Save("ChineseValue.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("../../Data/ChineseValue.pdf") 'Load an existing form Dim loadedForm As PdfLoadedForm = loadedDocument.Form 'Create new instance for export form settings. Dim settings As ExportFormSettings = New ExportFormSettings() 'Gets or sets the data format to export form fields. settings.DataFormat = DataFormat.Fdf 'Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname" 'Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings) 'Save the PDF document loadedDocument.Save("ChineseValue.pdf") 'close the document loadedDocument.Close(True) Gets or sets data format to export form fields. // Load an existing document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("../../Data/ChineseValue.pdf"); // Load an existing form PdfLoadedForm loadedForm = loadedDocument.Form; //Create new instance for export form settings. ExportFormSettings settings = new ExportFormSettings(); //Gets or sets the data format to export form fields. settings.DataFormat = DataFormat.Fdf; //Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings); //Save the PDF document loadedDocument.Save("ChineseValue.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("../../Data/ChineseValue.pdf") 'Load an existing form Dim loadedForm As PdfLoadedForm = loadedDocument.Form 'Create new instance for export form settings. Dim settings As ExportFormSettings = New ExportFormSettings() 'Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf 'Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings) 'Save the PDF document loadedDocument.Save("ChineseValue.pdf") 'close the document loadedDocument.Close(True) Gets or sets the value that indicates the form name of the PDF form is export. // Load an existing document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("../../Data/ChineseValue.pdf"); // Load an existing form PdfLoadedForm loadedForm = loadedDocument.Form; //Create new instance for export form settings. ExportFormSettings settings = new ExportFormSettings(); //Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname"; //Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings); //Save the PDF document loadedDocument.Save("ChineseValue.pdf"); //close the document loadedDocument.Close(true); 'Load an existing document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("../../Data/ChineseValue.pdf") 'Load an existing form Dim loadedForm As PdfLoadedForm = loadedDocument.Form 'Create new instance for export form settings. Dim settings As ExportFormSettings = New ExportFormSettings() 'Gets or sets the value that indicates the form name of the PDF form is export. settings.FormName = "formname" 'Export the form data to a file with specified ExportFormSettings. loadedForm.ExportData("ChineseValue.Fdf", settings) 'Save the PDF document loadedDocument.Save("ChineseValue.pdf") 'close the document loadedDocument.Close(True) Class that represents the form field import settings. // Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); // Load an existing form loadedForm = document.Form; //Create new instance for import form settings. ImportFormSettings settings = new ImportFormSettings(); // Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf; //Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf"; //Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings); //Save the PDF document document.Save("WF_60299_Fdf.pdf"); //close the document document.Close(true); 'Load an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Load an existing form loadedForm = document.Form 'ImportFormSettings that represents the form field import settings. Dim settings As ImportFormSettings = New ImportFormSettings() 'Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf 'Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf" 'Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings) 'Save the PDF document document.Save("WF_60299_Fdf.pdf") 'close the document document.Close(True) Gets or sets data format to import form fields. // Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); // Load an existing form loadedForm = document.Form; //Create new instance for import form settings. ImportFormSettings settings = new ImportFormSettings(); // Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf; //Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf"; //Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings); //Save the PDF document document.Save("WF_60299_Fdf.pdf"); //close the document document.Close(true); 'Load an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Load an existing form loadedForm = document.Form Dim settings As ImportFormSettings = New ImportFormSettings() 'Gets or sets the data format to import form fields. settings.DataFormat = DataFormat.Fdf 'Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf" 'Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings) 'Save the PDF document document.Save("WF_60299_Fdf.pdf") 'close the document document.Close(True) Gets or sets the value that indicates the form name of the PDF form is import. // Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); // Load an existing form loadedForm = document.Form; //Create new instance for import form settings. ImportFormSettings settings = new ImportFormSettings(); //Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf"; // Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings); //Save the PDF document document.Save("WF_60299_Fdf.pdf"); //close the document document.Close(true); 'Load an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Load an existing form loadedForm = document.Form 'Create new instance for import form settings. Dim settings As ImportFormSettings = New ImportFormSettings() 'Gets or sets the value that indicates the form name of the PDF form is import. settings.FormName = "../../FDF_output.pdf" 'Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings) 'Save the PDF document document.Save("WF_60299_Fdf.pdf") 'close the document document.Close(True) Gets or sets a flag describing whether to ignore errors while importing a PDF form. The default value is false. // Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); // Load an existing form loadedForm = document.Form; ImportFormSettings settings = new ImportFormSettings(); //Gets or sets a flag describing whether to ignore errors while importing a PDF form. The default value is false settings.IgnoreErrors = true; // Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings); //Save the PDF document document.Save("WF_60299_Fdf.pdf"); //close the document document.Close(true); 'Load an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Load an existing form loadedForm = document.Form Dim settings As ImportFormSettings = New ImportFormSettings() 'Gets or sets a flag describing whether to ignore errors while importing a PDF form. The default value is false settings.IgnoreErrors = true; 'Imports the form data from the file with the specified ImportFormSettings. loadedForm.ImportData("WF_60299.Fdf", settings) 'Save the PDF document document.Save("WF_60299_Fdf.pdf") 'close the document document.Close(True) Represents field collection of loaded form. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // PDF loaded field collection PdfLoadedFormFieldCollection fieldCollection = doc.Form.Fields; // Remove the first field fieldCollection.RemoveAt(0); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' PDF loaded field collection Dim fieldCollection As PdfLoadedFormFieldCollection = doc.Form.Fields ' Remove the first field fieldCollection.RemoveAt(0) doc.Save("Form.pdf") doc.Close(True) Class Loaded form, wich collection belongs to. Initializes a new instance of the class with the specific . The PDF loaded form. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); //Load the existing PDF form. PdfLoadedForm form = doc.Form; //Create a new form fields collection instance. PdfLoadedFormFieldCollection collection = new PdfLoadedFormFieldCollection(form); //Remove field. collection.RemoveAt(0); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") 'Load the existing PDF form. Dim form As PdfLoadedForm = doc.Form 'Create a new form fields collection instance. Dim collection As New PdfLoadedFormFieldCollection(form) 'Remove field. collection.RemoveAt(0) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Initialize the new instance of the class. Gets the field. The index. The created field. Creates the signature field. The dictionary. The cross table. The created signature field. Creates the list box. The dictionary. The cross table. The created list box. Creates the combo box. The dictionary. The cross table. The created combo box. Creates the text field. The dictionary. The cross table. The created text field. Creates the radio button. The dictionary. The cross table. The created radio button. Creates the check box. The dictionary. The cross table. The created check box. Creates the push button. The dictionary. The cross table. The created push button. Gets the type of the field. The name. The dictionary. The cross table. The field type. Adds a field to collection. The field. Inserts a filed into collection. The index. The field. Removes the field from collection. The field. Removes the field at the specified position. The index. Clears the collection. Check whether the field with the same name already exists. The name. true if there are no fields with the same name within the collection; otherwise false. Gets the new name of the field. The name. The field name. Adds the field dictionary. The field. NameChanged evant handler. New Name of the field. Gets the index of the field. The name. The index of the field. Gets the named field. The name. The field with specified name. Gets the form field with the given field name Name of the field Loaded Form Field True, if form field exists, else False. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); //Load the existing PDF form. PdfLoadedFormFieldCollection fields = doc.Form.Fields; PdfLoadedField field = null; //Get the specific field by name. fields.TryGetField("fn", out field); //Set text. (field as PdfLoadedTextBoxField).Text = "Modified"; //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") 'Load the existing PDF form. Dim fields As PdfLoadedFormFieldCollection = doc.Form.Fields Dim field As PdfLoadedField = Nothing 'Get the specific field by name. fields.TryGetField("fn", field) 'Set text. TryCast(field, PdfLoadedTextBoxField).Text = "Modified" 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the filed value from the given field name Name of the loaded form filed Value of the field True, if form field exists with the specific name, else False. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("Form.pdf"); //Load the existing PDF form. PdfLoadedFormFieldCollection fields = doc.Form.Fields; string fieldValue = null; //Get the specific field value by name. fields.TryGetValue("fn", out fieldValue); //Save and close the document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("Form.pdf") 'Load the existing PDF form. Dim fields As PdfLoadedFormFieldCollection = doc.Form.Fields Dim fieldValue As String = Nothing 'Get the specific field value by name. fields.TryGetValue("fn", fieldValue) 'Save and close the document. doc.Save("output.pdf") doc.Close(True) Gets the at the specified index.[Read-Only] PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); //load the form fields foreach (PdfField field in doc.Form.Fields) { // Flatten the form field.Flatten = true; } doc.Save("Form.pdf"); doc.Close(true); Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") 'load the form fields For Each field As PdfField In doc.Form.Fields ' Flatten the form field.Flatten = True Next field doc.Save("Form.pdf") doc.Close(True) Class Returns field with specified name.[Read-Only] The specified field name. // Loads an existing PDF document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the FirstTextBox field PdfField field = doc.Form.Fields["FirstTextBox"]; field.Flatten = true; doc.Save("Form.pdf"); doc.Close(true); // Loads an existing PDF document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the FirstTextBox field Dim field As PdfField = doc.Form.Fields("FirstTextBox") field.Flatten = True doc.Save("Form.pdf") doc.Close(True) Gets or sets the form. // Loads an existing PDF document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the FirstTextBox field PdfField field = doc.Form.Fields["FirstTextBox"]; field.Flatten = true; doc.Save("Form.pdf"); doc.Close(true); // Loads an existing PDF document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the FirstTextBox field Dim field As PdfField = doc.Form.Fields("FirstTextBox") field.Flatten = True doc.Save("Form.pdf") doc.Close(True) Represents loaded list box field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // Flatten the list field listField.Flatten = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' Flatten the list field listField.Flatten = True doc.Save("Form.pdf") doc.Close(True) Class Represents collection of items. Initializes a new instance of the class. The dictionary. The cross table. Draws this instance if it is flatten. Begins the save. Creates a copy of PdfLoadedListBoxField. Creates a copy of PdfLoadedListBoxField. Creates a copy of PdfLoadedListField Item. Applies the appearance. The widget. The item. Draws the list box. The graphics. The item. Converts to list items. The items. The PdfListItemCollection. Gets the height of the font. The calculated size of font. Gets or sets the complex script language support. //Load existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("form.pdf"); //Load the existing list box field. PdfLoadedListBoxField list = lfied as PdfLoadedListBoxField; //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Set font. list.Font = pdfFont; //Enable complex script support. list.ComplexScript = true; ldoc.Form.SetDefaultAppearance(false); //Save the document. ldoc.Save("output.pdf"); //Close the document. ldoc.Close(true); 'Load existing PDF document. Dim ldoc As New PdfLoadedDocument("form.pdf") 'Load the existing list box field. Dim list As PdfLoadedListBoxField = TryCast(ldoc.Form.Fields(0), PdfLoadedListBoxField) 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Set font. list.Font = pdfFont 'Enable complex script support. list.ComplexScript = True ldoc.Form.SetDefaultAppearance(False) 'Save the document. ldoc.Save("output.pdf") 'Close the document. ldoc.Close(True) Gets or sets a value indicating whether the field is multi-selectable. // Loads an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // Enabling the multi selection option listField.MultiSelect = true; doc.Save("Sample.pdf"); doc.Close(true); ' Loads an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' Enabling the multi selection option listField.MultiSelect = True doc.Save("Sample.pdf") doc.Close(True) Class Class Gets the collection of list field.[Read-Only] The collection of list box items. // Loads an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List box items collection PdfLoadedListFieldItemCollection listcollection = listField.Items; listcollection[0].Location = new PointF(100, 200); doc.Save("Sample.pdf"); doc.Close(true); ' Loads an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List box items collection Dim listcollection As PdfLoadedListFieldItemCollection = listField.Items listcollection(0).Location = New PointF(100, 200) doc.Save("Sample.pdf") doc.Close(True) Class Class Represents group item for list field. Class // Loads an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // Loaded list box field items PdfLoadedListFieldItem listFieldItem = listField.Items[0]; listFieldItem.Location = new PointF(100, 200); doc.Save("Sample.pdf"); doc.Close(true); ' Loads an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' Loaded list box field items Dim listFieldItem As PdfLoadedListFieldItem = listField.Items(0) listFieldItem.Location = New PointF(100, 200) doc.Save("Sample.pdf") doc.Close(True) Class Class Class Initializes a new instance of the class. The field. The index. The dictionary. Cloning the PdfLoadedListFieldItem. Represents loaded list field item collection. Class //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // list field item Collection PdfLoadedListFieldItemCollection listItemCollection = listField.Items; listItemCollection[0].Bounds = new RectangleF(0, 0, 20, 30); doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' list field item Collection Dim listItemCollection As PdfLoadedListFieldItemCollection = listField.Items listItemCollection(0).Bounds = New RectangleF(0, 0, 20, 30) doc.Save("LoadedForm.pdf") doc.Close(True) Class Cloning the PdfLoadedListFieldItemCollection. Gets the at the specified index.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List field item Collection PdfLoadedListFieldItemCollection listItemCollection = listField.Items; // Reading the first item in the list items collection PdfLoadedListFieldItem listItem = listItemCollection[0]; // Relocate the list item listItem.Location = new PointF(10, 20); doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List field item Collection Dim listItemCollection As PdfLoadedListFieldItemCollection = listField.Items ' Reading the first item in the list items collection Dim listItem As PdfLoadedListFieldItem = listItemCollection(0) ' Relocate the list item listItem.Location = New PointF(10, 20) doc.Save("LoadedForm.pdf") doc.Close(True) Class Represents loaded list item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // Get the selected list item PdfLoadedListItem listItem = listField.SelectedItem; listItem.Text = "NewText"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' Get the selected list item Dim listItem As PdfLoadedListItem = listField.SelectedItem listItem.Text = "NewText" doc.Save("Form.pdf") doc.Close(True) Class Class Text of the item. Value of the item. Field wich item belons to. CrossTable of document. Initializes a new instance of the class. The text. The value. The field. The cross table. Initializes a new instance of the class with the specific text and value. The text. The value. // Load the list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // Get the selected list item PdfLoadedListItem listItem = new PdfLoadedListItem("C#.Net",".NET Course"); // Add the list item in list field listField.Values.Add(listItem); ' Load the list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' Get the selected list item Dim listItem As PdfLoadedListItem = New PdfLoadedListItem("C#.Net",".NET Course") ' Add the list item in list field listField.Values.Add(listItem) Sets the text of the item. Sets item value. The item value. Gets or sets the value of the list item. A string value representing the value of the item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // Get the selected list item PdfLoadedListItem listItem = listField.SelectedItem; listItem.Value = "C#.NET"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' Get the selected list item Dim listItem As PdfLoadedListItem = listField.SelectedItem listItem.Value = "C#.NET" doc.Save("Form.pdf") doc.Close(True) Class Class Represents a collection of list box field items. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List field item Collection PdfLoadedListItemCollection listItemCollection = listField.Values; // Create a new list item PdfLoadedListItem listItem = new PdfLoadedListItem("Oracle", "Oracle"); // Adding item in collection listItemCollection.Add(listItem); doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List field item Collection Dim listItemCollection As PdfLoadedListItemCollection = listField.Values ' Create a new list item Dim listItem As PdfLoadedListItem = New PdfLoadedListItem("Oracle", "Oracle") ' Adding item in collection listItemCollection.Add(listItem) doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Class Parents field. Initializes a new instance of the class. The field. Inserts an list item at the end of the collection. a object to be added to collection. The index of item. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List field item Collection PdfLoadedListItemCollection listItemCollection = listField.Values; // Create a new list item PdfLoadedListItem listItem = new PdfLoadedListItem("Oracle", "Oracle"); // Adding item in collection listItemCollection.Add(listItem); doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List field item Collection Dim listItemCollection As PdfLoadedListItemCollection = listField.Values ' Create a new list item Dim listItem As PdfLoadedListItem = New PdfLoadedListItem("Oracle", "Oracle") ' Adding item in collection listItemCollection.Add(listItem) doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Adds the item. The item. The index of added item. Inserts the list item at the specified index. The index. The item. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List field item Collection PdfLoadedListItemCollection listItemCollection = listField.Values; // Getting the first item from the list item collection PdfLoadedListItem listItem = listItemCollection[0]; // Insert the item at first index listItemCollection.Insert(0, listItem); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List field item Collection Dim listItemCollection As PdfLoadedListItemCollection = listField.Values ' Getting the first item from the list item collection Dim listItem As PdfLoadedListItem = listItemCollection(0) ' Insert the item at first index listItemCollection.Insert(0, listItem) doc.Save("Form.pdf") doc.Close(True) Class Class Removes the list item at the specified index. The index. Throws IndexOutOfRange exception if the index is out of bounds. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List field item Collection PdfLoadedListItemCollection listItemCollection = listField.Values; // Remove the first item listItemCollection.RemoveAt(0); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List field item Collection Dim listItemCollection As PdfLoadedListItemCollection = listField.Values ' Remove the first item listItemCollection.RemoveAt(0) doc.Save("Form.pdf") doc.Close(True) Class Class Clears the item collection. //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List field item Collection PdfLoadedListItemCollection listItemCollection = listField.Values; // Clears the collection listItemCollection.Clear(); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List field item Collection Dim listItemCollection As PdfLoadedListItemCollection = listField.Values ' Clears the collection listItemCollection.Clear() doc.Save("Form.pdf") doc.Close(True) Class Class Gets the items. Gets the array. The item. The array of item value and text. Gets the at the specified index.[Read-Only] //Load an existing document. PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'course' list box field PdfLoadedListBoxField listField = doc.Form.Fields["Course"] as PdfLoadedListBoxField; // List field item Collection PdfLoadedListItemCollection listItemCollection = listField.Values; // Getting the first item from the list item collection PdfLoadedListItem listItem = listItemCollection[0]; listItem.Value = "C#.NET"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'course' list box field Dim listField As PdfLoadedListBoxField = TryCast(doc.Form.Fields("Course"), PdfLoadedListBoxField) ' List field item Collection Dim listItemCollection As PdfLoadedListItemCollection = listField.Values ' Getting the first item from the list item collection Dim listItem As PdfLoadedListItem = listItemCollection(0) listItem.Value = "C#.NET" doc.Save("Form.pdf") doc.Close(True) Class Class Represents collection of radio box group items. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Radio button field collection PdfLoadedRadioButtonItemCollection radiobuttonFieldCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonFieldCollection[0]; // Selected the item radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Radio button field collection Dim radiobuttonFieldCollection As PdfLoadedRadioButtonItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonFieldCollection(0) ' Selected the item radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Class Index of the specified item. The item. The index of specified item Adds the specified item. The item. Cloning the PdfLoadedRadioButtonItemCollection. Gets the at the specified index.[Read-Only] Returns object at the specified index. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Radio button field collection PdfLoadedRadioButtonItemCollection radiobuttonFieldCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonFieldCollection[0]; // Selected the item radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Radio button field collection Dim radiobuttonFieldCollection As PdfLoadedRadioButtonItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonFieldCollection(0) ' Selected the item radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Class Represents radio button field of an existing PDF document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Radio button field collection PdfLoadedRadioButtonItemCollection radiobuttonFieldCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonFieldCollection[0]; radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Radio button field collection Dim radiobuttonFieldCollection As PdfLoadedRadioButtonItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonFieldCollection(0) radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Class Initializes a new instance of the class. The field. The index. The dictionary. Gets the item value. The value of the item. Stes item value. The item value. Cloning the PdfLoadedRadioButtonItem. Gets or sets the value of the radio button. The value of the radio button item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Radio button field collection PdfLoadedRadioButtonItemCollection radiobuttonFieldCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonFieldCollection[0]; // Set the value of the item radiobuttonItem.Value = "Male"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Radio button field collection Dim radiobuttonFieldCollection As PdfLoadedRadioButtonItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonFieldCollection(0) ' Set the value of the item radiobuttonItem.Value = "Male" doc.Save("Form.pdf") doc.Close(True) Class Class Gets an option value of the radio button. The option value of the radio button field item // Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Gets the loaded form PdfLoadedForm form = doc.Form; //Set default appearance as false form.SetDefaultAppearance(false); // Gets the 'Gender' radio button field PdfLoadedRadioButtonListField radioButtonField = form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Select the item which contains option value as "Male" foreach (PdfLoadedRadioButtonItem item in radioButtonField.Items) { // Gets an option value of the item if (item.OptionValue == "Male") { item.Selected = true; } } // Save and close the PDF document doc.Save("Form.pdf"); doc.Close(true); ' Load an existing document Dim doc As New PdfLoadedDocument("SourceForm.pdf") ' Gets the loaded form Dim form As PdfLoadedForm = doc.Form 'Set default appearance as false form.SetDefaultAppearance(False) ' Gets the 'Gender' radio button field Dim radioButtonField As PdfLoadedRadioButtonListField = TryCast(form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Select the item which contains option value as "Male" For Each item As PdfLoadedRadioButtonItem In radioButtonField.Items ' Gets an option value of the item If item.OptionValue = "Male" Then item.Selected = True End If Next ' Save and close the PDF document doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets a value indicating whether this is selected. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Radio button field collection PdfLoadedRadioButtonItemCollection radiobuttonFieldCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonFieldCollection[0]; // Set the first item as selected item radiobuttonItem.Selected = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Radio button field collection Dim radiobuttonFieldCollection As PdfLoadedRadioButtonItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonFieldCollection(0) ' Set the first item as selected item radiobuttonItem.Selected = True doc.Save("Form.pdf") doc.Close(True) Class Class Gets the parent. Represents radio button field of an existing PDF document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Flatten the radio button field radiobuttonField.Flatten = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Flatten the radio button field radiobuttonField.Flatten = True doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Symbol for check state. Initializes a new instance of the class. The dictionary. The cross table. Get the radio button item based on its value/option value. Gets the item. The index. The item dictionary. The proper state item. Gets the index of the selected. The index of first selected item. Sets selected index of the radio button. Selected index. Sets selected value. Selected value. Draws this instance if it is flatten. Begins the save. Creates a copy of PdfLoadedRadioButtonListField. Creates a copy of PdfLoadedRadioButtonListField. Creates a copy of PdfLoadedRadioButtonItem. Gets option value from Opt dictionary and map it into item. Gets the collection of radio button items.[Read-Only] A that represents the items within the list. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Getting the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Radio button field collection PdfLoadedRadioButtonItemCollection radiobuttonFieldCollection = radiobuttonField.Items; // Radio button field item PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonFieldCollection[0]; // Selected the item radiobuttonItem.Checked = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Getting the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Radio button field collection Dim radiobuttonFieldCollection As PdfLoadedRadioButtonItemCollection = radiobuttonField.Items ' Radio button field item Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonFieldCollection(0) ' Selected the item radiobuttonItem.Checked = True doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Class Gets or sets the index of the selected item in the list. The lowest ordinal index of the selected items in the list. The default is -1, which indicates that nothing is selected. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Set the selected index as 1 radiobuttonField.SelectedIndex = 1; // Save the document to a disk doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Set the selected index as 1 radiobuttonField.SelectedIndex = 1 ' Save the document to a disk doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets the value of the first selected item in the list. A string value specifying the value of the first selected item, null (Nothing in VB.NET) if there is no selected item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Set the selected index as 1 radiobuttonField.SelectedValue = "Female"; // Save the document to a disk doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Set the selected index as 1 radiobuttonField.SelectedValue = "Female" ' Save the document to a disk doc.Save("Form.pdf") doc.Close(True) Class Class Gets the selected item.[Read-Only] Return the item as PdfLoadedRadioButtonItem class //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Read the selected item of the radio button PdfLoadedRadioButtonItem radiobuttonItem = radiobuttonField.SelectedItem; // Uncheck the selected item radiobuttonItem.Checked = false; // Save the document to a disk doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Read the selected item of the radio button Dim radiobuttonItem As PdfLoadedRadioButtonItem = radiobuttonField.SelectedItem ' Uncheck the selected item radiobuttonItem.Checked = False ' Save the document to a disk doc.Save("Form.pdf") doc.Close(True) Class Class Gets or sets the value of specified item. A string value representing the value of the item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the 'Gender' radio button field PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField; // Set the radio box value as Male radiobuttonField.Value = "Male"; // Save the document to a disk doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the 'Gender' radio button field Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField) ' Set the radio box value as Male radiobuttonField.Value = "Male" ' Save the document to a disk doc.Save("Form.pdf") doc.Close(True) Class Class Represents the signature field of an existing PDF document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Gets the signature field PdfLoadedSignatureField signatureField = doc.Form.Fields["ManagerSignature"] as PdfLoadedSignatureField; signatureField.Flatten = true; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = TryCast(doc.Form.Fields("ManagerSignature"), PdfLoadedSignatureField) signatureField.Flatten = True doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Internal variable to store the signature. Initializes a new instance of the class. The dictionary. The cross table. Sets the signature properties Begins the save. Creates a copy of PdfLoadedSignatureField. Creates a copy of loaded item. Draws this instance if it is flatten. Get Rotated bounds to flatten Get Current Rotation angle from Page Graphics Specifies the signatures's validation result. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Close the document document.Close(true) Specifies the signatures's validation result with X509Certificate collection. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Collection of X509Certificate X509CertificateCollection certificates = new X509CertificateCollection(); certificates.Add(X509Certificate.CreateFromCertFile("certificate1.cer")); certificates.Add(X509Certificate.CreateFromCertFile("certificate2.cer")) // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(certificates); // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Collection of X509Certificate Dim certificates As X509CertificateCollection = New X509CertificateCollection() certificates.Add(X509Certificate.CreateFromCertFile("certificate1.cer")) certificates.Add(X509Certificate.CreateFromCertFile("certificate2.cer")) ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature(certificates) ' Close the document document.Close(true) Specifies the signatures's validation result with X509Certificate collection with validation option // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Collection of X509Certificate X509CertificateCollection certificates = new X509CertificateCollection(); certificates.Add(X509Certificate.CreateFromCertFile("certificate1.cer")); certificates.Add(X509Certificate.CreateFromCertFile("certificate2.cer")) PdfSignatureValidationOptions options = new PdfSignatureValidationOptions(); // disable revocation status options.ValidateRevocationStatus = false; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(certificates, options); // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Collection of X509Certificate Dim certificates As X509CertificateCollection = New X509CertificateCollection() certificates.Add(X509Certificate.CreateFromCertFile("certificate1.cer")) certificates.Add(X509Certificate.CreateFromCertFile("certificate2.cer")) ' Signature validation options Dim options As PdfSignatureValidationOptions = New PdfSignatureValidationOptions() ' disable revocation status options.ValidateRevocationStatus = False ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature(certificates, options) ' Close the document document.Close(true) Checks whether the signature field is signed or not A boolean value specifying the digital signature field have signature data or not. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the first page PdfPageBase page = doc.Pages[0]; // Gets the signature field PdfLoadedSignatureField signatureField = doc.Form.Fields["ManagerSignature"] as PdfLoadedSignatureField; // Checks whether the signature field is signed or not bool isSigned = signatureField.IsSigned; doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the first page Dim page As PdfPageBase = doc.Pages(0) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = TryCast(doc.Form.Fields("ManagerSignature"), PdfLoadedSignatureField) ' Checks whether the signature field is signed or not Dim isSigned As Boolean = signatureField.IsSigned doc.Close(True) Class Gets or sets the digital signature for signing the field. A object specifying the digital signature for signing the field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the first page PdfPageBase page = doc.Pages[0]; // Gets the signature field PdfLoadedSignatureField signatureField = doc.Form.Fields["ManagerSignature"] as PdfLoadedSignatureField; // Create a new Signature PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5), new SizeF(100, 200)); // Set the signature of the field signatureField.Signature = signature; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the first page Dim page As PdfPageBase = doc.Pages(0) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = TryCast(doc.Form.Fields("ManagerSignature"), PdfLoadedSignatureField) ' Create a new Signature Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5), New SizeF(100, 200)) ' Set the signature of the field signatureField.Signature = signature doc.Save("Form.pdf") doc.Close(True) Class Class Class Represents an item in a text box field collection. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the text box field PdfLoadedTextBoxField textBoxField = doc.Form.Fields["EmployeeName"] as PdfLoadedTextBoxField; // Read the first text box field item from the collection PdfLoadedTexBoxItem textBoxItem = textBoxField.Items[0]; textBoxItem.Location = new PointF(10, 20); doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the text box field Dim textBoxField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields("EmployeeName"), PdfLoadedTextBoxField) ' Read the first text box field item from the collection Dim textBoxItem As PdfLoadedTexBoxItem = textBoxField.Items(0) textBoxItem.Location = New PointF(10, 20) doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Class Initializes a new instance of the class. The field. The index. The dictionary. Cloning the PdfLoadedTexBoxItem. Represents the text box field of an existing PDF document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; RectangleF newBounds = new RectangleF(100, 100, 50, 50); ldField.Bounds = newBounds; ldField.SpellCheck = true; ldField.Text = "New text of the field."; ldField.Password = false; ldField.BorderStyle = PdfBorderStyle.Dashed; doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) Dim newBounds As RectangleF = New RectangleF(100, 100, 50, 50) ldField.Bounds = newBounds ldField.SpellCheck = True ldField.Text = "New text of the field." ldField.Password = False ldField.BorderStyle = PdfBorderStyle.Dashed doc.Save("LoadedForm.pdf") doc.Close(True) Class Class The password chrackter. Collection of textbox items. Internal variable to stroe field`s fore color. Initializes a new instance of the class. The dictionary. The cross table. To fill XFA field using Acro API field Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. Converts the HighlightMode as String value. PdfHighlightMode value. Returns the PdfHighlightMode as string value. Converts the given string value as PdfHighlightMode. Given string value. Returns the PdfHighlightMode values. Begins the save. Creates a copy of PdfLoadedTextBoxField. Creates a copy of PdfLoadedTextBoxField. Creates a copy of PdfLoadedTextBoxItem. Applies the appearance. The widget. The item. Draws this instance if it is flatten. Draws the text box. The graphics. The item. Checks if the text contains RTL character or number. True if the text contans RTL character or number. Checks if the text contains RTL character or number. Array of symbols. True if the text contans RTL character or number. Gets the height of the font. The calculated size of font. Gets or sets the complex script language support. //Load existing PDF document. PdfLoadedDocument ldoc = new PdfLoadedDocument("form.pdf"); //Load the existing text box field. PdfLoadedTextBoxField textField = ldoc.Form.Fields[0] as PdfLoadedTextBoxField; //Create font. Font font = new Font("Tahoma", 10f); //Create a new PDF font instance. PdfFont pdfFont = new PdfTrueTypeFont(font, FontStyle.Regular, 10f, true, true); //Set font. textField.Font = pdfFont; //Enable complex script support. textField.ComplexScript = true; ldoc.Form.SetDefaultAppearance(false); //Save the document. ldoc.Save("output.pdf"); //Close the document. ldoc.Close(true); 'Load existing PDF document. Dim ldoc As New PdfLoadedDocument("form.pdf") 'Load the existing text box field. Dim textField As PdfLoadedTextBoxField = TryCast(ldoc.Form.Fields(0), PdfLoadedTextBoxField) 'Create font. Dim font As New Font("Tahoma", 10F) 'Create a new PDF font instance. Dim pdfFont As PdfFont = New PdfTrueTypeFont(font, FontStyle.Regular, 10F, True, True) 'Set font. textField.Font = pdfFont 'Enable complex script support. textField.ComplexScript = True ldoc.Form.SetDefaultAppearance(False) 'Save the document. ldoc.Save("output.pdf") 'Close the document. ldoc.Close(True) Get or Set the back color of the field A object specifying the background color of field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field. PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.BackColor = new PdfColor(Color.Transparent); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.BackColor = New PdfColor(Color.Transparent) doc.Save("Form.pdf") doc.Close(True) Class Class Gets or Set the fore color of the field. A object specifying the background color of field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field. PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.ForeColor = new PdfColor(Color.Red); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field. Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.ForeColor = New PdfColor(Color.Red) doc.Save("Form.pdf") doc.Close(True) Class Class Get or Set the text alignment in a text box. A enumeration member specifying the text alignment in a text box. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field. PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.TextAlignment = PdfTextAlignment.Justify; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field. Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.TextAlignment = PdfTextAlignment.Justify doc.Save("Form.pdf") doc.Close(True) Class Class Get or Set the HighLightMode of the Field. A enumeration member specifying the highlight mode in a text box. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Load the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.HighlightMode = PdfHighlightMode.Push; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.HighlightMode = PdfHighlightMode.Push doc.Save("Form.pdf") doc.Close(True) Class Class Gets or Set value of the text box field. A string value representing the value of the item. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.Text = "New Text"; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.Text = "New Text" doc.Save("Form.pdf") doc.Close(True) Class Gets or sets a value indicating whether to check spelling. True if the field content should be checked for spelling erorrs, false otherwise. Default is true. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.SpellCheck = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.SpellCheck = True doc.Save("Form.pdf") doc.Close(True) Class Meaningful only if the MaxLength property is set and the Multiline, Password properties are false. If set, the field is automatically divided into as many equally spaced positions, or combs, as the value of MaxLength, and the text is laid out into those combs. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.InsertSpaces = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.InsertSpaces = True doc.Save("Form.pdf") doc.Close(True) Class Gets or sets a value indicating whether this is multiline. True if the field is multiline, false otherwise. Default is false. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.Multiline = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.Multiline = True doc.Save("Form.pdf") doc.Close(True) Class Gets or sets a value indicating whether this is password field. True if the field is a password field, false otherwise. Default is false. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.Password = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.Password = True doc.Save("Form.pdf") doc.Close(True) Class Gets or sets a value indicating whether this is scrollable. True if the field content can be scrolled, false otherwise. Default is true. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.Scrollable = true; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.Scrollable = True doc.Save("Form.pdf") doc.Close(True) Class Gets or sets the maximum length of the field, in characters. A positive integer value specifying the maximum number of characters that can be entered in the text edit field. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField ldField = doc.Form.Fields[0] as PdfLoadedTextBoxField; ldField.MaxLength = 10; doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim ldField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ldField.MaxLength = 10 doc.Save("Form.pdf") doc.Close(True) Class Gets the collection of text box field items.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field PdfLoadedTextBoxField textboxField = doc.Form.Fields[0] as PdfLoadedTextBoxField; // TextBox Item collection PdfLoadedTextBoxItemCollection textboxFieldCollection = textboxField.Items; textboxFieldCollection[0].Location = new PointF(10, 20); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field Dim textboxField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ' TextBox Item collection Dim textboxFieldCollection As PdfLoadedTextBoxItemCollection = textboxField.Items textboxFieldCollection(0).Location = New PointF(10, 20) doc.Save("Form.pdf") doc.Close(True) Class Represents collection of text box group items. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field item PdfLoadedTextBoxField textboxField = doc.Form.Fields[0] as PdfLoadedTextBoxField; // TextBox Item collection PdfLoadedTextBoxItemCollection textboxFieldCollection = textboxField.Items; textboxFieldCollection[0].Location = new PointF(10, 20); doc.Save("LoadedForm.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field item Dim textboxField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ' TextBox Item collection Dim textboxFieldCollection As PdfLoadedTextBoxItemCollection = textboxField.Items textboxFieldCollection(0).Location = New PointF(10, 20) doc.Save("LoadedForm.pdf") doc.Close(True) Class Class Class Cloning the PdfLoadedTextBoxItemCollection. Gets the at the specified index.[Read-Only] //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf"); // Read the text box field item PdfLoadedTextBoxField textboxField = doc.Form.Fields[0] as PdfLoadedTextBoxField; // Read the text box item collection PdfLoadedTextBoxItemCollection textboxFieldCollection = textboxField.Items; PdfLoadedTexBoxItem textboxItem = textboxFieldCollection[0]; textboxItem.Location = new PointF(10, 20); doc.Save("Form.pdf"); doc.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Read the text box field item Dim textboxField As PdfLoadedTextBoxField = TryCast(doc.Form.Fields(0), PdfLoadedTextBoxField) ' Read the text box item collection Dim textboxFieldCollection As PdfLoadedTextBoxItemCollection = textboxField.Items Dim textboxItem As PdfLoadedTexBoxItem = textboxFieldCollection(0) textboxItem.Location = New PointF(10, 20) doc.Save("Form.pdf") doc.Close(True) Class Class Class Represents the area type of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("invoice.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Load the existing XFA area collection. PdfLoadedXfaArea area = (loadedForm.Fields["#subform[0]"] as PdfLoadedXfaForm).Fields["Header[0]"] as PdfLoadedXfaArea; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = area.Fields["InvoiceNumber[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "12345"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("invoice.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Load the existing XFA area collection. Dim area As PdfLoadedXfaArea = TryCast(TryCast(loadedForm.Fields("#subform[0]"), PdfLoadedXfaForm).Fields("Header[0]"), PdfLoadedXfaArea) 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast(area.Fields("InvoiceNumber[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "12345" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents Loaded XFA field. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents the XFA field names Represents the XFA subform names Represents the XFA field names Represents the XFA subform names Represents the field doesn't have name. Represents the area name. Represents the XFA Field collections Represents the acroform field. convert string to float Read the margin details set the size of the field Read the XFA form fields Represents loaded form fields collection. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("invoice.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Load the existing XFA area collection. PdfLoadedXfaArea area = (loadedForm.Fields["#subform[0]"] as PdfLoadedXfaForm).Fields["Header[0]"] as PdfLoadedXfaArea; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = area.Fields["InvoiceNumber[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "12345"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("invoice.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Load the existing XFA area collection. Dim area As PdfLoadedXfaArea = TryCast(TryCast(loadedForm.Fields("#subform[0]"), PdfLoadedXfaForm).Fields("Header[0]"), PdfLoadedXfaArea) 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast(area.Fields("InvoiceNumber[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "12345" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents the abstract class of the loaded XFA form fields styled parameters. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the size of the field. Read the border of the field Read the caption details Read the font info create a new attribute Get the fields rotation angle. Gets or sets the field is readonly //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set read only. loadedTextBox.ReadOnly = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set read only. loadedTextBox.ReadOnly = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the width //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the width of the field. float width = loadedTextBox.Width; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the width of the field. Dim width As Single = loadedTextBox.Width 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the height //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the height of the field. float height = loadedTextBox.Height; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the height of the field. Dim height As Single = loadedTextBox.Height 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the location //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the location of the field. PointF location = loadedTextBox.Location; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the location of the field. Dim location As PointF = loadedTextBox.Location 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the Font //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set the font. loadedTextBox.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set the font. loadedTextBox.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets tool tip //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set tool tip. loadedTextBox.ToolTip = "Text Box"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set tool tip. loadedTextBox.ToolTip = "Text Box" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the caption //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the caption text. string text = loadedTextBox.Caption.Text; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the caption text. Dim text As string = loadedTextBox.Caption.Text 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or set the fore color. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the fore color of the field PdfColor foreColor = loadedTextBox.ForeColor; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the fore color of the field. Dim foreColor As PdfColor = loadedTextBox.ForeColor 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or set the border //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set border color. loadedTextBox.Border.Color = Color.Red; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set border color. loadedTextBox.Border.Color = Color.Red 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the horizontal alignment of the field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set the horizontal alignment of the field. loadedTextBox.HorizontalAlignment = PdfXfaHorizontalAlignment.Center; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set the horizontal alignment of the field. loadedTextBox.HorizontalAlignment = PdfXfaHorizontalAlignment.Center 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the vertical alignment of the field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set the vertical alignment of the field. loadedTextBox.VerticalAlignment = PdfXfaVerticalAlignment.Middle; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set the vertical alignment of the field. loadedTextBox.VerticalAlignment = PdfXfaVerticalAlignment.Middle 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the hightlight mode of the button field Gets or sets the mouse rollover text Gets or sets the mouse down text of the button field Gets or sets the content of the button field Represents the loaded XFA check box field. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded check box field. PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField; //Check the check box loadedCheckBox.IsChecked = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded check box field. Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField) 'Check the check box loadedCheckBox.IsChecked = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets a value indicating whether this is checked or not //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded check box field. PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField; //Check the check box loadedCheckBox.IsChecked = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded check box field. Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField) 'Check the check box loadedCheckBox.IsChecked = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the size of the check box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded check box field. PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField; //Check the check box loadedCheckBox.IsChecked = true; //Get the checkbox size. float checkBoxSize = loadedCheckBox.CheckBoxSize; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded check box field. Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField) 'Check the check box loadedCheckBox.IsChecked = True 'Get the checkbox size. Dim checkBoxSize As Single = loadedCheckBox.CheckBoxSize 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the checked styles of the check box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded check box field. PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField; //Check the check box loadedCheckBox.IsChecked = true; //Get the checked style. PdfXfaCheckedStyle style = loadedCheckBox.CheckedStyle; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded check box field. Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField) 'Check the check box loadedCheckBox.IsChecked = True 'Get the checked style. Dim style As PdfXfaCheckedStyle = loadedCheckBox.CheckedStyle 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the appearance of the check box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded check box field. PdfLoadedXfaCheckBoxField loadedCheckBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["checkBox[0]"] as PdfLoadedXfaCheckBoxField; //Check the check box loadedCheckBox.IsChecked = true; //Get the check box appearance. PdfXfaCheckBoxAppearance appearance = loadedCheckBox.CheckBoxAppearance; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded check box field. Dim loadedCheckBox As PdfLoadedXfaCheckBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("checkBox[0]"), PdfLoadedXfaCheckBoxField) 'Check the check box loadedCheckBox.IsChecked = True 'Get the check box appearance. Dim appearance As PdfXfaCheckBoxAppearance = loadedCheckBox.CheckBoxAppearance 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the border of the circle Gets or sets the tool tip of the circle Gets or sets the start angle of the arc Gets or sets the sweep angle of the Arc Gets or sets the apperance of the circle field Gets or sets the rotation angle Gets or sets width of the field Gets or sets height of the field Represents the existing combo box fields of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded combo box field. PdfLoadedXfaComboBoxField loadedComboBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["comboBoxField[0]"] as PdfLoadedXfaComboBoxField; //Set the combo box selected index loadedComboBoxField.SelectedIndex = 1; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded combo box field. Dim loadedComboBoxField As PdfLoadedXfaComboBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("comboBoxField[0]"), PdfLoadedXfaComboBoxField) 'Set the combo box selected index loadedComboBoxField.SelectedIndex = 1 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the default index of the combo box field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded combo box field. PdfLoadedXfaComboBoxField loadedComboBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["comboBoxField[0]"] as PdfLoadedXfaComboBoxField; //Set the combo box selected index loadedComboBoxField.SelectedIndex = 1; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded combo box field. Dim loadedComboBoxField As PdfLoadedXfaComboBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("comboBoxField[0]"), PdfLoadedXfaComboBoxField) 'Set the combo box selected index loadedComboBoxField.SelectedIndex = 1 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or Sets the default value of the combo box field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded combo box field. PdfLoadedXfaComboBoxField loadedComboBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["comboBoxField[0]"] as PdfLoadedXfaComboBoxField; //Set the combo box selected value loadedComboBoxField.SelectedValue = "English"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded combo box field. Dim loadedComboBoxField As PdfLoadedXfaComboBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("comboBoxField[0]"), PdfLoadedXfaComboBoxField) 'Set the combo box selected value loadedComboBoxField.SelectedValue = "English" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the hidden items of combo box field. Represents the loaded date time field of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded date time field. PdfLoadedXfaDateTimeField loadedDateTimeField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["dateTimeField[0]"] as PdfLoadedXfaDateTimeField; //Set the value loadedDateTimeField.Value = DateTime.Now; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded date time field. Dim loadedDateTimeField As PdfLoadedXfaDateTimeField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("dateTimeField[0]"), PdfLoadedXfaDateTimeField) 'Set the value loadedDateTimeField.Value = Date.Now 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Clear the DateTime field value. By doing this, the DateTime field will be set to empty. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded date time field. PdfLoadedXfaDateTimeField loadedDateTimeField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["dateTimeField[0]"] as PdfLoadedXfaDateTimeField; //Clear the value loadedDateTimeField.ClearValue();+ /// //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded date time field. Dim loadedDateTimeField As PdfLoadedXfaDateTimeField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("dateTimeField[0]"), PdfLoadedXfaDateTimeField) 'Clear the value loadedDateTimeField.ClearValue() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the date time //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded date time field. PdfLoadedXfaDateTimeField loadedDateTimeField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["dateTimeField[0]"] as PdfLoadedXfaDateTimeField; //Set the value loadedDateTimeField.Value = DateTime.Now; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded date time field. Dim loadedDateTimeField As PdfLoadedXfaDateTimeField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("dateTimeField[0]"), PdfLoadedXfaDateTimeField) 'Set the value loadedDateTimeField.Value = Date.Now 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get or sets the date field format //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded date time field. PdfLoadedXfaDateTimeField loadedDateTimeField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["dateTimeField[0]"] as PdfLoadedXfaDateTimeField; //Set the value loadedDateTimeField.Value = DateTime.Now; //Get the date time format. PdfXfaDateTimeFormat format = loadedDateTimeField.Format; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded date time field. Dim loadedDateTimeField As PdfLoadedXfaDateTimeField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("dateTimeField[0]"), PdfLoadedXfaDateTimeField) 'Set the value loadedDateTimeField.Value = Date.Now 'Get the date time format. Dim format As PdfXfaDateTimeFormat = loadedDateTimeField.Format 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or set the date field pattern //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded date time field. PdfLoadedXfaDateTimeField loadedDateTimeField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["dateTimeField[0]"] as PdfLoadedXfaDateTimeField; //Set the value loadedDateTimeField.Value = DateTime.Now; //Set the pattern. loadedDateTimeField.Pattern = "date{MMMM DD, YYYY}"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded date time field. Dim loadedDateTimeField As PdfLoadedXfaDateTimeField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("dateTimeField[0]"), PdfLoadedXfaDateTimeField) 'Set the value loadedDateTimeField.Value = Date.Now 'Set the pattern. loadedDateTimeField.Pattern = "date{MMMM DD, YYYY}" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents the loaded XFA document. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Intialize the new instance of the class. The input file path. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Initialize the new instance of the class. The input file path. The password for the input document. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf", "password"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf", "password") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Initialize the new instance of the class. The input file stream. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument(new MemoryStream(File.ReadAllBytes("input.pdf"))); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument(New MemoryStream(File.ReadAllBytes("input.pdf"))) 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Initialize the new instance of the class. The input file stream. Password of the input file. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument(new MemoryStream(File.ReadAllBytes("input.pdf")), "password"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument(New MemoryStream(File.ReadAllBytes("input.pdf")), "password") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Save the document The file path. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Save the document The stream where to save the document. The HTTP response stream object. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; MemoryStream ms = new MemoryStream(); //Save the document loadedDocument.Save(ms, Response); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" Dim ms As MemoryStream = New MemoryStream() 'Save the document loadedDocument.Save(ms, Response) 'Close the document loadedDocument.Close() Save the document The name of the document. The HTTP response stream object. The type of the reading document. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf", Response, HttpReadType.Open); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf", Response, HttpReadType.Open) 'Close the document loadedDocument.Close() Save the document File stream to be stored in the output document. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; MemoryStream ms = new MemoryStream(); //Save the document loadedDocument.Save(ms); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" Dim ms As MemoryStream = New MemoryStream() 'Save the document loadedDocument.Save(ms) 'Close the document loadedDocument.Close() Close all the instance of the XFA document. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Flatten the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Set flatten. loadedDocument.Flatten = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Set flatten. loadedDocument.Flatten = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get value of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get value of the XML Data Package. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Get the XML Data Package XmlDocument xdp = loadedDocument.XmlData; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Get the XML Data Package Dim xdp As XmlDocument = loadedDocument.XmlData 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents field collection of loaded XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Initializes a new instance of the class. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Add the loaded field to the field collection. Get fields name. Add new XFA form fields. The XFA form field to be added in the collection. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("invoice.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Create a new PdfXfaField. PdfXfaTextBoxField field = new PdfXfaTextBoxField("text1", new SizeF(100, 20)); field.Caption.Text = "Text Field"; //Add the text box field to existing field collection. loadedForm.Fields.Add(field); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("invoice.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Create a new PdfXfaField. Dim field As New PdfXfaTextBoxField("text1", New SizeF(100, 20)) field.Caption.Text = "Text Field" 'Add the text box field to existing field collection. loadedForm.Fields.Add(field) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Remove the specified XFA field. The lField item which is to be removed to the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; PdfLoadedXfaForm subform1 = loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = subform1.Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Remove the field. subform1.Remove(loadedTextBox); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm Dim subform1 As PdfLoadedXfaForm = (TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm) 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast(subform1.Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Remove the field. subform1.Remove(loadedTextBox) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Remove the field with specific index. The index of the field has been removed. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Remove the field at index. loadedForm.Fields.RemoveAt(1); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Remove the field at index. loadedForm.RemoveAt(1) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Clear all the fields. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Crear all the fields. loadedForm.Fields.Clear(); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Clear all the fields. loadedForm.Fields.Clear() 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Returns an enumerator that iterates through a collection. Returns an enumerator that iterates through a collection. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("invoice.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; foreach (PdfLoadedXfaField field in loadedForm.Fields) { if(field is PdfLoadedXfaTextBoxField) { (field as PdfLoadedXfaTextBoxField).Text = "Test"; } } //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("invoice.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm For Each field As PdfLoadedXfaField In loadedForm.Fields If TypeOf field Is PdfLoadedXfaTextBoxField Then TryCast(field, PdfLoadedXfaTextBoxField).Text = "Test" End If Next 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Returns field with specified name. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Return's the field with the specified index. Field collection. Gets the field count. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the fields count. int count = loadedForm.Fields.Count; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Gets the fiels count. Dim count As Integer = loadedForm.Fields.Count 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents Loaded XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() current document catalog Represents the XFA array Repersents the XFA image array Loaded pdf document List of XFA fields indicating the field count of the current form Represent the data set writer of XFA XFA document Represents the Data set Document used to indexing purpose denote the node counts Represent the complete field names of the XFA Represents the width of the form. Represents the height of the form. Represents the location of the form. Represents the form visibility. Represents the readonly. Size of the form. Reperesents the XFA form type Represents flatten document. Represents point. Load the XFA documents Save the XFA document save main form Fill and save the subforms and fields Read the main form details Read subForms and fields Get the fields collection by field name Name of the field Collection of XFA fields //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("invoice.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get fields by name. PdfLoadedXfaField[] fields = loadedForm.TryGetFieldsByName("InvoiceNumber[0]"); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("invoice.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get fields by name. Dim fields As PdfLoadedXfaField() = loadedForm.TryGetFieldsByName("InvoiceNumber[0]") 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the XFA field using complete field name complete name of the field Get the XFA field using complete field name Complete name of the field Return the XFA field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("invoice.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get fields by name. PdfLoadedXfaField field = loadedForm.TryGetFieldByCompleteName("form1[0].#subform[0].Header[0].InvoiceNumber[0]"); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("invoice.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get fields by name. Dim fields As PdfLoadedXfaField() = loadedForm.TryGetFieldByCompleteName("form1[0].#subform[0].Header[0].InvoiceNumber[0]") 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Import XFA form data from XML file to Pdf document. The file path of XML file to import //Load the XFA form document PdfLoadedXfaDocument xfaDocument = new PdfLoadedXfaDocument(xfaFormFile); //Import XFA data from xml file xfaDocument.XfaForm.ImportXfaData("Import.xml"); //Save and close the XFA document xfaDocument.Save("Output.pdf"); xfaDocument.Close(); 'Load the XFA form document Dim xfaDocument As PdfLoadedXfaDocument = New PdfLoadedXfaDocument(xfaFormFile) 'Import XFA data from xml file xfaDocument.XfaForm.ImportXfaData("Import.xml") 'Save and close the XFA document xfaDocument.Save("Output.pdf") xfaDocument.Close() stream.Dispose() Import XFA form data from stream to Pdf document. The stream of XFA data to import //Load the XFA PDF document. PdfLoadedXfaDocument xfaDocument = new PdfLoadedXfaDocument(xfaFormFile); //Import XFA data from stream. FileStream fileStream = new FileStream("Import.xml", FileMode.Open); xfaDocument.XfaForm.ImportXfaData(fileStream); //Save and Close the document. xfaDocument.Save("Output.pdf"); xfaDocument.Close(); //Dispose the Stream. fileStream.Dispose(); 'Load the XFA form document Dim xfaDocument As PdfLoadedXfaDocument = New PdfLoadedXfaDocument(xfaFormFile) 'Import XFA data from stream. Dim fileStream As FileStream = New FileStream("Import.xml", FileMode.Open) xfaDocument.XfaForm.ImportXfaData(fileStream) 'Save and Close the document. xfaDocument.Save("Output.pdf") xfaDocument.Close() 'Dispose the Stream. fileStream.Dispose() Export XFA form data from Pdf document to a file in XML format. The name/path of the file to export XFA data //Load the XFA form document PdfLoadedXfaDocument xfaDocument = new PdfLoadedXfaDocument(xfaFormFile); //Export XFA data to xml format in a file xfaDocument.XfaForm.ExportXfaData("Export.xml"); //Save and close the XFA document xfaDocument.Save("Output.pdf"); xfaDocument.Close(); 'Load the XFA form document Dim xfaDocument As PdfLoadedXfaDocument = New PdfLoadedXfaDocument(xfaFormFile) 'Export XFA data to xml format in a file xfaDocument.XfaForm.ExportXfaData("Export.xml") 'Save and close the XFA document xfaDocument.Save("Output.pdf") xfaDocument.Close() stream.Dispose() Export XFA form data from Pdf document to a stream in XML format. The stream to export XFA form data //Load the XFA form document PdfLoadedXfaDocument xfaDocument = new PdfLoadedXfaDocument(xfaFormFile); //Create stream to export the data MemoryStream stream = new MemoryStream(); //Export XFA data to xml format to stream xfaDocument.XfaForm.ExportXfaData(stream); //Save and close the XFA document xfaDocument.Save("Output.pdf"); xfaDocument.Close(); 'Load the XFA form document Dim xfaDocument As PdfLoadedXfaDocument = New PdfLoadedXfaDocument(xfaFormFile) 'Create stream to export the data Dim stream As MemoryStream = New MemoryStream() 'Export XFA data to xml format to stream xfaDocument.XfaForm.ExportXfaData(stream) 'Save and close the XFA document xfaDocument.Save("Output.pdf.pdf") xfaDocument.Close() stream.Dispose() Get the name Save the attributes of the current form Get the complete field names Get complete field names Get the fields by name Save the new XFA fields Get the loaded fields Gets or sets the field is readonly //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Set readonly. loadedForm.ReadOnly = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Set readonly. loadedForm.ReadOnly = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the visibility of the field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Set visibility. loadedForm.Visibility = PdfXfaVisibility.Visible; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Set visibility. loadedForm.Visibility = PdfXfaVisibility.Visible 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the width //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the form width. float width = loadedForm.Width; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the form width. Dim width As Single = loadedForm.Width 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the height //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the form height. float height = loadedForm.Height; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the form height. Dim height As Single = loadedForm.Height 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the location //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the form location. PointF location = loadedForm.Location; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the form location. Dim loaction As PointF = loadedForm.Location 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents loaded form fields collection. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() catalog of the current document Represents the XFA array Get all the field names //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the field names. string[] fieldNames = loadedForm.FieldNames; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the field names. Dim fieldNames As String() = loadedForm.FieldNames 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gett all the subforms name //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the subform names. string[] subformNames = loadedForm.SubFormNames; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the subform names. Dim subformNames As String() = loadedForm.SubFormNames 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the complete names of the fields //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the complete field names. string[] completeFieldNames = loadedForm.CompleteFieldNames; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the complete field names. Dim completeFieldNames As String() = loadedForm.CompleteFieldNames 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the area name of the form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the area names. string[] areaNames = loadedForm.AreaNames; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the area names. Dim areaNames As String() = loadedForm.AreaNames 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents the loaded list box field of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded list box field. PdfLoadedXfaListBoxField loadedListBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["listBoxField[0]"] as PdfLoadedXfaListBoxField; //Set the list box selected index loadedListBoxField.SelectedIndex = 1; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded list box field. Dim loadedListBoxField As PdfLoadedXfaListBoxField = TryCast(TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm).Fields("listBoxField[0]"), PdfLoadedXfaListBoxField) 'Set the list box selected index loadedListBoxField.SelectedIndex = 1 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the items to multi select //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded list box field. PdfLoadedXfaListBoxField loadedListBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["listBoxField[0]"] as PdfLoadedXfaListBoxField; //Get the selected items. string[] selectedItems = loadedListBoxField.SelectedItems; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded list box field. Dim loadedListBoxField As PdfLoadedXfaListBoxField = TryCast(TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm).Fields("listBoxField[0]"), PdfLoadedXfaListBoxField) 'Get the seleted items. Dim selectedItems As String() = loadedListBoxField.SelectedItems 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the default index of the list box field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded list box field. PdfLoadedXfaListBoxField loadedListBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["listBoxField[0]"] as PdfLoadedXfaListBoxField; //Set the list box selected index loadedListBoxField.SelectedIndex = 1; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded list box field. Dim loadedListBoxField As PdfLoadedXfaListBoxField = TryCast(TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm).Fields("listBoxField[0]"), PdfLoadedXfaListBoxField) 'Set the list box selected index loadedListBoxField.SelectedIndex = 1 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the default value of the list box field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded list box field. PdfLoadedXfaListBoxField loadedListBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["listBoxField[0]"] as PdfLoadedXfaListBoxField; //Set the list box selected value loadedListBoxField.SelectedValue = "English"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded list box field. Dim loadedListBoxField As PdfLoadedXfaListBoxField = TryCast(TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm).Fields("listBoxField[0]"), PdfLoadedXfaListBoxField) 'Set the list box selected value loadedListBoxField.SelectedValue = "English" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the if the field is multi select or not //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded list box field. PdfLoadedXfaListBoxField loadedListBoxField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["listBoxField[0]"] as PdfLoadedXfaListBoxField; //Get the selection mode PdfXfaSelectionMode mode = loadedListBoxField.SelectionMode; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded list box field. Dim loadedListBoxField As PdfLoadedXfaListBoxField = TryCast(TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm).Fields("listBoxField[0]"), PdfLoadedXfaListBoxField) 'Get the seletion mode. Dim mode As PdfXfaSeletionMode = loadedListBoxField.SelectionMode 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents the loaded numeric field of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded numeric field. PdfLoadedXfaNumericField loadedNumericField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["numericField[0]"] as PdfLoadedXfaNumericField; //fill the numeric field loadedNumericField.NumericValue = 945322; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded numeric field. Dim loadedNumericField As PdfLoadedXfaNumericField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("numericField[0]"), PdfLoadedXfaNumericField) 'fill the numeric field loadedNumericField.NumericValue = 945322 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Save acroform textbox field. Gets or sets the Value of the numeric Field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded numeric field. PdfLoadedXfaNumericField loadedNumericField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["numericField[0]"] as PdfLoadedXfaNumericField; //fill the numeric field loadedNumericField.NumericValue = 945322; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded numeric field. Dim loadedNumericField As PdfLoadedXfaNumericField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("numericField[0]"), PdfLoadedXfaNumericField) 'fill the numeric field loadedNumericField.NumericValue = 945322 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the comb cells //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded numeric field. PdfLoadedXfaNumericField loadedNumericField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["numericField[0]"] as PdfLoadedXfaNumericField; //fill the numeric field loadedNumericField.NumericValue = 945322; //Set the comb length. loadedNumericField.CombLenght = 6; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded numeric field. Dim loadedNumericField As PdfLoadedXfaNumericField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("numericField[0]"), PdfLoadedXfaNumericField) 'fill the numeric field loadedNumericField.NumericValue = 945322 'Set the comb length. loadedNumericField.CombLenght = 6 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the numeric field type //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded numeric field. PdfLoadedXfaNumericField loadedNumericField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["numericField[0]"] as PdfLoadedXfaNumericField; //Get the numeric field type. PdfXfaNumericType type = loadedNumericField.FieldType; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded numeric field. Dim loadedNumericField As PdfLoadedXfaNumericField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("numericField[0]"), PdfLoadedXfaNumericField) 'Get the numeric field type. Dim type As PdfXfaNumericType = loadedNumericField.FieldType 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the pattern string //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded numeric field. PdfLoadedXfaNumericField loadedNumericField = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["numericField[0]"] as PdfLoadedXfaNumericField; //Get the pattern string. string pattern = loadedNumericField.PatternString; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded numeric field. Dim loadedNumericField As PdfLoadedXfaNumericField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("numericField[0]"), PdfLoadedXfaNumericField) 'Get the pattern string. Dim pattern As String = loadedNumericField.PatternString 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the content area Represents the radio button field of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the radio button field PdfLoadedXfaRadioButtonField loadedRadioButtonField = loadedRadioButtonGroup.Fields[0] as PdfLoadedXfaRadioButtonField; //Check the radio button loadedRadioButtonField.IsChecked = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the radio button field Dim loadedRadioButtonField As PdfLoadedXfaRadioButtonField = TryCast(loadedRadioButtonGroup.Fields(0), PdfLoadedXfaRadioButtonField) 'Check the radio button loadedRadioButtonField.IsChecked = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the checked state of the radio button //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the radio button field PdfLoadedXfaRadioButtonField loadedRadioButtonField = loadedRadioButtonGroup.Fields[0] as PdfLoadedXfaRadioButtonField; //Check the radio button loadedRadioButtonField.IsChecked = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the radio button field Dim loadedRadioButtonField As PdfLoadedXfaRadioButtonField = TryCast(loadedRadioButtonGroup.Fields(0), PdfLoadedXfaRadioButtonField) 'Check the radio button loadedRadioButtonField.IsChecked = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the radio button size //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the radio button field PdfLoadedXfaRadioButtonField loadedRadioButtonField = loadedRadioButtonGroup.Fields[0] as PdfLoadedXfaRadioButtonField; //Get the radio button size. float size = loadedRadioButtonField.RadioButtonSize; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the radio button field Dim loadedRadioButtonField As PdfLoadedXfaRadioButtonField = TryCast(loadedRadioButtonGroup.Fields(0), PdfLoadedXfaRadioButtonField) 'Get the radio button size. Dim size As Single = loadedRadioButtonField.RadioButtonSize 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the checked styles of the radio button //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the radio button field PdfLoadedXfaRadioButtonField loadedRadioButtonField = loadedRadioButtonGroup.Fields[0] as PdfLoadedXfaRadioButtonField; //Get the checked style. PdfXfaCheckedStyle style = loadedRadioButtonField.CheckedStyle; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the radio button field Dim loadedRadioButtonField As PdfLoadedXfaRadioButtonField = TryCast(loadedRadioButtonGroup.Fields(0), PdfLoadedXfaRadioButtonField) 'Get the checked style Dim style As PdfXfaCheckedStyle = loadedRadioButtonField.CheckedStyle 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the appearance of the radio button //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the radio button field PdfLoadedXfaRadioButtonField loadedRadioButtonField = loadedRadioButtonGroup.Fields[0] as PdfLoadedXfaRadioButtonField; //Get the radio button appearance. PdfXfaCheckBoxAppearance appearance = loadedRadioButtonField.RadioButtonAppearance; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the radio button field Dim loadedRadioButtonField As PdfLoadedXfaRadioButtonField = TryCast(loadedRadioButtonGroup.Fields(0), PdfLoadedXfaRadioButtonField) 'Get the radio button appearance. Dim appearance As PdfXfaCheckBoxAppearance = loadedRadioButtonField.RadioButtonAppearance 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Represents the loaded radio button group of the XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the radio button field PdfLoadedXfaRadioButtonField loadedRadioButtonField = loadedRadioButtonGroup.Fields[0] as PdfLoadedXfaRadioButtonField; //Check the radio button loadedRadioButtonField.IsChecked = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the radio button field Dim loadedRadioButtonField As PdfLoadedXfaRadioButtonField = TryCast(loadedRadioButtonGroup.Fields(0), PdfLoadedXfaRadioButtonField) 'Check the radio button loadedRadioButtonField.IsChecked = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Add Radiobutton fields Read the exclGroup items Set the Default Index Gets or sets the field is readonly //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Set as read only. loadedRadioButtonGroup.ReadOnly = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Set as read only. loadedRadioButtonGroup.ReadOnly = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the visibility of the field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the visibility. PdfXfaVisibility visibility = loadedRadioButtonGroup.Visibility; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the visibility. Dim visibility As PdfXfaVisibility = loadedRadioButtonGroup.Visibility 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the width //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the width. float width = loadedRadioButtonGroup.Width; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the width. Dim width As Single = loadedRadioButtonGroup.Width 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the height //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the height. float height = loadedRadioButtonGroup.Height; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the height. Dim height As Single = loadedRadioButtonGroup.Height 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the location //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the location of the field. PointF location = loadedRadioButtonGroup.Location; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the location of the field. Dim location As PointF = loadedRadioButtonGroup.Location 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Get the list of the . //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the radio button group PdfLoadedXfaRadioButtonGroup loadedRadioButtonGroup = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["radioButtonGroup[0]"] as PdfLoadedXfaRadioButtonGroup; //Get the radio button field PdfLoadedXfaRadioButtonField loadedRadioButtonField = loadedRadioButtonGroup.Fields[0] as PdfLoadedXfaRadioButtonField; //Check the radio button loadedRadioButtonField.IsChecked = true; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the radio button group Dim loadedRadioButtonGroup As PdfLoadedXfaRadioButtonGroup = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("radioButtonGroup[0]"), PdfLoadedXfaRadioButtonGroup) 'Get the radio button field Dim loadedRadioButtonField As PdfLoadedXfaRadioButtonField = TryCast(loadedRadioButtonGroup.Fields(0), PdfLoadedXfaRadioButtonField) 'Check the radio button loadedRadioButtonField.IsChecked = True 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Draw the rectangle field to PDF document. Gets or sets the border Gets or sets the tool tip Gets or sets the cornor shaps Gets or sets the rotation angle Represents the text box field of an existing PDF document`s XFA form. //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Initializes a new instance of the class. Initializes a new instance of the class. The name of the field. The value of the field. Read the text box field. Save the acroform textbox field. save the textBox Gets or sets the maximum width of the text box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set maxium width. loadedTextBox.MaximumWidth = 200; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set maximum width. loadedTextBox.MaximumWidth = 200 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the maximum height of the text box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set maxium height. loadedTextBox.MaximumHeight = 40; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set maximum height. loadedTextBox.MaximumHeight = 40 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the minimum width of the text box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set minimum width. loadedTextBox.MinimumWidth = 100; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set minimum width. loadedTextBox.MinimumWidth = 100 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the minimum height of the textbox //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set minimum height. loadedTextBox.MinimumHeight = 20; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set minimum height. loadedTextBox.MinimumHeight = 20 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the value of the Text Box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //fill the text box loadedTextBox.Text = "First Name"; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'fill the text box loadedTextBox.Text = "First Name" 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the type of the text box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the text box type. PdfXfaTextBoxType type = loadedTextBox.Type; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the text box type. Dim type As PdfXfaTextBoxType = loadedTextBox.Type 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the password char of the text box field //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the password character. char password = loadedTextBox.PasswordCharacter; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the password character. Dim password As Char = loadedTextBox.PasswordCharacter 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the maximum char of the text box //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Set the maximum length. loadedTextBox.MaximumLength = 10; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Set the maximum length. loadedTextBox.MaximumLength = 10 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Gets or sets the comb cells count; //Load the existing PDF document PdfLoadedXfaDocument loadedDocument = new PdfLoadedXfaDocument("input.pdf"); //Load the existing XFA form PdfLoadedXfaForm loadedForm = loadedDocument.XfaForm; //Get the loaded text box field. PdfLoadedXfaTextBoxField loadedTextBox = (loadedForm.Fields["subform1[0]"] as PdfLoadedXfaForm).Fields["text[0]"] as PdfLoadedXfaTextBoxField; //Get the comb length. int combLength = loadedTextBox.CombLength; //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(); 'Load the existing PDF document Dim loadedDocument As New PdfLoadedXfaDocument("input.pdf") 'Load the existing XFA form Dim loadedForm As PdfLoadedXfaForm = loadedDocument.XfaForm 'Get the loaded text box field. Dim loadedTextBox As PdfLoadedXfaTextBoxField = TryCast((TryCast(loadedForm.Fields("subform1[0]"), PdfLoadedXfaForm)).Fields("text[0]"), PdfLoadedXfaTextBoxField) 'Get the comb length. Dim combLength As Integer = loadedTextBox.CombLength 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close() Draw the tex to the PDF document. Gets or sets the text Draw the background color. Draw the edge Get pens dash style. Represents base class of XFDF. Initializes a new instance of the class. The filename. Identify push button field. Identify check box field. Identify radio button field. Identify text field. Identify listbox field. Identify combobox field. Identify signature field. Identify that field has no type. Specifies the format of Export or Import data. //Load an existing document PdfLoadedDocument ldoc = new PdfLoadedDocument("SourceForm.pdf"); // Load the existing form PdfLoadedForm form = ldoc.Form; // Export the form data as XML file form.ExportData("Export.xml", DataFormat.Xml, "SourceForm.pdf"); 'Load an existing document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf") ' Load the existing form Dim form As PdfLoadedForm = ldoc.Form ' Export the form data as XML file form.ExportData("Export.xml", DataFormat.Xml, "SourceForm.pdf") Class Class Specifies XML file format Specifies Forms Data Format file format Specifies XFDF file format. Specifies JSON file format. Specifies Forms Data Format file format Specifies XFDF file format. Specifies JSON file format. Specifies the subject of the Certificate Specifies the issuer of the Certificate You can use this class to replace the system unavailable fonts. Raises after the specified font is not available in the system. specifies the custom size of the converted image. specifies the horizontal DPI of the resultant image. specifies the Vertical DPI of the resultant image. specifies Whether need to maintain the pdf page size. The delegate of the fontnotfound event handler. Replace used fonts for documents Gets the used font from the document. Gets and set the alternate font for the respective fonts. The Syncfusion.Pdf.Parsing namespace contains classes, which are used to load or modify an existing PDF document. Represents a PdfLoadedDocument. You can use this class to load or modify an existing PDF document // Loads an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); lDoc.Save("Output.pdf"); lDoc.Close(true); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") lDoc.Save("Output.pdf") lDoc.Close(True) Class Class String contain either user or owner password. The stream with the document data. Indicates whether the document was encrypted. Indicates whether the document was Pdf Viewer document. Stores loaded form. Collection of loaded and created pages. Bookmarks of the document. Named destination of the document. Indicates whether the stream should be closed on dispose. Indicates whether the object was disposed. Internal stream Defines the color space of the document Defines the attachment collection of the document String contain either user or owner password. Defines the Pdf Page Label. Defined the Pdf Loaded Page Label Collection Check whether the Page Label Enabled or not. Indicates is xfa form or not. Indicates whether PDF document is Extended feature enabled. Holds the file name for file saving operation. Holds the conformance level of the loaded document. Check whether the document is linearized or not. Private variable to store the pdf portfolio Repairing wrong offset values Gets or sets the value whether to skip the changes made in the document to be saved Holds the dublin core values of the loaded document. Internal variable used to store the font information The variable is used to indicate whether resources need to optimize or not The variable is used to hold destination document while merging PDF A relative or absolute path for the file. /// This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight // Loads an existing PDF Document PdfLoadedDocument doc = new PdfLoadedDocument("Input.pdf"); // Save the document to a disk doc.Save("Output.pdf"); doc.Close(true); ' Loads an existing PDF Document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ' Save the document to a disk doc.Save("Output.pdf") doc.Close(True) Class Initializes a new instance of the class with the specified input file path and repair document A relative or absolute path for the file. True to repair the document to prevent document corruption This constructor loads the document and also repairs the wrong offsets. The repairing engine is not capable of fixing all kinds of corruption and the process may delay the loading time depending on the type of issue. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Loads an existing PDF Document PdfLoadedDocument doc = new PdfLoadedDocument("Input.pdf", true); // Save the document to a disk doc.Save("Output.pdf"); doc.Close(true); ' Loads an existing PDF Document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf", True) ' Save the document to a disk doc.Save("Output.pdf") doc.Close(True) Class Initializes a new instance of the class with the specified input file path and password A relative or absolute path for the file. The password (user or owner) of the encrypted document to open. // Load the PDF document with password. PdfLoadedDocument doc = new PdfLoadedDocument("Input.pdf","password"); doc.Save("Output.pdf"); doc.Close(true); ' Load the PDF document with password. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf", "password") doc.Save("Output.pdf") doc.Close(True) This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight Initializes a new instance of the class with the specified password and repair document. A relative or absolute path for the file. The password (user or owner) of the encrypted document to open. True to repair the document to prevent document corruption This constructor loads the document and also repairs the wrong offsets. The repairing engine is not capable of fixing all kinds of corruption and the process may delay the loading time depending on the type of issue. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Load the PDF document with password. PdfLoadedDocument doc = new PdfLoadedDocument("Input.pdf", "password", true); doc.Save("Output.pdf"); doc.Close(true); ' Load the PDF document with password. Dim doc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf", "password", True) doc.Save("Output.pdf") doc.Close(True) Initializes a new instance of the class with the specified byte array. The array of bytes containing the PDF document to load. Stream file2 = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Create a byte array of file stream length byte[] pdfData = new byte[file2.Length]; //Read block of bytes from stream into the byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)); // Load the byte array PdfLoadedDocument doc = new PdfLoadedDocument(pdfData); doc.Save("Output.pdf"); doc.Close(true); Dim file2 As Stream = New FileStream("sample.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Create a byte array of file stream length Dim pdfData() As Byte = New Byte(file2.Length){} 'Read block of bytes From stream Into the Byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)) ' Load the byte array Dim doc As PdfLoadedDocument = New PdfLoadedDocument(pdfData) doc.Save("Output.pdf") doc.Close(True) Initializes a new instance of the class with specified byte array and repair document. The array of bytes containing the PDF document to load. True to repair the document to prevent document corruption This constructor loads the document and also repairs the wrong offsets. The repairing engine is not capable of fixing all kinds of corruption and the process may delay the loading time depending on the type of issue. Stream file2 = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Create a byte array of file stream length byte[] pdfData = new byte[file2.Length]; //Read block of bytes from stream into the byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)); // Load the byte array PdfLoadedDocument doc = new PdfLoadedDocument(pdfData, true); doc.Save("Output.pdf"); doc.Close(true); Dim file2 As Stream = New FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Create a byte array of file stream length Dim pdfData() As Byte = New Byte(file2.Length){} 'Read block of bytes From stream Into the Byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)) ' Load the byte array Dim doc As PdfLoadedDocument = New PdfLoadedDocument(pdfData, True) doc.Save("Output.pdf") doc.Close(True) Initializes a new instance of the class with the specified byte array and password. The array of bytes containing the PDF document to load. The password (user or owner) of the encrypted document. Stream file2 = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Create a byte array of file stream length byte[] pdfData = new byte[file2.Length]; //Read block of bytes from stream into the byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)); // Load the byte array PdfLoadedDocument doc = new PdfLoadedDocument(pdfData,"password"); doc.Save("Output.pdf"); doc.Close(true); Dim file2 As Stream = New FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Create a byte array of file stream length Dim pdfData() As Byte = New Byte(file2.Length){} 'Read block of bytes From stream Into the Byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)) ' Load the byte array Dim doc As PdfLoadedDocument = New PdfLoadedDocument(pdfData,"password") doc.Save("Output.pdf") doc.Close(True) Initializes a new instance of the class. The array of bytes containing the PDF document to load. The password (user or owner) of the encrypted document. True to repair the document to prevent document corruption This constructor loads the document and also repairs the wrong offsets. The repairing engine is not capable of fixing all kinds of corruption and the process may delay the loading time depending on the type of issue. Stream file2 = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Create a byte array of file stream length byte[] pdfData = new byte[file2.Length]; //Read block of bytes from stream into the byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)); // Load the byte array PdfLoadedDocument doc = new PdfLoadedDocument(pdfData,"password",true); doc.Save("Output.pdf"); doc.Close(true); Dim file2 As Stream = New FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Create a byte array of file stream length Dim pdfData() As Byte = New Byte(file2.Length){} 'Read block of bytes From stream Into the Byte array file2.Read(pdfData,0,System.Convert.ToInt32(pdfData.Length)) ' Load the byte array Dim doc As PdfLoadedDocument = New PdfLoadedDocument(pdfData,"password",True) doc.Save("Output.pdf") doc.Close(True) Initializes a new instance of the class with the specified stream. The stream containing the PDF document to load. Stream file2 = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Load the stream PdfLoadedDocument doc = new PdfLoadedDocument(file2); doc.Save("Output.pdf"); doc.Close(true); Dim file2 As Stream = New FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Load the stream Dim doc As PdfLoadedDocument = New PdfLoadedDocument(file2) doc.Save("Output.pdf") doc.Close(True) Initializes a new instance of the class. The stream containing the PDF document to load True to repair the document to prevent document corruption. This constructor loads the document and also repairs the wrong offsets. The repairing engine is not capable of fixing all kinds of corruption and the process may delay the loading time depending on the type of issue. Stream file2 = new FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Load the stream PdfLoadedDocument doc = new PdfLoadedDocument(file2, true); doc.Save("Output.pdf"); doc.Close(true); Dim file2 As Stream = New FileStream("Input.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Load the stream Dim doc As PdfLoadedDocument = New PdfLoadedDocument(file2, True) doc.Save("Output.pdf") doc.Close(True) Initializes a new instance of the class. The stream containing the PDF document to load. The password (user or owner) of the encrypted document. Stream file2 = new FileStream("sample.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Load the stream PdfLoadedDocument doc = new PdfLoadedDocument(file2, "password"); doc.Save("Samplepdf.pdf"); Dim file2 As Stream = New FileStream("sample.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Load the stream Dim doc As PdfLoadedDocument = New PdfLoadedDocument(file2, "password") doc.Save("Samplepdf.pdf") Initializes a new instance of the class. The stream containing the PDF document to load. The password (user or owner) of the encrypted document. True to repair the document to prevent document corruption. Stream file2 = new FileStream("sample.pdf", FileMode.Open, FileAccess.Read, FileShare.Read); // Load the stream PdfLoadedDocument doc = new PdfLoadedDocument(file2, "password", true); doc.Save("Samplepdf.pdf"); Dim file2 As Stream = New FileStream("sample.pdf", FileMode.Open, FileAccess.Read, FileShare.Read) ' Load the stream Dim doc As PdfLoadedDocument = New PdfLoadedDocument(file2, "password", True) doc.Save("Samplepdf.pdf") Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection. Creates the stream. The filename. The proper file stream. Creates the stream. The file content. The proper memory stream. Saves the document into the same stream or file. // Loads an existing document PdfLoadedDocument ldoc = new PdfLoadedDocument("Input.pdf"); ldoc.FileStructure.Version = PdfVersion.Version1_6; // Save the changes in the same document. ldoc.Save(); ldoc.Close(true); ' Loads an existing document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ldoc.FileStructure.Version = PdfVersion.Version1_6 ' Save the changes in the same document. ldoc.Save() ldoc.Close(True) Class Exports the specified page as Image The page index to be converted into image Returns the specified page as Image Exports the specified page as Image The page index to be converted into image Returns the specified page as Image Exports the specified page as Image with respect to dpi specified. The page index to be converted into image The horizontal DPI of the resultant image. The vertical DPI of the resultant image. Returns the specified page as Image with custom resolution Exports the specified page as Image The page index to be converted into image The custom size of the converted image Whether need to maintain the pdf page size Returns the specified page as image with custom size Exports the specified page as Image The page index to be converted into image The custom size of the converted image The horizontal DPI of the resultant image. The vertical DPI of the resultant image. Whether need to maintain the pdf page size Returns the specified page as image with custom size and resolution Exports the specified page as Image The page index to be converted into image Specifies the instance of the imageexportsettingclass Returns the specified page as Image Exports the specified pages as Images The starting page index The ending page index Returns the specified pages as Images Exports the specified pages as Images with respect to dpi specified. The starting page index The ending page index The horizontal DPI of the resultant image. The vertical DPI of the resultant image. Returns the specified pages as Images with custom resolution Exports the specified pages as Images The starting page index The ending page index The custom size of the converted image Whether need to maintain the pdf page size Returns the specified pages as images with custom size Exports the specified pages as Images The starting page index The ending page index The custom size of the converted image The horizontal DPI of the resultant image. The vertical DPI of the resultant image. Whether need to maintain the pdf page size Returns the specified pages as images with custom size and resolution Exports the specified pages as Images The starting page index The ending page index exportSettings used to set image export properties Returns rectangle positions of the text matches for specific page The text to be searched The specified page index Holds the rectangle positions of the text matches Returns the page number and rectangle positions of the text matches The text to be searched Holds the page number and rectangle positions of the text matches Returns the TextSearchResultCollection instance which contains collection of MatchedItemCollection List of items to be searched. Instance of TextSearchResultCollection Returns true if found any match Returns the dictionary of page number and list of text search items in the PDF document. List of items to be searched. The dictionary of page number and list of search results. Returns true if found any match Returns the dictionary of page number and list of captured terms in the PDF document. List of items to be searched. The dictionary of page number and list of search results. Search option to find the texts Returns true if found any match Returns the TextSearchResultCollection instance which contains collection of MatchedItemCollection List of items to be searched. Instance of TextSearchResultCollection If true,then the text search will be performed asynchronously Returns true if found any match Returns the dictionary of page number and list of text search items in the PDF document. List of items to be searched. The dictionary of page number and list of search results. If true,then the text search will be performed asynchronously Returns true if found any match Returns the dictionary of page number and list of captured terms in the PDF document. List of items to be searched. The dictionary of page number and list of search results. Search option to find the texts If true,then the text search will be performed asynchronously Returns true if found any match Convert the existing PDF document to PDF/A document. //Load an existing PDF document PdfLoadedDocument doc = new PdfLoadedDocument("Input.pdf"); //Sample level Font event handling doc.SubstituteFont += LoadedDocument_SubstituteFont; //Convert loaded document to PDF/A document doc.ConvertToPDFA(PdfConformanceLevel.Pdf_A1B); //Save the document doc.Save("Output.pdf"); //Close the document doc.Close(true); 'Load an existing PDF document Dim doc As New PdfLoadedDocument("Input.pdf") doc.SubstituteFont += LoadedDocument_SubstituteFont 'Convert loaded document to PDF/A document doc.ConvertToPDFA(PdfConformanceLevel.Pdf_A1B) 'Save the document doc.Save("Output.pdf") 'Close the document. doc.Close(True) Splits a PDF document into individual pages. The name of the individual destination pages. This method splits a PDF document to individual pages. Each page is named using destFilePattern parameter after which a numeric index is appended. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Loads an existing document PdfLoadedDocument ldoc = new PdfLoadedDocument("Input.pdf"); // Splits the source document ldoc.Split("Output.pdf"); ldoc.Close(true); ' Loads an existing document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ' Splits the source document ldoc.Split("Output.pdf") ldoc.Close(True) Class Splits a PDF document into individual pages The name of the individual destination pages The number that is use as a start point for the page numbering. This method splits a PDF document to individual pages. Each page is named using destFilePattern parameter after which a numeric index is appended. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight // Loads an existing document PdfLoadedDocument ldoc = new PdfLoadedDocument("Form.pdf"); // Splits the source document ldoc.Split("pdfDoc.pdf", 1); ldoc.Close(true); ' Loads an existing document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("Form.pdf") ' Splits the source document ldoc.Split("pdfDoc.pdf", 1) ldoc.Close(True) Creates a new form to the loaded document //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Create form. document.CreateForm(); //Create new text box field. PdfTextBoxField field = new PdfTextBoxField(document.Pages[0], "textBox1"); field.Bounds = new RectangleF(0, 0, 100, 30); field.Text = "Text Box"; //Add fields to form. document.Form.Fields.Add(field); //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Create form. document.CreateForm() 'Create new text box field. Dim field As New PdfTextBoxField(document.Pages(0), "textBox1") field.Bounds = New RectangleF(0, 0, 100, 30) field.Text = "Text Box" 'Add fields to form. document.Form.Fields.Add(field) 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Creates a PDF attachments to the loaded document The collection of attachments in the loaded document. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Create attachment collection. PdfAttachmentCollection collection = document.CreateAttachment(); PdfAttachment attachment = new PdfAttachment("Attachment1.pdf", File.ReadAllBytes("input.pdf")); //Add the attachment to the attachment collection. collection.Add(attachment); //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Create attachment collection. Dim collection As PdfAttachmentCollection = document.CreateAttachment() Dim attachment As New PdfAttachment("Attachment1.pdf", File.ReadAllBytes("input.pdf")) 'Add the attachment to the attachment collection. collection.Add(attachment) 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Creates a bookmarks collection to the loaded document. The collection of bookmarks in the loaded document. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Create bookmark. PdfBookmarkBase bookmark = document.CreateBookmarkRoot(); bookmark.Add("Page1"); //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Create bookmark. Dim bookmark As PdfBookmarkBase = document.CreateBookmarkRoot() bookmark.Add("Page1") 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Creates a named destination collection to the loaded document. The collection of named destination in the loaded document. Saves the PDF document to the specified stream. The stream where to save the PDF document. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); MemoryStream stream = new MemoryStream(); //Save the document. document.Save(stream); //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") Dim stream As New MemoryStream() 'Save the document. document.Save(stream) 'Close the document. document.Close(True) Extract the fonts from the loaded PDF document. Returns the collection of fonts. Class Adds the fields connected to the page. The loaded document. The new page. The lost of the fields. Clones pages and their resource dictionaries and adds them into the document. The loaded document. The page being cloned. The destinations. Gets the form. The proper PdfForm instance. Release all the resource used by the document instance //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceDoc.pdf"); //Creates a new page and adds it as the last page of the document PdfPageBase page = doc.Pages.Add(); //Create Pdf graphics for the page PdfGraphics g = page.Graphics; //Create a solid brush PdfBrush brush = new PdfSolidBrush(Color.Black); float fontSize = 8f; //Set the font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, fontSize); //Draw the text g.DrawString("HelloWorld", font, brush, new RectangleF(47.835f, 236.835f, 564.165f, 553.937f)); doc.Save("Dispose.pdf"); // Dispose the object doc.Dispose(); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") 'Create a page Dim page As PdfPageBase = doc.Pages.Add() 'Create Pdf graphics for the page Dim g As PdfGraphics = page.Graphics 'Create a solid brush Dim brush As PdfBrush = New PdfSolidBrush(Color.Black) Dim fontSize As Single = 8f 'Set the font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, fontSize) 'Draw the text g.DrawString("HelloWorld", font, brush, New RectangleF(47.835f, 236.835f, 564.165f, 553.937f)) doc.Save("Dispose.pdf") ' Dispose the object doc.Dispose() Releases unmanaged and - optionally - managed resources true to release both managed and unmanaged resources; false to release only unmanaged resources. Releases all the resources allocated by this PDF document if set to true the document should close its stream as well. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); MemoryStream stream = new MemoryStream(); //Save the document. document.Save(stream); //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") Dim stream As New MemoryStream() 'Save the document. document.Save(stream) 'Close the document. document.Close(True) Creates a shallow copy of the current document. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("SourceDoc.pdf"); // Clone the existing the document PdfLoadedDocument doc1 = doc.Clone() as PdfLoadedDocument; // Save the cloned document to a disk doc1.Save("ClonedPDF.pdf"); doc1.Close(true); 'Load an existing document Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceDoc.pdf") ' Clone the existing the document Dim doc1 As PdfLoadedDocument = TryCast(doc.Clone(), PdfLoadedDocument) ' Save the cloned document to a disk doc1.Save("ClonedPDF.pdf") doc1.Close(True) Gets the conformance level applied in the loaded document. Returns only levels supported by PdfConformanceLevel enum, otherwise None. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Class Set the Page Label Variable to store document level actions. Creates the bookmark destination dictionary. Hashtable that uses destination as a key and bookmark list as a value. Gets the named destination. The name of the destination. The direct destination. Gets the named destination. The name of the destination. A direct destination. Extracts the destination from dictionary or returns the object. The destination object. The destination array. Loads the document. The file. Check whether the loaded PDF is tagged one. Gets the PDF version Gets the catalog of the loaded document. The PdfCatalog instance. To check the Need Appearance. dictionary Read and parse the document's info dictionary. Checks whether the PDF document was encrypted. True if the document was encrypted. Gets the form dictionary. The form dictionary. Gets the form dictionary. The form dictionary. Get the collection dictionary Appends the new document data. The writer. Copies the old stream. The writer. Exports the annotation data. Output file name. Exporting data format. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Export annotation data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Export annotation data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf) 'Close and dispose the document document.Close(true) document.Dispose() Exports the annotation data. Output file name. Exporting data format. Target file name or path. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Export annotation data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf, "Annotation.Pdf"); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Export annotation data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf, "Annotation.Pdf") 'Close and dispose the document document.Close(true) document.Dispose() Exports the annotation data. Output file name. Exporting data format. Annotation collection to export. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Export selected annotation's data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf, collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Export selected annotation's data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf, collection) 'Close and dispose the document document.Close(true) document.Dispose() Exports the annotation data. Output file name. Exporting data format. Target file name or path. Annotation collection to export. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Export selected annotation's data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf, "Annotation.pdf", collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Export selected annotation's data into FDF/XFDF format document.ExportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf, "Annotation.pdf", collection) 'Close and dispose the document document.Close(true) document.Dispose() Exports the annotation data. Output file stream. Exporting data format. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an instance of MemoryStream MemoryStream stream = new MemoryStream(); //Export annotation data into the memory stream document.ExportAnnotations(stream, AnnotationDataFormat.Fdf); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an instance of MemoryStream Dim stream As New MemoryStream() 'Export annotation data into the memory stream document.ExportAnnotations(stream, AnnotationDataFormat.Fdf) 'Close and dispose the document document.Close(true) document.Dispose() Exports the annotation data. Output file stream. Exporting data format. Target file name or path. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an instance of MemoryStream MemoryStream stream = new MemoryStream(); //Export annotation data into the memory stream document.ExportAnnotations(stream, AnnotationDataFormat.Fdf, "Annotation.pdf"); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an instance of MemoryStream Dim stream As New MemoryStream() 'Export annotation data into the memory stream document.ExportAnnotations(stream, AnnotationDataFormat.Fdf, "Annotation.pdf") 'Close and dispose the document document.Close(true) document.Dispose() Exports the annotation data. Output file stream. Exporting data format. Annotation collection to export. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Initialize an instance of MemoryStream MemoryStream stream = new MemoryStream(); //Export selected annotation's data into FDF/XFDF format document.ExportAnnotations(stream, AnnotationDataFormat.Fdf, collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Initialize an instance of MemoryStream Dim stream As New MemoryStream() 'Export selected annotation's data into FDF/XFDF format document.ExportAnnotations(stream, AnnotationDataFormat.Fdf, collection) 'Close and dispose the document document.Close(true) document.Dispose() Exports the annotation data. Output file stream. Exporting data format. Target file name or path. Annotation collection to export. Returns whether the annotation data is exported or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Initialize an object for export annotation collection PdfExportAnnotationCollection collection = new PdfExportAnnotationCollection(); //Get the first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Add loaded annotations into the export annotation collection collection.Add(page.Annotations[0] as PdfLoadedAnnotation); collection.Add(page.Annotations[1] as PdfLoadedAnnotation); //Initialize an instance of MemoryStream MemoryStream stream = new MemoryStream(); //Export selected annotation's data into FDF/XFDF/Json format document.ExportAnnotations(stream, AnnotationDataFormat.Fdf, "Annotation.pdf", collection); //Close and dispose the document document.Close(true); document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Initialize an object for export annotation collection Dim collection As New PdfExportAnnotationCollection() 'Get the first page from the document Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Add loaded annotations into the export annotation collection collection.Add(TryCast(page.Annotations[0], PdfLoadedAnnotation)) collection.Add(TryCast(page.Annotations[1], PdfLoadedAnnotation)) 'Initialize an instance of MemoryStream Dim stream As New MemoryStream() 'Export selected annotation's data into FDF/XFDF format document.ExportAnnotations(stream, AnnotationDataFormat.Fdf, "Annotation.pdf", collection) 'Close and dispose the document document.Close(true) document.Dispose() Imports the annotation data from FDF/XFDF/Json file. FDF/XFDF file name. Importing data format. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Import annotation data from FDF file document.ImportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf); //Save and close the document document.Save("Output.pdf"); document.Close(true); //dispose the document document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Import annotation data from FDF file document.ImportAnnotations("Annotations.fdf", AnnotationDataFormat.Fdf) Save and close the document 'Close and dispose the document document.Save("Output.pdf") document.Close(true) //dispose the document document.Dispose() Imports the annotation data from FDF/XFDF/Json stream. FDF/XFDF stream. Importing data format. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Import annotation data from FDF stream Stream stream = new FileStream("Annotations.fdf", FileMode.Open, FileAccess.Read, FileShare.Read); document.ImportAnnotations(stream, AnnotationDataFormat.Fdf); //Save and close the document document.Save("Output.pdf"); document.Close(true); //dispose the document document.Dispose(); 'Load an existing document Dim document As New PdfLoadedDocument("Input.pdf") 'Import annotation data from FDF stream Dim stream As Stream = New FileStream("Annotations.fdf", FileMode.Open, FileAccess.Read, FileShare.Read) document.ImportAnnotations(stream, AnnotationDataFormat.Fdf) Save and close the document 'Close and dispose the document document.Save("Output.pdf") document.Close(true) //dispose the document document.Dispose() Gets or sets a value indicating whether this form is XFA Form or AcroForm. Returns true, when the PDF document has extended features enabled, otherwise it returns false. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("input.pdf"); //Get extended feature enabled bool extendedFeature = doc.IsExtendedFeatureEnabled; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("input.pdf") 'Get extended feature enabled. Dim extendedFeature As Boolean = doc.IsExtendedFeatureEnabled doc.Save("output.pdf") doc.Close(true) Gets or sets the compression options. //Load an existing document PdfLoadedDocument doc = new PdfLoadedDocument("input.pdf"); //Create new compression options instance. dfCompressionOptions options = new PdfCompressionOptions(); //Set image compression. options.CompressImages = true; //Set image quality. options.ImageQuality = 50; //Optimize font. options.OptimizeFont = true; //Optimize page contents. options.OptimizePageContents = true; //Remove metadata information. options.RemoveMetadata = true; //Set compression options. doc.CompressionOptions = options; //Save and close the PDF document. doc.Save("output.pdf"); doc.Close(true); 'Load an existing document Dim doc As New PdfLoadedDocument("input.pdf") 'Create new compression options instance. Dim options As New PdfCompressionOptions() 'Set image compression. options.CompressImages = True 'Set image quality. options.ImageQuality = 50 'Optimize font. options.OptimizeFont = True 'Optimize page contents. options.OptimizePageContents = True 'Remove metadata information. options.RemoveMetadata = True 'Set compression options. doc.CompressionOptions = options 'Save and close the PDF document. doc.Save("output.pdf") doc.Close(True) Gets or sets a value of the metadata Dublin core values. Gests or sets the PdfPageLabel for the loaded PDF document page number. // Loads an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Create page label with upper case roman letters and starts with 1 PdfPageLabel label = new PdfPageLabel(); label.NumberStyle = PdfNumberStyle.UpperRoman; label.StartNumber = 1; lDoc.LoadedPageLabel = label; lDoc.Save("Output.pdf"); lDoc.Close(true); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ' Create page label with upper case roman letters and starts with 1 Dim label As PdfPageLabel = New PdfPageLabel() label.NumberStyle = PdfNumberStyle.UpperRoman label.StartNumber = 1 lDoc.LoadedPageLabel = label lDoc.Save("Output.pdf") lDoc.Close(True) Class Class Get and Set the Password. Gets the actions to be performed when the document is opened/closed. This property has impact on javascript actions only. //Load a PDF document PdfLoadedDocument ldoc = new PdfLoadedDocument("Input.pdf"); //Load and change new javascript action to the document ldoc.Actions.AfterOpen = new PdfJavaScriptAction("app.alert(\"Content Changed!\")"); //Save the document ldoc.Save("Output.pdf"); //Close the document ldoc.Close(true); 'Load a PDF document. Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Load and change new javascript action to the document. ldoc.Actions.AfterOpen = new PdfJavaScriptAction("app.alert(\"Content Changed!\")") 'Save the document ldoc.Save("Output.pdf") 'Close the document ldoc.Close(True) Gets the list of attachments embedded in the document. // Loads an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Gets the collection of attachments embedded in the document. PdfAttachmentCollection collection = lDoc.Attachments; // Creating an attachment PdfAttachment attachment = new PdfAttachment("logo.jpeg"); attachment.FileName = "Syncfusion Logo"; // Adding attachments to an existing document collection.Add(attachment); lDoc.Save("Output.pdf"); lDoc.Close(true); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ' Gets the collection of attachments displayed on a PDF page. Dim collection As PdfAttachmentCollection = lDoc.Attachments ' Creating an attachment Dim attachment As PdfAttachment = New PdfAttachment("logo.jpeg") attachment.FileName = "Syncfusion Logo" ' Adding attachments to an existing document collection.Add(attachment) lDoc.Save("Output.pdf") lDoc.Close(True) Class Class Gets or set the portfolio information associated with this document Class Class //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Create a new portfolio document.PortfolioInformation = new PdfPortfolioInformation(); //set the view mode of the portfolio document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Tile; //Create the attachment PdfAttachment pdfFile = new PdfAttachment("CorporateBrochure.pdf"); pdfFile.FileName = "CorporateBrochure.pdf"; //Set the startup document to view document.PortfolioInformation.StartupDocument = pdfFile; //Add the attachment to the document document.Attachments.Add(pdfFile); //Save and close the PDF document. document.Save("output.pdf"); document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Create a new portfolio document.PortfolioInformation = New PdfPortfolioInformation() 'set the view mode of the portfolio document.PortfolioInformation.ViewMode = PdfPortfolioViewMode.Tile 'Create the attachment Dim pdfFile As New PdfAttachment("CorporateBrochure.pdf") pdfFile.FileName = "CorporateBrochure.pdf" 'Set the startup document to view document.PortfolioInformation.StartupDocument = pdfFile 'Add the attachment to the document document.Attachments.Add(pdfFile) 'Save and close the PDF document. document.Save("output.pdf") document.Close(True) Gets or sets the color space of the document. This property can be used to create PDF document in RGB, Grayscale or CMYK color spaces. By default the document uses RGB color space. This property has impact on the new created pages only. // Loads an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Sets the documents colorSpace as GrayScale lDoc.ColorSpace = PdfColorSpace.GrayScale; lDoc.Save("Output.pdf"); lDoc.Close(true); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") 'Sets the documents colorSpace as GrayScale lDoc.ColorSpace = PdfColorSpace.GrayScale lDoc.Save("Output.pdf") lDoc.Close(True) Class Gets the PDF form fields included in the document. // Load the PDF form PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Gets the form from the existing document PdfLoadedForm form = lDoc.Form; // Reading field element PdfLoadedTextBoxField textField = form[0] as PdfLoadedTextBoxField; textField.Text = "Syncfusion"; lDoc.Save("Output.pdf"); lDoc.Close(true); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ' Gets the form from the existing document Dim form As PdfLoadedForm = lDoc.Form ' Reading field element Dim textField As PdfLoadedTextBoxField = TryCast(form(0), PdfLoadedTextBoxField) textField.Text = "Syncfusion" lDoc.Save("Output.pdf") lDoc.Close(True) Class Class Gets the document's collection of pages. // Loads an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Reading page collection from an existing document PdfLoadedPageCollection pageCollection = lDoc.Pages; //Creates a new page pageCollection.Add(); lDoc.Save("Output.pdf"); lDoc.Close(true); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("Input.pdf") ' Reading page collection from an existing document Dim pageCollection As PdfLoadedPageCollection = lDoc.Pages ' Create a page pageCollection.Add() lDoc.Save("Output.pdf") lDoc.Close(True) Class Class Gets the list of bookmarks in the PDF document. // Loads an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("sourceDoc.pdf"); // Reading bookmark collection from an existing document PdfBookmarkBase bm = lDoc.Bookmarks; // Creates a new bookmark PdfBookmark newbm = bm.Add("Chapter1"); newbm.Color = Color.DarkBlue; newbm.TextStyle = PdfTextStyle.Bold; newbm.Destination = new PdfDestination( lDoc.Pages[0]); lDoc.Save("BookMark.pdf"); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("sourceDoc.pdf") ' Reading bookmark collection from an existing document Dim bm As PdfBookmarkBase = lDoc.Bookmarks ' Creates a new bookmark Dim newbm As PdfBookmark = bm.Add("Chapter1") newbm.Color = Color.DarkBlue newbm.TextStyle = PdfTextStyle.Bold newbm.Destination = New PdfDestination(lDoc.Pages(0)) lDoc.Save("BookMark.pdf") Class Class Gets the list of named destinations in the PDF document. // Loads an existing document PdfLoadedDocument lDoc = new PdfLoadedDocument("sourceDoc.pdf"); // Reading named destination collection from an existing document PdfNamedDestinationCollection destinationCollection = lDoc.NamedDestinationCollection; // Creates a new named destination PdfNamedDestination newNamedDestination = new PdfNamedDestination("Chapter1"); newNamedDestination.Destination = new PdfDestination( lDoc.Pages[0]); destinationCollection.Add(newNamedDestination); lDoc.Save("NamedDestination.pdf"); ' Loads an existing document Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("sourceDoc.pdf") ' Reading named destination collection from an existing document Dim destinationCollection As PdfNamedDestinationCollection = lDoc.NamedDestinationCollection ' Creates a new named destination Dim newNamedDestination As PdfNamedDestination = New PdfNamedDestination("Chapter1") newNamedDestination.Destination = New PdfDestination(lDoc.Pages(0)) destinationCollection.Add(newNamedDestination) lDoc.Save("NamedDestination.pdf") Class Class Gets the list of PdfPageTemplateCollection in the PDF document. // Loads an existing PDF Document PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get the first page of the document PdfPageBase page = loadedDocument.Pages[0]; //Create a page template PdfPageTemplate pageTemplate = new PdfPageTemplate(page); //Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate"; //Sets the PdfPageTemplate is visible pageTemplate.IsVisible = true; //Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate); //Save the document loadedDocument.Save("output.pdf"); //Close the document loadedDocument.Close(true); 'Loads an existing PDF Document Dim loadedDocument As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the first page of the document Dim page As PdfPageBase = loadedDocument.Pages(0) 'Create a page template Dim pageTemplate As PdfPageTemplate = New PdfPageTemplate(page) 'Sets the PdfPageTemplate name pageTemplate.Name = "pageTemplate" 'Sets the PdfPageTemplate is visible pageTemplate.IsVisible = True 'Adds the page template loadedDocument.PdfPageTemplates.Add(pageTemplate) 'Save the document loadedDocument.Save("output.pdf") 'Close the document loadedDocument.Close(True) Gets number of pages. Gets the conformance level applied in the loaded document. Returns only levels supported by PdfConformanceLevel enum, otherwise None. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Class //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get the confirmation level. PdfConformanceLevel level = document.Conformance; //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Get the confirmation level. Dim level As PdfConformanceLevel = document.Conformance 'Close the document. document.Close(True) Gets the fonts which are available in the PDF document. Retruns the fonts which are used in the PDF document. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight //Load the existing PDF document PdfLoadedDocument ldoc = new PdfLoadedDocument("input.pdf"); //Get the use fonts PdfUsedFont[] fonts = ldoc.UsedFonts; List<string> usedFontNames = new List<string>(); //Get the used font Names foreach(PdfUsedFont font in fonts) usedFontNames.Add(font.Name); //Close the document ldoc.Close(true); 'Load the existing PDF document Dim ldoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get the use fonts Dim fonts() As PdfUsedFont = ldoc.UsedFonts Dim usedFontNames As List(Of String) = New List(Of String) 'Get the used font Names For Each font As PdfUsedFont In fonts usedFontNames.Add(font.Name) Next 'Close the document ldoc.Close(True) Gets whether the document is linearized or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get the document is linearisze. bool linearizedDocument = document.IsLinearized; //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Get the document is linearisze. Dim linearizedDocument As Boolean = document.IsLinearized 'Close the document. document.Close(True) Gets whether the document has portfolio content or not //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Check portfolio bool portfolio = document.IsPortfolio; //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Check portfolio Dim portfolio As Boolean = document.IsPortfolio 'Close the document. document.Close(True) Gets and Sets the Optimize Identical Content Gets and Sets the Destination document The event raised on Pdf password. // Creates a new document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Subscribe the On pdf password event lDoc.OnPdfPassword += LDoc_OnPdfPassword; //Access the attachments PdfAttachmentCollection attachment=lDoc.Attachments; //Save the document lDoc.save("Ouput.pdf"); // On Pdf Password event handler void LDoc_OnPdfPassword(object sender, OnPdfPasswordEventArgs args) { args.UserPassword = "syncfusion"; } The event raised while starting redaction progress. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); // Get first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; PdfRedaction redaction = new PdfRedaction(new RectangleF(37, 94, 50, 10), System.Drawing.Color.Black); //Adds redaction to the loaded page page.Redactions.Add(redaction); document.RedactionProgress += redaction_TrackProgress; //Save the document document.Save("output.pdf"); document.Close(true); // Event handler for Track redaction process void redaction_TrackProgress(object sender, RedactionProgressEventArgs arguments) { MessageBox.Show(String.Format("Redaction Process " + arguments.Progress + " % completed")); } Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page from the document Dim page As PdfLoadedPage = document.Pages(0) as PdfLoadedPage Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(37,94,50,10),System.Drawing.Color.Black) 'Adds redaction to the loaded page page.Redactions.Add(redaction) document.RedactionProgress += redaction_TrackProgress 'Save the document document.Save("output.pdf") document.Close(True) 'Event handler for Track redaction process Private Sub redaction_TrackProgress(ByVal sender As Object, ByVal arguments As RedactionProgressEventArgs) MessageBox.Show(String.Format("Redaction Process " + arguments.Progress + " % completed")) End Sub The event raised while starting PDF/A conversion progress. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Set the conformance level. loadedDocument.Conformance = PdfConformanceLevel.Pdf_A1B; document.PdfAConversionProgress += pdfAConversion_TrackProgress; //Save the document document.Save("output.pdf"); document.Close(true); // Event handler for Track redaction process void pdfAConversion_TrackProgress(object sender, PdfAConversionProgressEventArgs arguments) { MessageBox.Show(String.Format("Pdf/A conversion Process " + arguments.Progress + " % completed"); } Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Set the conformance level. loadedDocument.Conformance = PdfConformanceLevel.Pdf_A1B document.PdfAConversionProgress += pdfAConversion_TrackProgress 'Save the document document.Save("output.pdf") document.Close(True) 'Event handler for Track redaction process Private Sub pdfAConversion_TrackProgress(ByVal sender As Object, ByVal arguments As PdfAConversionProgressEventArgs) MessageBox.Show(String.Format("Pdf/A conversion Process " + arguments.Progress + " % completed")) End Sub Gets the instance of the class. Gets the document's information such as documents title, keywords, subject etc., //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Get the document information. PdfDocumentInformation inform = document.DocumentInformation; //Get author of the document. string author = inform.Author; MemoryStream stream = new MemoryStream(); //Save the document. document.Save(stream); //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Get the document information. Dim inform As PdfDocumentInformation = document.DocumentInformation 'Get author of the document. Dim author As String = inform.Author Dim stream As New MemoryStream() 'Save the document. document.Save(stream) 'Close the document. document.Close(True) Gets a value indicating whether the document was PDF viewer document. Gets a value indicating whether the document was encrypted. Gets whether the document is encrypted or not. //Load an existing document PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Gets whether the document is encrypted? bool isEncrypted = document.IsEncrypted; MemoryStream stream = new MemoryStream(); //Save the document. document.Save(stream); //Close the document. document.Close(true); 'Load an existing document Dim document As New PdfLoadedDocument("input.pdf") 'Gets whether the document is encrypted? Dim isEncrypted As Boolean = document.IsEncrypted Dim stream As New MemoryStream() 'Save the document. document.Save(stream) 'Close the document. document.Close(True) Delegate for handling Pdf Password. // Creates a new document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Subscribe the On pdf password event lDoc.OnPdfPassword += new OnPdfPasswordEventHandler(LDoc_OnPdfPassword); //Access the attachments PdfAttachmentCollection attachment=lDoc.Attachments; //Save the document lDoc.save("Ouput.pdf"); // On Pdf Password event handler void LDoc_OnPdfPassword(object sender, OnPdfPasswordEventArgs args) { args.UserPassword = "syncfusion"; } Delegate for handling redaction progress. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); // Get first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; PdfRedaction redaction = new PdfRedaction(new RectangleF(37, 94, 50, 10), System.Drawing.Color.Black); //Adds redaction to the loaded page page.Redactions.Add(redaction); document.RedactionProgress += redaction_TrackProgress; //Save the document document.Save("output.pdf"); document.Close(true); // Event handler for Track redaction process void redaction_TrackProgress(object sender, RedactionProgressEventArgs arguments) { MessageBox.Show(String.Format("Redaction Process " + arguments.Progress + " % completed")); } Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page from the document Dim page As PdfLoadedPage = document.Pages(0) as PdfLoadedPage Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(37,94,50,10),System.Drawing.Color.Black) 'Adds redaction to the loaded page page.Redactions.Add(redaction) document.RedactionProgress += redaction_TrackProgress 'Save the document document.Save("output.pdf") document.Close(True) 'Event handler for Track redaction process Private Sub redaction_TrackProgress(ByVal sender As Object, ByVal arguments As RedactionProgressEventArgs) MessageBox.Show(String.Format("Redaction Process " + arguments.Progress + " % completed")) End Sub Delegate for handling PDF/A conversion progress. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Set the conformance level. loadedDocument.Conformance = PdfConformanceLevel.Pdf_A1B; document.PdfAConversionProgress += pdfAConversion_TrackProgress; //Save the document document.Save("output.pdf"); document.Close(true); // Event handler for Track redaction process void pdfAConversion_TrackProgress(object sender, PdfAConversionProgressEventArgs arguments) { MessageBox.Show(String.Format("Pdf/A conversion Process " + arguments.Progress + " % completed"); } Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Set the conformance level. loadedDocument.Conformance = PdfConformanceLevel.Pdf_A1B document.PdfAConversionProgress += pdfAConversion_TrackProgress 'Save the document document.Save("output.pdf") document.Close(True) 'Event handler for Track redaction process Private Sub pdfAConversion_TrackProgress(ByVal sender As Object, ByVal arguments As PdfAConversionProgressEventArgs) MessageBox.Show(String.Format("Pdf/A conversion Process " + arguments.Progress + " % completed")) End Sub Stores info about current node. Internal variable used to store Kids values. Internal variable used to store index value. Initializes a new instance of the class. The kids. Initializes a new instance of the class. The kids. The index. Arguments of Pdf Password. // Creates a new document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Subscribe the On pdf password event lDoc.OnPdfPassword += LDoc_OnPdfPassword; //Access the attachments PdfAttachmentCollection attachment=lDoc.Attachments; //Save the document lDoc.save("Ouput.pdf"); // On Pdf Password event handler void LDoc_OnPdfPassword(object sender, OnPdfPasswordEventArgs args) { args.UserPassword = "syncfusion"; } Gets or sets a value of pdf password. // Creates a new document PdfLoadedDocument lDoc = new PdfLoadedDocument("Input.pdf"); // Subscribe the On pdf password event lDoc.OnPdfPassword += LDoc_OnPdfPassword; //Access the attachments PdfAttachmentCollection attachment=lDoc.Attachments; //Save the document lDoc.save("Ouput.pdf"); // On Pdf Password event handler void LDoc_OnPdfPassword(object sender, OnPdfPasswordEventArgs args) { args.UserPassword = "syncfusion"; } Shows the redaction progress of the PDF document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); // Get first page from the document PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; PdfRedaction redaction = new PdfRedaction(new RectangleF(37, 94, 50, 10), System.Drawing.Color.Black); //Adds redaction to the loaded page page.Redactions.Add(redaction); document.RedactionProgress += redaction_TrackProgress; //Save the document document.Save("output.pdf"); document.Close(true); // Event handler for Track redaction process void redaction_TrackProgress(object sender, RedactionProgressEventArgs arguments) { MessageBox.Show(String.Format("Redaction Process " + arguments.Progress + " % completed")); } Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Get first page from the document Dim page As PdfLoadedPage = document.Pages(0) as PdfLoadedPage Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(37,94,50,10),System.Drawing.Color.Black) 'Adds redaction to the loaded page page.Redactions.Add(redaction) document.RedactionProgress += redaction_TrackProgress 'Save the document document.Save("output.pdf") document.Close(True) 'Event handler for Track redaction process Private Sub redaction_TrackProgress(ByVal sender As Object, ByVal arguments As RedactionProgressEventArgs) MessageBox.Show(String.Format("Redaction Process " + arguments.Progress + " % completed")) End Sub Initializes a new instance of the class. Gets the redaction progress in percentage. Progress constantly increases from 0 to 100. 100 value means that redaction prcoess completed for entire document. Shows the PDF/A conversion progress of the PDF document. PdfLoadedDocument document = new PdfLoadedDocument("input.pdf"); //Set the conformance level. loadedDocument.Conformance = PdfConformanceLevel.Pdf_A1B; document.PdfAConversionProgress += pdfAConversion_TrackProgress; //Save the document document.Save("output.pdf"); document.Close(true); // Event handler for Track redaction process void pdfAConversion_TrackProgress(object sender, PdfAConversionProgressEventArgs arguments) { MessageBox.Show(String.Format("Pdf/A conversion Process " + arguments.Progress + " % completed"); } Dim document As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") 'Set the conformance level. loadedDocument.Conformance = PdfConformanceLevel.Pdf_A1B document.PdfAConversionProgress += pdfAConversion_TrackProgress 'Save the document document.Save("output.pdf") document.Close(True) 'Event handler for Track redaction process Private Sub pdfAConversion_TrackProgress(ByVal sender As Object, ByVal arguments As PdfAConversionProgressEventArgs) MessageBox.Show(String.Format("Pdf/A conversion Process " + arguments.Progress + " % completed")) End Sub Initializes a new instance of the class. Gets the PDF/A conversion progress in percentage. Progress constantly increases from 0 to 100. If the value reaches 100 means, that PDF/A conversion process completed for the entire document. Represents to customize the signature validations. Gets or sets to validate revocation while validating signature. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Signature validation options PdfSignatureValidationOptions options = new PdfSignatureValidationOptions(); // disable revocation status options.ValidateRevocationStatus = false; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(options); // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Signature validation options Dim options As PdfSignatureValidationOptions = New PdfSignatureValidationOptions() ' disable revocation status options.ValidateRevocationStatus = False ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature(options) ' Close the document document.Close(true) Gets or sets to OCSP response data Gets or sets to CRL response data Represents the loaded named destination class. //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get all the named destinations. PdfNamedDestinationCollection namedCollections = loadedDocument.NamedDestinationCollection; //Get the first named destination PdfLoadedNamedDestination namedDestination = namedCollections[0] as PdfLoadedNamedDestination; //Get the destination PdfDestination dest = namedDestination.Destination; //Save and close the document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get all the named destinations. Dim namedCollections As PdfNamedDestinationCollection = loadedDocument.NamedDestinationCollection 'Get the first named destination Dim namedDestination As PdfLoadedNamedDestination = TryCast(namedCollections(0), PdfLoadedNamedDestination) 'Get the destination Dim destination As PdfDestination = namedDestination.Destination 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class Class Class Initializes a new instance of the class. The dictionary. The cross table. Gets the destination. The destination of named destination. Gets or sets the named destination title. A string value which contains the named destination title //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get all the named destinations. PdfNamedDestinationCollection namedCollections = loadedDocument.NamedDestinationCollection; //Get the first named destination PdfLoadedNamedDestination namedDestination = namedCollections[0] as PdfLoadedNamedDestination; //Get the named destination title. string title = namedDestination.Title; //Save and close the document loadedDocument.Save("Output.pdf"); loadedDocument.Close(true); 'Load the PDF document. Dim loadedDocument As New PdfLoadedDocument("Input.pdf") 'Get all the named destinations. Dim namedCollections As PdfNamedDestinationCollection = loadedDocument.NamedDestinationCollection 'Get the first named destination Dim namedDestination As PdfLoadedNamedDestination = TryCast(namedCollections(0), PdfLoadedNamedDestination) 'Get the named destination title. Dim title As String = namedDestination.Title 'Save and close the document loadedDocument.Save("Output.pdf") loadedDocument.Close(True) Class Class Class Initializes a new instance of the class. Initializes a new instance of the class. The dictionary. The data. Gets bytes of the stream. Stream to be converted. Destination bytes. Gets bytes of the stream. Stream to be converted. Indicates whether to write the whole stream. Destination bytes. Converts a stream to bigendian format. A stream containing data. A stream in bigendian format. Writes the specified symbol. The symbol. Writes the specified text. The text. Writes the specified data. The data. Blocks the encryption. Decompresses this instance. Cleares a stream. Saves the object using the specified writer. The writer. Decrypts the data using the specified encryptor. The encryptor. The current object number. Decompresses the stream data. The data to decompress. The filter name. Uncompressed byte array. Returnes a compressor by its name. The name of the compressor. IPDFCompressor interface. Performs postprocessing of the data for the filter specified. The data to process. The filter. Restored data. Normalizes the filter. If the filter array has only one element store that element instead of entire array. Compresses the content if it's required. The writer. The compressed data. Adds a filter to the filter array. Name of the filter. Encrypts the stream content. The data. The writer. The encrypted content. Gets or sets the animation for this 3D artwork. Gets or sets content of this stream. Gets or sets the default view. If there are no views, this value is ignored. If the value is outside of the valid range, the first view is considered to be default. Gets or sets the type of 3DAnnotation. Gets or sets the code to execute when the 3D artwork is instantiated. Javascript code to be executed when the 3D artwork is instantiated. Gets the list of views for this 3D artwork. Gets the internal stream. Gets or sets the data. The modifications of the returned stream have no impact on the real data. Gets or sets compression flag. true if compress; otherwise, false. Gets a value indicating whether the object was encrypted. Gets a value indicating whether this is decrypted. true if decrypted; otherwise, false. The elements of the PDF array. Indicates if the array was changed. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Internal variable to hold PdfCrossTable reference. Internal variable to hold cloned object. Represents the Font array. Initializes a new instance of the class. Initializes a new instance of the class. The array. Initializes a new instance of the class. The list of array. Initializes a new instance of the class. The array. Initializes a new instance of the class. The array. Initializes a new instance of the class. The array. Creates filled PDF array from the rectangle. The rectangle. The filled in PdfArray instance. Creates filled PDF array from the rectangle. The rectangle. The filled in PdfArray instance. Adds the specified element to the PDF array. The element. Adds the specified list of elements to array. The list. Determines whether the specified element is within the array. The element. true if the array contains the specified element; otherwise, false. Inserts the element into the array. Zero-based index of the element in the array. The element that should be added to the array. Checks whether array contains the element. The element object. Index of the element in the array if exists, -1 otherwise. Removes element from the array. The element that should be removed from the array. ReArrange the Nested page kids array To specify the in which sequence the pages are arranged. Remove the element from the array by its index. Zero-based index of the element in the array. Cleares the array. Converts an instance of the PdfArray to the RectangleF. The properly filled RectangleF structure. Saves the object using the specified writer. The writer. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. Marks the object changed. Freezes the changes. The freezer. Gets the number from the array. The index. The proper instance of the PdfNumber. Creates a copy of PdfArray. Gets the at the specified index. Gets the count. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Gets the elements of the Pdf Array Returns PdfCrossTable associated with the object. Returns cloned object. Represents the Font dictionary Gets a value indicating whether this is changed. The value of the PDF boolean. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Initializes a new instance of the class. Initializes a new instance of the class. if it is value, set to true. Creates a copy of PdfBoolean. Saves the object using the specified writer. The writer. Gets or sets the value of this instance. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Returns cloned object. Internal structure describing a pair of Key/Value. Event arguments class. Pdf document writer. Creates the new object. The writer. Gets a document that is currently generating. Delegate type. Implementation of the name object. Start symbol of the name object. PDF special characters. The symbols that are not allowed in PDF names and should be replaced. Value of the element. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Initializes a new instance of the class. Creates object with defined string value. Value of the string. Initializes a new instance of the class. The enum value. Makes the string more correct from the PDF's point of view. The string to normalize as PDF name. The normalized string. Replace a symbol with its code with the precedence of the sharp sign. The string which the symbol should be replaced in. The symbol to replace. Replace some characters with its escape sequences. The string value. Modified string. Encode the PdfName Decode the PdfName Convert to hex value Explicit operator. Converts a string to a PdfName. The string representation of the name. Properly initialized PdfName instance. Gets string representation of the primitive. Compares two PDF names. PDFName to compare The result of comparison. Returns a hash code for the name. The hash code. Compares two names. The name1. The name2. Determines if two names aren't equal. The name1. The name2. Determines if two names are equal. The name1. The name2. Determines if two names aren't equal. The name1. The name2. Saves the name using the specified writer. The writer. Creates a copy of PdfName. Gets or sets the value of the object. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Returns cloned object. Represent the PDF null object. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Initializes a new instance of the class. Saves the object. PDF writer. Creates a copy of PdfNull. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Returns cloned object. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Initializes a new instance of the class. The value. Initializes a new instance of the class. The value. Initializes a new instance of the class. The value. Initializes a new instance of the class. The value. Converts a float value to a string using Adobe PDF rules. The number. Determines the minimum of the three values. The 1st value. The 2nd value. The 3d value. The min value. Determines the maximum of the three values. The 1st value. The 2nd value. The 3d value. The max value. Saves the object. PDF writer. Creates a copy of PdfNumber. Gets or sets the integer value. Gets or sets the float value. Gets or sets a value indicating whether this instance is integer. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Returns cloned object. Represents a PDF reference. Holds the object number. Holds the generation number of the object. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Initialize the class. The object number. The generation number. Initialize the class. The object number. The generation number. Returns a string representing the object. The string. Compares two object. The object to compare with. The result of comparison. Returns a hash code. The hash code. Creates a copy of PdfReference. Compares two reference objects. The first object to compare. The second object to compare. The result of the comparison. Compares two reference objects. The first object to compare. The second object to compare. The result of the comparison. Writes a reference into a PDF document. A PDF writer. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Returns cloned object. Class that is like a reference but during saving it is replaced by a real reference to the object it holds. The object which the reference is of. The cross-reference table, which the object is within. The reference to the object, which was read from the PDF document. The index of the object within the object collection. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Use to avoid multi threading issue Initializes a new instance of the class. The wrapper. Initializes the class instance with an object. The object. Initializes a new instance of the class. The reference. The cross-reference table. Saves the object. A PDF writer. Create a copy of the referenced object. Compares two reference holders. Object to compare. The result of comparison. Returns a hashcode for a hashtable. The hashcode. Compares two reference holders whether they are equal. A reference holder to compare. A reference holder to compare. The result of the comparison. Compares two reference holders whether they are different. A reference holder to compare. A reference holder to compare. The result of the comparison. Gets the object. Gets the object the reference is of. Gets the index of the object. Gets the reference. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Returns cloned object. Implements PDF string object. General markers for string. Hex markers for string. Format of password data. Value indicating whether the string was converted to hex. Value of the object. The byte data of the string. Indicates whether to check if the value has unicode characters. Indicates whether we should convert data to Unicode. Shows if the data of the stream was decrypted. Shows the type of object status whether it is object registered or other status; Indicates if the object is currently in saving state or not. Holds the index number of the object. Internal variable to store the position. Shows if the data of the stream was decrypted. Internal variable to hold PdfCrossTable reference. Internal variable to hold cloned object. Gets a value indicating whether the object is packed or not Initializes a new instance of the class. Creates new PDF string object. Value of the object. Initialize a string from a hex string. The value. if set to true the string has been encrypted. Creates new PDF string object. Value of the object. Converts byte data to string. Bytes to be converted. Destination string. Converts byte data to string. Bytes to be converted. The actual length of the buffer. Destination string. Determines if the string is a unicode one. String value. True if string is in Unicode format; otherwise False. Converts string to array of unicode symbols. String value. Indicates whether we should add Unicode prefix to output data. Array of data in unicode format. FromDate in PDF suitable form. The datetime. Compare two PDF strings by their bytes. The first string. The second string. If the first string is greater then the second one it returns a value greater then 0, if the second string is greater then the first one, it returns a value lower then 0, if both are equal the 0 is returned. Explicit operator. Converts system string into PdfString. The system string. Properly initialized PdfString. Converts PDFString to string. Byte array containing PDF representation of this object. Gets ascii bytes for specified string value. String for which to get bytes. Bytes retrieved from specified text. Converts bytes to string using hex format for representing string. Bytes to be converted. String int hex format. If needed encryption of data, encrypts data and returns new content. Bytes to be encrypted. A PDF document. Encrypted data. Escapes special symbols. Data from which must be escaped special symbols. Data from which are escaped special symbols. Escapes special symbols. Data from which must be escaped special symbols. Data from which are escaped special symbols. Converts hexadecimal digits into a byte array. The string value. The byte array. Parses the hex. The character representing a hex digit. A byte value. Converts hex digits into byte numbers. The hex numbers. The byte array. Converts the Value to array of bytes. An array of bytes. Returns a byta array based on the value. Shows if should be unicode encoding. The byte array. Saves the object using the specified writer. The writer. Forces PdfString to the hex mode. Creates a copy of PdfString. Converts string value to a byte array. The string data. The resulting byte array. Processes the unicode string Decrypts the specified encryptor. The encryptor. The current object number. Gets or sets string value of the object. Gets a value indicating whether string is in hex. Gets a value indicating whether the object is packed or not Gets or sets a value indicating whether to check if the value has unicode characters. Gets or sets value indicating whether we should convert data to Unicode. Gets a flag that shows if the object has been decrypted already. Gets the bytes. Gets or sets the Status of the specified object. Gets or sets a value indicating whether this document is saving or not. Gets or sets the integer value of the specified object. Gets or sets the position of the object. Gets or set the flag indicating whether the string in the stream is decrypted or not. Returns PdfCrossTable associated with the object. Returns cloned object. Gets a value indicating whether the object was encrypted. Shows what encoding must be used. The types of the PDFString data source. Set the Stroking of current graphics state brush color value Set the Non Stroking of current graphics state brush color value Determining valid email address email address to validate true is valid, false if not valid Represents a redactor for a loaded page. //Load the document. PdfLoadedDocument lDoc = new PdfLoadedDocument("input.pdf"); //Get the first page from the document. PdfLoadedPage page = lDoc.Pages[0] as PdfLoadedPage; //Create a redaction object PdfRedaction redaction = new PdfRedaction(new RectangleF(40, 40, 50, 20)); //Add redaction object into redaction collection of loaded page page.Redactions.Add(redaction); //Save and Close the document. lDoc.Save("sample.pdf"); lDoc.Close(true); 'Load the document. Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") //Create a redaction object Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(40, 40, 50, 20)) //Add redaction object into collection page.Redactions.Add(redaction) 'Save the document. lDoc.Save("sample.pdf") lDoc.Close(True) Initializes a new instance of the class. The rectangle bounds to be redact. Initializes a new instance of the class. The rectangle bounds to be redact. The fill color on the redaction bounds. Gets or sets the fill color on the redaction bounds (Read only). //Load the document. PdfLoadedDocument lDoc = new PdfLoadedDocument("input.pdf"); //Get the first page from the document. PdfLoadedPage page = lDoc.Pages[0] as PdfLoadedPage; //Create a redaction object PdfRedaction redaction = new PdfRedaction(new RectangleF(40, 40, 50, 20)); //Set fill color for the redaction bounds redaction.FillColor = System.Drawing.Color.Green; //Add redaction object into redaction collection of loaded page page.Redactions.Add(redaction); //Save and Close the document. lDoc.Save("sample.pdf"); lDoc.Close(true); 'Load the document. Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") //Create a redaction object Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(40, 40, 50, 20)) //Set fill color for the redaction bounds redaction.FillColor = Color.Green //Add redaction object into collection page.Redactions.Add(redaction) 'Save the document. lDoc.Save("sample.pdf") lDoc.Close(True) Gets or sets the appearance on the redaction bounds (Read only). //Load the document. PdfLoadedDocument lDoc = new PdfLoadedDocument("input.pdf"); //Get the first page from the document. PdfLoadedPage page = lDoc.Pages[0] as PdfLoadedPage; //Create a redaction object PdfRedaction redaction = new PdfRedaction(new RectangleF(40, 40, 100, 20)); //Set appearance on the redaction bounds redaction.Appearance.Graphics.DrawString("Redacted", new PdfStandardFont(PdfFontFamily.Helvetica, 10), PdfBrushes.Black, PointF.Empty); //Add redaction object into redaction collection of loaded page page.Redactions.Add(redaction); //Save and Close the document. lDoc.Save("sample.pdf"); lDoc.Close(true); 'Load the document. Dim lDoc As PdfLoadedDocument = New PdfLoadedDocument("input.pdf") //Create a redaction object Dim redaction As PdfRedaction = New PdfRedaction(New RectangleF(40, 40, 100, 20)) //Set appearance on the redaction bounds redaction.Appearance.Graphics.DrawString("Redacted", New PdfStandardFont(PdfFontFamily.Helvetica, 10), PdfBrushes.Black, PointF.Empty) //Add redaction object into collection page.Redactions.Add(redaction) 'Save the document. lDoc.Save("sample.pdf") lDoc.Close(True) Get the object from IPdfPrimitive Get DER ecoded byte Represents the tag of the AsnObject Stream used for encoding Creates a new instance of the Asnobject Creates a new instance of the Asnobject Encodes the AsnObject Input bytes Encoded bytes Get the DER encoded bytes Calculates the correct length of the encoded bytes Updates the message digit Updates the message digit Updates the message digit with block of bytes Retruns the final dighit values Reset Retuns the agorithm name Gets the size in bytes Gets the buffer length Class used for implementing Advanced Encryption Standard algorithm. Initializes a new instance of the Aes class. Key size. Key bytes Encipher 16 bit input 16 bit Input Output value Decipher 16-bit input Dump Dump key. Dump two by two. Possible key sizes. 128-bit. 192-bit. 256-bit. Implements both the 128 bit and 256 bit AES encryption. Block size for 128 bit encryption Aes encryptor Cypher Blocking Chain vector vector that represents next block of the Chain Offset of the initialization vector. Buffer containing the initialization vector Reprents the current process either encryption/decryption Initializes a new instance of the AesEncryptor class. Does the initial AES encryption process in CBC mode. input data stream. Offset of input stream. length of the input stream. output encrypted stream. current offset of the output stream. Does the final encryption after padding (PKCS7 standards). output encrypted stream. current offset of the output stream. Calculates the correct block size for the given input data length length of the data. Calculates the length for padding length of the data. Does Cypher Blocking chain operation and calls for encryption. input data stream. Offset of input stream. output encrypted stream. current offset of the output stream. Add padding in the PKCS7 standards. input data. offset where the padding has to be done. Checks for the padding added in the encrypted cypher. input data. Represents the Asn1Boolean value Creates a new instance of the As1Boolean object boolean value Creates a new instance of the As1Boolean object Bytes containg the boolean value Converts the boolean value to bytes Asn1Boolean object in bytes Encodes as Asn1object Encoded bytes Gets the vector list count Builds the Asnobjects using the tag in the stream Tag of the Object Tag number of the AsnObject byte length Builds the Asnobjects Represents the Asn1Integer Creates a new instance of the As1Integer Asn1Integer value Returns the integer Encoded Bytes Encodes as Asn1Object Encoded bytes Represernts the Asn1Null object Returns null bytes null bytes Encodes as Asn1Object Encoded bytes Seperator in the Oid Represents the object identifier string Creates a new instance of the Asn1ObjectIdentifier Oid String Creates a new instance of the Object Indentifier Oid in bytes Represents the final output stream Creates a new instance of the Asn1OutputStream Parses the given time stamp token AsnObject, either a sequence or set Encoded bytes Parses the time stamp token with the given sequence Asnobject, either a sequence or set Encoded bytes Calculates the correct output length for the given bytes input bytes object containing the Asn1Objects Creates a new instance of the Asn1Sequence Creates a new instance of the Asn1Sequence List containing the AsnObjects Encodes as Asn1Object Encoded bytes Returns the Asn1Objects in the sequence Encodes as Asn1Object Encoded bytes AsnSequence which represents the Algorithm Creates a new instance of the AlgorithmIdentifier class Object Identifeier parameters Encodes as Asn1Object Encoded bytes for when the public key is raw bits... To be signed Return our time as DateTime. A date time. Get the public key of the subject of the certificate. The public key parameters. Return a Der encoded version of this certificate. A byte array. Create loading data from byte array. List of Asn Tags. http://www.obj-sys.com/asn1tutorial/node124.html Represents Cipher Block Chaining Mode Add more seed material to the generator. Add more seed material to the generator. Fill byte array with random values. Fill byte array with random values. initialize the cipher Process blocks Name of the algorithm Get the input size Get output size Initialize the padding Add padding Pad count get the padding name Algorithm available for signatures since PDF 1.3 Algorithm available for signatures since PDF 1.6 Algorithm available for signatures since PDF 1.7 Algorithm available for signatures since PDF 1.7 Algorithm available for signatures since PDF 1.7 Maps the digest IDs with the human-readable name of the digest algorithm. Maps the name of a digest algorithm with its ID. Cryptographic Message Syntax CMS Advanced Electronic Signatures Initalize CMS with content and certificate bytes Represent RSA Message digest signer Signer Utility class contains methods that can not be specifically grouped into other classes. Encryption algorithms class converts encryption algorithms into human-readable forms. Represents the Certificate object. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); //Create new PDF certificate instance. PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "syncfusion"); //Create new PDF signature instance. PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() 'Create new PDF certificate instance. Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "syncfusion") 'Create new PDF signature instance. Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class User's crypt key set. The high word of the dwFlags parameter. The high word of the dwFlags parameter The high word of the dwFlags parameter Encoding type. Encoding type. Encoding type. Structure type. CERT_RDN attribute. Structure contains information for signing messages using a specified signing certificate context. Certificate's version. Certificate's serial number. Certificate's issuer name. Certificate's subject name. Certificate's structure. Signature length. Date and time before which the certificate is not valid. Date and time after which the certificate is not valid. Initializes a new instance of the class with the path to the pfx file and the password. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The path to pfx file. The password for pfx file. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Initializes a new instance of the class with the path to the pfx file and the password. This constructor is not supported in WinRT and Silverlight. The path to pfx file. The password for pfx file. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate(certificateStream, "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate(certificateStream, "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class s Get distinguish attribute collection Adding distinguish string to dictionary Initializes a new instance of the class with the path to the pfx file,password and storageflag This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The path to pfx file. The password for pfx file. The private key storage flag. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123",KeyStorageFlags.DefaultKeySet); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123",KeyStorageFlags.DefaultKeySet) Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Initializes a new instance of the class with the path to the pfx file,password and storageflag This constructor is not supported in WinRT and Silverlight. The path to pfx file. The password for pfx file. The private key storage flag. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate(certificateStream, "123",KeyStorageFlags.DefaultKeySet); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate(certificateStream, "123",KeyStorageFlags.DefaultKeySet) Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Creates new pdf certificate object. The certificate. Initialize the new instance of the class. The X509 certificate. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Create a new PDF certificate instance using X509Certificate2 object. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Create a new PDF certificate instance using X509Certificate2 object. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Finds the certificate by subject. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The store type. The certificate subject. Returns the instance. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Find by subject. PdfCertificate storeCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion"); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, storeCertificate, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Find by subject. Dim storeCertificate As PdfCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion") 'Creates a signature. Dim signature As New PdfSignature(document, page, storeCertificate, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Finds the certificate by subject The Store type Certificate subject The Certificate store Location Returns the instance. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Find by subject. PdfCertificate storeCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion", StoreRegion.LocalMachine); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, storeCertificate, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Find by subject. Dim storeCertificate As PdfCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion", StoreRegion.LocalMachine) 'Creates a signature. Dim signature As New PdfSignature(document, page, storeCertificate, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Returns the Store location. Returns the Store name Finds the certificate by serial number. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The certification system store type. The certificate id. PDF certificate instance. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load an existing PDF certificate. PdfCertificate certificate = new PdfCertificate("certificate.Pfx", "password"); //Get the serial number of the certificate. byte[] data = certificate.SerialNumber; //Get the store certificate. PdfCertificate storeCertificate = PdfCertificate.FindBySerialId(StoreType.MY, data); //Creates a digital signature. PdfSignature signature = new PdfSignature(document, page, storeCertificate, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load an existing PDF certificate. Dim certificate As New PdfCertificate("certificate.Pfx", "password") 'Get the serial number of the certificate. Dim data As Byte() = certificate.SerialNumber 'Get the store certificate. Dim storeCertificate As PdfCertificate = PdfCertificate.FindBySerialId(StoreType.MY, data) 'Creates a digital signature. Dim signature As New PdfSignature(document, page, storeCertificate, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Initializes PdfCertificate object. Initializes PdfCertificate object. Initializes PdfCertificate object. Certificate's structure. Gets signature length. Signature length. Gets signature value. Signature string. Signature value. Retrieves data from the file. Path to the file. Data from the file if found, null otherwise. Converts FILETIME to DataTime. FILETIME struct. DateTime struct. Decodes a structure. Code structure. Decode value. Gets the certificate issuer. The handle of certificate context. Checks whether arrays of bytes are equal. First array. Second array. True if data are equal, False otherwise. Gets the serial number of a certificate.[Read-Only] This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The serial number of the certificate. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load an existing PDF certificate. PdfCertificate certificate = new PdfCertificate("certificate.Pfx", "password"); //Get the serial number of the certificate. byte[] data = certificate.SerialNumber; //Get the store certificate. PdfCertificate storeCertificate = PdfCertificate.FindBySerialId(StoreType.MY, data); //Creates a digital signature. PdfSignature signature = new PdfSignature(document, page, storeCertificate, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load an existing PDF certificate. Dim certificate As New PdfCertificate("certificate.Pfx", "password") 'Get the serial number of the certificate. Dim data As Byte() = certificate.SerialNumber 'Get the store certificate. Dim storeCertificate As PdfCertificate = PdfCertificate.FindBySerialId(StoreType.MY, data) 'Creates a digital signature. Dim signature As New PdfSignature(document, page, storeCertificate, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Certificate's structure. Represent the country name Represent the Organization name Represent the Organization unit name Represent the State name Represent the Locality name Represent the Locality name Represent the SerialNumber Represent the Street name Represent the Title name Represent the Given name Represent the Email address Represent the User ID Represent the Domain Component The Syncfusion.Pdf.Security namespace contains classes for creating protected PDF document. Represents a digital signature used for signing a PDF document. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Holds signature dictionary. Holds pdf signature field. Holds pdf Loaded signature field. Holds pdf certificate. Reason of signing. Page on which signature field is initialized. The CPU host name or physical location of the signing. Information provided by the signer to enable a recipient to contact the signer to verify the signature; for example, a phone number. Holds a value which indicates certefication of the document. Permissions of the certificated document. Holds timestamping server Document that holds page and this signature. That document should be signed. Indicates whether the signature corresponds to signature field or not. Note : We draw appearance in the case of signature field. Indicates whether the signature contains time stamp alone. Initializes a new instance of the class. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. Initializes a new instance of the class with the page, certificate and the signature name. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The current pdf page where signature will be replaced. The pdf certificate. Name of the signature. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") Class Class Class Class Initializes a new instance of the class with the page, certificate and the signature name. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The current pdf page where signature will be replaced. Name of the signature. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(page, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(page, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") Class Class Class Class Initializes a new instance of the class with the PDF document, page, certificate and the signature name. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The document, which has the page. The page. The certificate. The name of the signature. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") Class Class Class Class Initializes a new instance of the class with the PDF document, page, certificate , signature name and the signature field. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The loaded document, which has the page. The page. The certificate. The name of the signature. The name of the loaded signature field // Creates a new document PdfLoadedDocument doc = new PdfLoadedDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfLoadedSignatureField signatureField = loadedDocument.Form.Fields["Signature"] as PdfLoadedSignatureField; PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature",signatureField); doc.Save("SignedPdfSample.pdf"); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signatureField as PdfLoadedSignatureField = TryCast(loadedDocument.Form.Fields["Signature"],PdfLoadedSignature) Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature",signatureField) doc.Save("SignedPdfSample.pdf") Class Class Class Class To create Layer structure validate signature Apperance Set matrix for appearance To calcualte the Adobe signature appearance scale , width and height To check annotation last elements have signature field Create Long Term Validation of the signature. X509 certificate data //Load the PDF document. PdfLoadedDocument loadedDocument = new PdfLoadedDocument("input.pdf"); //Get the existing page. PdfLoadedPage page = loadedDocument.Pages[0] as PdfLoadedPage; //Create a new PdfSignature instance. PdfSignature signature = new PdfSignature(loadedDocument, page, null, "Sig1"); //Create LTV with X509 public certificates. signature.CreateLtv(certificates); //Save and close the PDF document. loadedDocument.Save("output.pdf"); loadedDocument.Close(true); Get LTV from x509Certificate with OCSP Response Add External Signer for signature Copy source data to destination Move to the file location Get OCSP resposne data Get DSS details by creating crl collection Get DSS details and update dss information in the dictionary Create LTV for external signer Handles the BeginSave event of the catalog document. NOTE: Needed for certifying pdf document. The source of the event. The instance containing the event data. Handles the BeginSave event of the Dictionary control. The source of the event. The instance containing the event data. The event raised on the time of signing certificate to the PDF document. //Load the existing PDF documnt. PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Get the page. PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Create a new PDF signature instance. PdfSignature signature = new PdfSignature(document, page, null, "Sig1"); //Set the signature bounds. signature.Bounds = new RectangleF(0, 0, 200, 100); //Call the compute hash event. signature.ComputeHash += Signature_ComputeHash; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); //ComputeHash event handler. private void Signature_ComputeHash(object sender, PdfSignatureEventArgs ars) { //Get the document bytes. byte[] documentBytes = ars.Data; //Generate hash. byte[] hash = SHA256.Create().ComputeHash(ars.Data); //Include the signed data to PDF. ars.SignedData = GetSignature(hash); } 'Load the existing PDF documnt. Dim document As New PdfLoadedDocument("Input.pdf") 'Get the page. Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Create a new PDF signature instance. Dim signature As New PdfSignature(document, page, Nothing, "Sig1") 'Set the signature bounds. signature.Bounds = New RectangleF(0, 0, 200, 100) 'Call the compute hash event. AddHandler signature.ComputeHash , AddressOf Signature_ComputeHash 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) //ComputeHash event handler. Private Sub Signature_ComputeHash(ByVal sender As Object, ByVal ars As PdfSignatureEventArgs) 'Get the document bytes. Dim documentBytes As Byte() = ars.Data 'Generate hash. Dim hash As Byte() = SHA256.Create().ComputeHash(ars.Data) 'Include the signed data to PDF. ars.SignedData = GetSignature(hash) End Sub Gets the signature Appearance.[Read-Only] This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. A object defines signature`s appearance. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); PdfAppearance appearance = signature.Appearence; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") Dim appearance As PdfAppearance = signature.Appearence signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets the signature Appearance.[Read-Only] This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. A object defines signature`s appearance. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); PdfAppearance appearance = signature.Appearence; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") Dim appearance As PdfAppearance = signature.Appearence signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets signature location on the PDF page. This porperty is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Location = new PointF(100, 200); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Location = New PointF(100, 200) signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets bounds of the signature. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Location = new PointF(100, 200); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Location = New PointF(100, 200) signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets information provided by the signer to enable a recipient to contact the signer to verify the signature; for example, a phone number. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.ContactInfo = "Syncfusion"; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.ContactInfo = "Syncfusion" signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets reason of signing. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Reason = "PDF is signed"; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Reason = "PDF is signed" signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets the physical location of the signing. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.LocationInfo = "US"; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.LocationInfo = "US" signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets a value indicating certificate document or not. NOTE: Works only with Adobe Reader 7.0.8 or higher. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. certificate document if true. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Certificated = true; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Certificated = True signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets the permission for certificated document. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. The document permission. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.DocumentPermissions = PdfCertificationFlags.AllowComments; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.DocumentPermissions = PdfCertificationFlags.AllowComments signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets the signing certificate. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.ContactInfo = "Syncfusion"; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.ContactInfo = "Syncfusion" signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Get or Set LTV to signed document. Gets a value indicating whether signature visible or not.[Read-Only] Signature can be set as invisible when its size is set to empty. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Visible = false; signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Visible = False signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Gets or sets time stamping server unique resource identifier. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Add time stamp. signature.TimeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com"), "user", "123456"); //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Add time stamp. signature.TimeStampServer = New TimeStampServer(New Uri("http://syncfusion.digistamp.com"), "user", "123456") 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets pdf signature field. Gets whether to draw signature appearance or not. Gets or sets the signature validation appearance // Creates a new document PdfDocument document = new PdfDocument(); //Its handle the rotation on signature annoatation document.PageSettings.Rotate = PdfPageRotateAngle.RotateAngle90; PdfPageBase page = document.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate(@"PDF.pfx", "syncfusion"); PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new Rectangle(10, 20, 400, 200); //set the signature validation appearance is true to update Adobe signature validation during runtime signature.EnableValidationAppearance = true; document.Save("Output.pdf"); document.Close(); /// ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'set the signature validation appearance is true to update Adobe signature validation during runtime signature.EnableValidationAppearance = true; document.Save("output.pdf") 'Close the document. document.Close(True) Get signed Date Gets or sets the signed name // Creates a new document PdfDocument document = new PdfDocument(); // Add a new page PdfPageBase page = document.Pages.Add(); // Create a PDF certificate PdfCertificate pdfCert = new PdfCertificate(@"PDF.pfx", "syncfusion"); // Add a new signature to the PDF page PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new Rectangle(10, 20, 400, 200); // Set the signed name signature.SignedName = "Syncfusion Signature"; // Save and close the document document.Save("Output.pdf"); document.Close(True); /// ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPageBase = document.Pages.Add() 'Create a PDF certificate Dim pdfCert As New PdfCertificate(@"PDF.pfx", "syncfusion") 'Add a new signature to the PDF page Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = new Rectangle(10, 20, 400, 200) 'Set the signed name signature.SignedName = "Syncfusion Signature" 'Save and close the document document.Save("Output.pdf") 'Close the document. document.Close(True) Returns external OCSP bytes Returns external CRL bytes Returns external signer Returns external public certificates Sets the estimated size of the signature. The estimated size is the size that will be reserved in the PDF document before digitally signing it. This size corresponds only to the Contents field of the signature field. The range between 0 to 536,870,911 // Creates a new document PdfDocument document = new PdfDocument(); // Add a new page PdfPageBase page = document.Pages.Add(); // Create a PDF certificate PdfCertificate pdfCert = new PdfCertificate(@"PDF.pfx", "syncfusion"); // Add a new signature to the PDF page PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new Rectangle(10, 20, 400, 200); // Set the estimated signature size signature.EstimatedSignatureSize = 20000; // Save and close the document document.Save("Output.pdf"); document.Close(True); /// ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPageBase = document.Pages.Add() 'Create a PDF certificate Dim pdfCert As New PdfCertificate(@"PDF.pfx", "syncfusion") 'Add a new signature to the PDF page Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = new Rectangle(10, 20, 400, 200) 'Set the estimated signature size signature.EstimatedSignatureSize = 20000 'Save and close the document document.Save("Output.pdf") 'Close the document. document.Close(True) Delegate for handling PdfSignatureEventArgs The sender of the event. The argument of the event Represents the arguments of PdfSignature event. //Load the existing PDF documnt. PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Get the page. PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Create a new PDF signature instance. PdfSignature signature = new PdfSignature(document, page, null, "Sig1"); //Set the signature bounds. signature.Bounds = new RectangleF(0, 0, 200, 100); //Call the compute hash event. signature.ComputeHash += Signature_ComputeHash; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); //ComputeHash event handler. private void Signature_ComputeHash(object sender, PdfSignatureEventArgs ars) { //Get the document bytes. byte[] documentBytes = ars.Data; //Generate hash. byte[] hash = SHA256.Create().ComputeHash(ars.Data); //Include the signed data to PDF. ars.SignedData = GetSignature(hash); } 'Load the existing PDF documnt. Dim document As New PdfLoadedDocument("Input.pdf") 'Get the page. Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Create a new PDF signature instance. Dim signature As New PdfSignature(document, page, Nothing, "Sig1") 'Set the signature bounds. signature.Bounds = New RectangleF(0, 0, 200, 100) 'Call the compute hash event. AddHandler signature.ComputeHash , AddressOf Signature_ComputeHash 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) //ComputeHash event handler. Private Sub Signature_ComputeHash(ByVal sender As Object, ByVal ars As PdfSignatureEventArgs) 'Get the document bytes. Dim documentBytes As Byte() = ars.Data 'Generate hash. Dim hash As Byte() = SHA256.Create().ComputeHash(ars.Data) 'Include the signed data to PDF. ars.SignedData = GetSignature(hash) End Sub Current PDF document range data for computing hash. //Load the existing PDF documnt. PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Get the page. PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Create a new PDF signature instance. PdfSignature signature = new PdfSignature(document, page, null, "Sig1"); //Set the signature bounds. signature.Bounds = new RectangleF(0, 0, 200, 100); //Call the compute hash event. signature.ComputeHash += Signature_ComputeHash; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); //ComputeHash event handler. private void Signature_ComputeHash(object sender, PdfSignatureEventArgs ars) { //Get the document bytes. byte[] documentBytes = ars.Data; //Generate hash. byte[] hash = SHA256.Create().ComputeHash(ars.Data); //Include the signed data to PDF. ars.SignedData = GetSignature(hash); } 'Load the existing PDF documnt. Dim document As New PdfLoadedDocument("Input.pdf") 'Get the page. Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Create a new PDF signature instance. Dim signature As New PdfSignature(document, page, Nothing, "Sig1") 'Set the signature bounds. signature.Bounds = New RectangleF(0, 0, 200, 100) 'Call the compute hash event. AddHandler signature.ComputeHash , AddressOf Signature_ComputeHash 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) //ComputeHash event handler. Private Sub Signature_ComputeHash(ByVal sender As Object, ByVal ars As PdfSignatureEventArgs) 'Get the document bytes. Dim documentBytes As Byte() = ars.Data 'Generate hash. Dim hash As Byte() = SHA256.Create().ComputeHash(ars.Data) 'Include the signed data to PDF. ars.SignedData = GetSignature(hash) End Sub Signed document data. //Load the existing PDF documnt. PdfLoadedDocument document = new PdfLoadedDocument("Input.pdf"); //Get the page. PdfLoadedPage page = document.Pages[0] as PdfLoadedPage; //Create a new PDF signature instance. PdfSignature signature = new PdfSignature(document, page, null, "Sig1"); //Set the signature bounds. signature.Bounds = new RectangleF(0, 0, 200, 100); //Call the compute hash event. signature.ComputeHash += Signature_ComputeHash; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); //ComputeHash event handler. private void Signature_ComputeHash(object sender, PdfSignatureEventArgs ars) { //Get the document bytes. byte[] documentBytes = ars.Data; //Generate hash. byte[] hash = SHA256.Create().ComputeHash(ars.Data); //Include the signed data to PDF. ars.SignedData = GetSignature(hash); } 'Load the existing PDF documnt. Dim document As New PdfLoadedDocument("Input.pdf") 'Get the page. Dim page As PdfLoadedPage = TryCast(document.Pages(0), PdfLoadedPage) 'Create a new PDF signature instance. Dim signature As New PdfSignature(document, page, Nothing, "Sig1") 'Set the signature bounds. signature.Bounds = New RectangleF(0, 0, 200, 100) 'Call the compute hash event. AddHandler signature.ComputeHash , AddressOf Signature_ComputeHash 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) //ComputeHash event handler. Private Sub Signature_ComputeHash(ByVal sender As Object, ByVal ars As PdfSignatureEventArgs) 'Get the document bytes. Dim documentBytes As Byte() = ars.Data 'Generate hash. Dim hash As Byte() = SHA256.Create().ComputeHash(ars.Data) 'Include the signed data to PDF. ars.SignedData = GetSignature(hash) End Sub Represents signature dictionary. Name of type Name of the filter. Name of the filter. Name of the document type. Name of the taransformation parameters. Holds pdf document for siging. Holds pdf signature object. Holds pdf certificate object. First range length; Second range index. Start position byte range. Position of the digest value for docMDP method. Position of the digest value for FieldMDP method. Internal variable to store dictionary. Identifying the certificate chain Representing the PDF stream Inicates the range values Creates new pdf signature dictionary object. The pdf document for signing. The pdf signature. The pdf certificate. Creates new pdf signature dictionary object. The pdf document for signing. Initializes a new instance of the class with specified document and signature. The pdf document for signing. The signature to be added into the dictionary Adds required items. Adds optional items. Adds the location. Adds the contact info. Adds required items to annotation dictionary. Adds signed name to signature dictionary. Adds required items to annotation dictionary. Adds optional items to annotation dictionary. Adds required items to annotation dictionary. Adds required items to annotation dictionary. Adds required items to annotation dictionary. Adds required items to annotation dictionary. Allow single instance of MDP signature. true if allow; otherwise, false. Adds the certification dictionary. The writer. Event handler of document saved. Sender of the event. Event data. Saves range item. Writer object. item value. Position for save. Point for save next item. Adds the certefication reference. Creates timestamp request in ASN.1 format. SHA1 hash of data which need to be timestamped. Stream where request will be written. Request length Handles the BeginSave event of the pdf signature dictionary object. The source of the event. The events arguments. Gets or sets a value indicating whether this is archive. true if archive; otherwise, false. Gets the element. Computing hash for Pdf digital signature. Array of objects for hashing. Contains ID's of Pdf objects. Creating hashing object. Hashes the document. The PdfDocument. The hash byte array. Hashes the signature field. The page where signature is located. Hashes the dictionary item. The PdfDictionary. The dictionary item. The crypto context. The list of the Pdf objects. Hashes the name of the dictionary. The PdfDictionary. The name of the dictionary. The crypto context. The list of the Pdf objects. Is dictionary inheritable. If dictionary is null then hash either null. Returns state of the hashing. Hashes the Pdf object. The object to hash. The crypto context. The list of the Pdf objects. Hashes the page. The current page for hashing. The crypto context. The list of the Pdf objects. Hashes the pages. The collection of Pdf pages. The crypto context. The list of the Pdf objects. Hashes the field. The PdfField. The crypto context. The list. Hashes the action. The PdfAction. The crypto context. The list of the Pdf objects. Hashes the annotations. The current page. The crypto context. The list of the Pdf objects. Hashes the annotation. The dictionary. The crypto context. The list of the Pdf objects. Hashes the embedded files. The dictionary. The crypto context. The list of the Pdf objects. Converts little endian characters to big endian. The input buffer. SHA1 message digest algorithm SHA256 message digest algorithm SHA384 message digest algorithm SHA512 message digest algorithm RIPEMD160 message digest algorithm Cryptographic Message Syntax CMS Advanced Electronic Signatures Specifies the certificate's revocation status. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the revocation result RevocationResult revocationResult = result.RevocationResult; // Gets the OCSP revocation status RevocationStatus revocationStatus = revocationResult.OcspRevocationStatus; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the revocation result Dim revocationResult As RevocationResult = result.RevocationResult ' Gets the OCSP revocation status Dim revocationStatus As RevocationStatus = revocationResult.OcspRevocationStatus ' Close the document document.Close(true) Specifies Default / No status. Specifies good status. Specifies unknown status. Specifies revoked status. Specifies the certificate's verification status. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the signature validation status SignatureStatus status = result.SignatureStatus; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the signature validation status Dim status As SignatureStatus = result.SignatureStatus ' Close the document document.Close(true) Specifies unknown status. Specifies valid status. Specifies invalid status. Specifies the signatures's validation result. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Close the document document.Close(true) Gets the name of the signature field. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the name of the signature field string name = result.SignatureName; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the name of the signature field Dim name As string = result.SignatureName ' Close the document document.Close(true) Gets the certificate's verification status. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the signature validation status SignatureStatus status = result.SignatureStatus; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the signature validation status Dim status As SignatureStatus = result.SignatureStatus ' Close the document document.Close(true) Gets the resultant data of certificate revocation validation. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the revocation result RevocationResult revocationResult = result.RevocationResult; // Gets the value indicating whether the CRL is revoked or not bool hasRevokedCrl = revocationResult.IsRevokedCRL; // Gets the OCSP revocation status RevocationStatus revocationStatus = revocationResult.OcspRevocationStatus; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the revocation result Dim revocationResult As RevocationResult = result.RevocationResult ' Gets the value indicating whether the CRL is revoked or not Dim hasRevokedCrl As Boolean = revocationResult.IsRevokedCRL ' Gets the OCSP revocation status Dim revocationStatus As RevocationStatus = revocationResult.OcspRevocationStatus ' Close the document document.Close(true) Gets a value to check whether the document is modified or not // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Checks whether the document is modified or not bool isDocumentModified = result.IsDocumentModified; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Checks whether the document is modified or not Dim isDocumentModified As Boolean = result.IsDocumentModified ' Close the document document.Close(true) Gets a value to check whether the signature is certificated or not // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Checks whether the signature is certificated or not bool isCertificated = result.IsCertificated; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Checks whether the signature is certificated or not Dim isCertificated As Boolean = result.IsCertificated ' Close the document document.Close(true) Gets a value to check whether the signature valid at signed time // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Checks whether the signature is valid at the time of signing bool isValidAtSignedTime = result.IsValidAtSignedTime; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Checks whether the signature is valid at the time of signing Dim isValidAtSignedTime As Boolean = result.IsValidAtSignedTime ' Close the document document.Close(true) Gets a value to check whether the signature valid at current time // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Checks whether the signature is valid at current time bool isValidAtCurrentTime = result.IsValidAtCurrentTime; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Checks whether the signature is valid at current time Dim isValidAtCurrentTime As Boolean = result.IsValidAtCurrentTime ' Close the document document.Close(true) Gets a value to check whether the signature valid at timestamp time // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Checks whether the signature is valid at timestamp time bool isValidAtTimeStampTime = result.IsValidAtTimeStampTime; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Checks whether the signature is valid at timestamp time Dim isValidAtTimeStampTime As Boolean = result.IsValidAtTimeStampTime ' Close the document document.Close(true) Gets a value to check whether the signature is valid or not // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Checks whether the signature is valid or not bool isSignatureValid = result.IsSignatureValid; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Checks whether the signature is valid or not Dim isSignatureValid As Boolean = result.IsSignatureValid ' Close the document document.Close(true) Gets the cryptographic standard used in the signature // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the cryptographic standard used in the signature CryptographicStandard cryptographicStandard = result.CryptographicStandard; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the cryptographic standard used in the signature Dim cryptographicStandard As CryptographicStandard = result.CryptographicStandard ' Close the document document.Close(true) Gets the signature algorithm used // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the signature algorithm used string signatureAlgorithm = result.SignatureAlgorithm; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the signature algorithm used Dim signatureAlgorithm As string = result.SignatureAlgorithm ' Close the document document.Close(true) Gets the digestion algorithm used in the signature // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the digestion algorithm used in the signature DigestAlgorithm digestAlgorithm = result.DigestAlgorithm; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the digestion algorithm used in the signature Dim digestAlgorithm As DigestAlgorithm = result.DigestAlgorithm ' Close the document document.Close(true) Gets the list of certificates in the signature // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the list of certificates in the signature X509Certificate2Collection certificates = result.Certificates; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the list of certificates in the signature Dim certificates As X509Certificate2Collection = result.Certificates ' Close the document document.Close(true) Gets the timestamp information from the signature // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the timestamp information from the signature TimeStampInformation timeStampInformation = result.TimeStampInformation; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the timestamp information from the signature Dim timeStampInformation As TimeStampInformation = result.TimeStampInformation ' Close the document document.Close(true) Represents a resultant data of certificate revocation validation. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the revocation result RevocationResult revocationResult = result.RevocationResult; // Gets the value indicating whether the CRL is revoked or not bool hasRevokedCrl = revocationResult.IsRevokedCRL; // Gets the OCSP revocation status RevocationStatus revocationStatus = revocationResult.OcspRevocationStatus; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the revocation result Dim revocationResult As RevocationResult = result.RevocationResult ' Gets the value indicating whether the CRL is revoked or not Dim hasRevokedCrl As Boolean = revocationResult.IsRevokedCRL ' Gets the OCSP revocation status Dim revocationStatus As RevocationStatus = revocationResult.OcspRevocationStatus ' Close the document document.Close(true) Represents a resultant data of certificate revocation validation. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the value indicating whether the CRL is revoked or not bool hasRevokedCrl = revocationResult.IsRevokedCRL; // Gets the OCSP revocation status RevocationStatus revocationStatus = revocationResult.OcspRevocationStatus; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the value indicating whether the CRL is revoked or not Dim hasRevokedCrl As Boolean = revocationResult.IsRevokedCRL ' Gets the OCSP revocation status Dim revocationStatus As RevocationStatus = revocationResult.OcspRevocationStatus ' Close the document document.Close(true) Represents a resultant data of certificate revocation validation. // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the revocation result RevocationResult revocationResult = result.RevocationResult; // Gets the OCSP revocation status RevocationStatus revocationStatus = revocationResult.OcspRevocationStatus; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the revocation result Dim revocationResult As RevocationResult = result.RevocationResult ' Gets the OCSP revocation status Dim revocationStatus As RevocationStatus = revocationResult.OcspRevocationStatus ' Close the document document.Close(true) Specifies the Pdf signature validation exception. Gets or Set Signature validation exception type Specifies the Signature validation exception type Interface for external signing to a PDF document Returns Signed Message Digest Get HashAlgorithm Specifies the timestamp information from the signature // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the timestamp information from the signature TimeStampInformation timeStampInformation = result.TimeStampInformation; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the timestamp information from the signature Dim timeStampInformation As TimeStampInformation = result.TimeStampInformation ' Close the document document.Close(true) Gets the timestamp policy ID // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the timestamp information from the signature TimeStampInformation timeStampInformation = result.TimeStampInformation; // Gets the timestamp policy ID string timeStampPolicyId = timeStampInformation.TimeStampPolicyId; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the timestamp information from the signature Dim timeStampInformation As TimeStampInformation = result.TimeStampInformation ' Gets the timestamp policy ID Dim timeStampPolicyId As string = timeStampInformation.TimeStampPolicyId ' Close the document document.Close(true) Gets the timestamp time // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the timestamp information from the signature TimeStampInformation timeStampInformation = result.TimeStampInformation; // Gets the timestamp time DateTime timeStampTime = timeStampInformation.Time; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the timestamp information from the signature Dim timeStampInformation As TimeStampInformation = result.TimeStampInformation ' Gets the timestamp time Dim timeStampTime As DateTime = timeStampInformation.Time ' Close the document document.Close(true) Checks whether the timestamp is valid or not // Loads an existing document PdfLoadedDocument document = new PdfLoadedDocument(fileName); // Gets the signature field PdfLoadedSignatureField signatureField = document.Form.Fields[0] as PdfLoadedSignatureField; // Validate signature and get validation result PdfSignatureValidationResult result = signatureField.ValidateSignature(); // Gets the timestamp information from the signature TimeStampInformation timeStampInformation = result.TimeStampInformation; // Checks whether the timestamp is valid or not bool isValid = timeStampInformation.IsValid; // Close the document document.Close(true); ' Loads an existing document Dim document As PdfLoadedDocument = New PdfLoadedDocument(fileName) ' Gets the signature field Dim signatureField As PdfLoadedSignatureField = document.Form.Fields[0] As PdfLoadedSignatureField ' Validate signature and get validation result Dim result As PdfSignatureValidationResult = signatureField.ValidateSignature() ' Gets the timestamp information from the signature Dim timeStampInformation As TimeStampInformation = result.TimeStampInformation ' Checks whether the timestamp is valid or not Dim isValid As Boolean = timeStampInformation.IsValid ' Close the document document.Close(true) AsnObject that represents the encoded time stamp response Represents the Public Key Infrastructure status info Time stamp token of the obtained time stamp response Oid type of the time stamp response Intializes a new instance and reads the timestamp response Array containing the time stamp request bytes Encodes the timestamp response from the Asn1Sequence Asn1Sequence containing the AsnObjects Encoded bytes Reads the Asn objects in the time stamp response stream Input response stream Parses the time stamp response and encodes the content Asn1Sequence containing the AsnObjects Encoded bytes Reads the content type of the response and encodes it Encoded bytes Encodes the time stamp content info Encoded bytes Returns the final encoded AsnSequence Represent a time stamp to add in PDF document, // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com"), "user", "123456"); //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As TimeStampServer = New TimeStampServer(New Uri("http://syncfusion.digistamp.com"), "user", "123456") 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Initialize a new instance of the class. The timestamp server uri // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com")); //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As TimeStampServer = New TimeStampServer(New Uri("http://syncfusion.digistamp.com")) 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Initialize a new instance of the class. The time stamp server uri. The user name of the timestamp server. The password of the timestamp server. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com"), "user", "123456"); //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As TimeStampServer = New TimeStampServer(New Uri("http://syncfusion.digistamp.com"), "user", "123456") 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Initialize a new instance of the class. The timestamp server uri. The user name of the timestamp server. The password of the user. The time out seconds. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com"), "user", "123456", 5); //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As TimeStampServer = New TimeStampServer(New Uri("http://syncfusion.digistamp.com"), "user", "123456", 5) 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or set the server uri. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com")); //Set server uri. timeStampServer.Server = new Uri("http://syncfusion.digistamp.com"); //Set user. timeStampServer.UserName = "user"; //Set password. timeStampServer.Password = "123456"; //Set time out. timeStampServer.TimeOut = 5; //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As New TimeStampServer(New Uri("http://syncfusion.digistamp.com")) 'Set server uri. timeStampServer.Server = New Uri("http://syncfusion.digistamp.com") 'Set user. timeStampServer.UserName = "user" 'Set password. timeStampServer.Password = "123456" 'Set time out. timeStampServer.TimeOut = 5 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or set the user name. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com")); //Set server uri. timeStampServer.Server = new Uri("http://syncfusion.digistamp.com"); //Set user. timeStampServer.UserName = "user"; //Set password. timeStampServer.Password = "123456"; //Set time out. timeStampServer.TimeOut = 5; //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As New TimeStampServer(New Uri("http://syncfusion.digistamp.com")) 'Set server uri. timeStampServer.Server = New Uri("http://syncfusion.digistamp.com") 'Set user. timeStampServer.UserName = "user" 'Set password. timeStampServer.Password = "123456" 'Set time out. timeStampServer.TimeOut = 5 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or set the password. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com")); //Set server uri. timeStampServer.Server = new Uri("http://syncfusion.digistamp.com"); //Set user. timeStampServer.UserName = "user"; //Set password. timeStampServer.Password = "123456"; //Set time out. timeStampServer.TimeOut = 5; //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As New TimeStampServer(New Uri("http://syncfusion.digistamp.com")) 'Set server uri. timeStampServer.Server = New Uri("http://syncfusion.digistamp.com") 'Set user. timeStampServer.UserName = "user" 'Set password. timeStampServer.Password = "123456" 'Set time out. timeStampServer.TimeOut = 5 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets or set the timeout. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Load the x509 certificate. X509Certificate2 cert = new X509Certificate2("certificate.pfx", "password"); //Find by subject. PdfCertificate pdfCert = new PdfCertificate(cert); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Create a new PDF time stamp server TimeStampServer timeStampServer = new TimeStampServer(new Uri("http://syncfusion.digistamp.com")); //Set server uri. timeStampServer.Server = new Uri("http://syncfusion.digistamp.com"); //Set user. timeStampServer.UserName = "user"; //Set password. timeStampServer.Password = "123456"; //Set time out. timeStampServer.TimeOut = 5; //Add time stamp. signature.TimeStampServer = timeStampServer; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Load the x509 certificate. Dim cert As New X509Certificate2("certificate.pfx", "password") 'Find by subject. Dim pdfCert As New PdfCertificate(cert) 'Creates a signature. Dim signature As New PdfSignature(document, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Create a new PDF time stamp server Dim timeStampServer As New TimeStampServer(New Uri("http://syncfusion.digistamp.com")) 'Set server uri. timeStampServer.Server = New Uri("http://syncfusion.digistamp.com") 'Set user. timeStampServer.UserName = "user" 'Set password. timeStampServer.Password = "123456" 'Set time out. timeStampServer.TimeOut = 5 'Add time stamp. signature.TimeStampServer = timeStampServer 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Gets a value indicating whether the Timestamp URL is valid. //Create a timestamp server. TimeStampServer tsServer = new TimeStampServer(new Uri("http://timestampurl.com/")); //Check whether the Timestamp URL is valid or not. bool isValid = tsServer.IsValid; 'Create a timestamp server. Dim tsServer As TimeStampServer = New TimeStampServer(New Uri("http://timestampurl.com/")) 'Check whether the Timestamp URL is valid or not. Dim isValid As Boolean = tsServer.IsValid New key offset length. Key length of 40 bit key. Key length of 128 bit key. Key length of 256 bit key. Revision number. A number specifying which revision of the standard security handler should be used to interpret this dictionary. Revision number. A number specifying which revision of the standard security handler should be used to interpret this dictionary. Amount of bytes. Amount of random bytes. Optimal string length. Number of iteration of the loop during owner pass calculation. Number of iteration of the loop during owner pass calculation. Flag, used during enc. key calculating. Number of bits in one byte. A value indicating whether password values were already computed. The object that allows to compute the MD5 hash for the input data using the implementation provided by the cryptographic service provider (CSP). Bytes array for manipulating by Custom algo. Bytes array of random numbers. Output owner password. Output user password. Changed owner password. It's needed to encryption purpose. Changed user password. It's needed to encryption purpose. The encryption key. Length of encryption key. Permission flags. A revision number that has been read from a PDF document. Shows if the encryptor's settings have been changed. Predefined bytes for empty string. Helps to control access to s_paddingString. Holds ecryptor status enable/disable ecryption. The valuse that should be stored in the encryptor dictionary. The array used to add padding to the encryption key in AES mode. The object that describes the type of encryption algorithm that should be used. The user encryption key (UE), that should stored in encryption dictionary. The Owner encryption key (OE), that should stored in encryption dictionary. The permission flag (Perms), that should stored in encryption dictionary. The 32 byte random number used as key for encrypting contents. The random bytes used in computing U and UE entries. The random bytes used in computing O and OE entries. Used to derive random byte array. Used to compute SHA256 hash. Shows if metadata has to be encrypted or not. The integer which represents revision of the encryption dictionary. The integer which represents the version of the encryption dictionary. AcrobatX security hash computation algorithms. Initializes a new instance of the class. Clones the specified document. A new cloned encryptor. Reads the essential values from a dictionary. The dictionary. Checks the password. The password. The key. Encrypts the data. The curr obj number. The data. Encrypted byte array. Saves this instance. Pads or truncates string to string with length equals to c_stringLength == 32. Bytes of newly created string. Pads or truncates data with length equals to c_stringLength == 32. Bytes of newly created string. Preperes hash code for cryptographic algorithm and executes it. Data to be encrypted / decrypted. Key for using by Custom algo. Prepares hash code for cryptographic algorithm and executes it. Data to be encrypted / decrypted. Key for using by Custom algo. The length of a key. Encrypts the data using AES cryptographic algorithm using initialization vector in CBC mode Data to be encrypted / decrypted. Key for using by Custom algo. The encrypted data Decrypts the data using AES cryptographic algorithm using initialization vector in CBC mode Data to be decrypted. Key for using by Custom algo. The decrypted data Encrypts the data using AES(256 Bit) cryptographic algorithm using initialization vector in CBC mode Data to be decrypted. Encrypted data Decrypts the data using AES(256 Bit) cryptographic algorithm using initialization vector in CBC mode Data to be decrypted. Decrypted data Creates initialization vector for AES encryption Initialization vector Recreates CustomArray array. This method is the part of implementation Custom algo. Key for using by Custom algo. The length of a key. Returns length of the encryption key. Length of the encryption key. Calculates owner password. Data of calculated owner password. Algorithm 3.3 of PDF 1.6 reference. Algorithm 2.B from ISO 32000-2 input for the advance compute hash password for the custom algorithm key for the computation hash algorithm returns the byte array of computed hash Calculates owner password for 256 bit encryption algorithm. Data of calculated owner password. Algorithm 3.9 of adobe_supplement_iso32000. Calculates owner password for 256-bit AcrobatX encryption algorithm. Algorithm 2.B of adobe_supplement_iso32000-2. Calculates owner encryption key for 256 bit encryption algorithm. Data of calculated owner encryption key. Algorithm 3.9 of adobe_supplement_iso32000. Computes first 4 steps from algorithm 3.3 to calculate the encryption key. The owner password. The encryption key. Computes the file encryption key of 256 bit AES encrypted documents. The owner/user password. The algorithm 3.2a of adobe_supplement_iso32000 Compute the owner file encryption key of 256-bit AcrobatX encrypted documents. The owner password Algorithm 2.B from ISO 32000-2 Compute the ueser file encryption key of 256-bit AcrobatX encrypted documents. The user password Algorithm 2.B from ISO 32000-2 Calculates temporary key used for calculating owner password value. Orignial key value. Current index. Temporary key used for calculating owner password value. Creates encryption key. Input password string. Owner password value. Key created. Creates file encryption key for 256 bit encryption scheme (random 32 byte array). Creates user password. Created user password. Calculates user encryption key for 256 bit encryption algorithm. Data of calculated user encryption key. Algorithm 3.8 of adobe_supplement_iso32000. Calculates user encryption key for 256-bit AcrobatX encryption algorithm. Data of calculated user encryption key. Algorithm 2-B of adobe_supplement_iso32000-2. Calculates user encryption key for 256 bit encryption algorithm. Data of calculated user encryption key. Algorithm 3.8 of adobe_supplement_iso32000. Calculates permission flag(Perms) for 256 bit encryption algorithm. Data of calculated Permission flag. Algorithm 3.10 of adobe_supplement_iso32000. Creates user password when encryption key is 40 bits length. Created user password. Creates user password when encryption key is 128 bits length. Created user password. Initializes data. Transforms key before encryption. Original key to be transformed. Transformed key. Checks if the password given is the user password. The password, which was given by the user. A flag indicating if the password is the user password. Checks if the password given is the user password (256 bit encryption scheme). The password, which was given by the user. A flag indicating if the password is the user password. Checks if the password given is the owner password. The password, which was given by the user. A flag indicating if the password is the owner password. Checks if the password given is the owner password (256 bit encryption scheme). The password, which was given by the user. A flag indicating if the password is the owner password. Converts an array into a password string. Before the convertion to string cutts off the padding string if there is one. The array, which should be converted. A string that should be a valid password string. Determines if the arrays are equal. One array that should be compared. Another array. True if arrays are equal, false otherwise. Determines if the first bytes of the arrays are equal. One array that should be compared. Another array. The actual size of the arrays to compare. True if arrays are equal, false otherwise. Standard encryption dictionary for AES encryption Gets security handler. Filter's value. Gets or sets the cryptographic algorithm. V's value. Gets or sets encryption algorithm. Gets or sets permission set. Gets revision number. R's value. Gets or sets the password required to change permissions for the PDF document. O's value. Gets or sets the password required to open the PDF document. P's value. Gets bytes array of random numbers. Gets or sets a value indicating whether this document is encrypt only attachment or not. Gets or sets bytes array for manipulating by Custom algo. Gets or sets the object that allows to compute the MD5 hash for the input data using the implementation provided by the cryptographic service provider (CSP). Gets encoding. Gets or sets encryption key. Gets or sets value indicating whether document should be encrypted or not. Gets calculated user password. Gets calculated owner password. Shows if the encryptor's setting have been changed. Shows if the metadata should be encrypted. Bytes for empty string. Represents the SfBigInteger Represents the security settings of the PDF document. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; PdfStandardFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 20f, PdfFontStyle.Bold); PdfBrush brush = PdfBrushes.Black; //Document security PdfSecurity security = document.Security; //use 128 bits key security.KeySize = PdfEncryptionKeySize.Key128Bit; security.OwnerPassword = "syncfusion"; security.Permissions = PdfPermissionsFlags.Print | PdfPermissionsFlags.FullQualityPrint; security.UserPassword = "password"; document.Save("Security.pdf"); document.Close(true); ' Creates a new document Dim document As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim font As PdfStandardFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 20f, PdfFontStyle.Bold) Dim brush As PdfBrush = PdfBrushes.Black 'Document security Dim security As PdfSecurity = document.Security 'use 128 bits key security.KeySize = PdfEncryptionKeySize.Key128Bit security.OwnerPassword = "syncfusion" security.Permissions = PdfPermissionsFlags.Print Or PdfPermissionsFlags.FullQualityPrint security.UserPassword = "password" document.Save("Security.pdf") document.Close(True) Owner password value. User password value. Object encrypting the data. Internal variable to indicates the security setting modified. Initializes a new instance of the class. Logically ORs flag and mask and return result. The mask of set bit that should be set in the result. The ORed value of flag and mask. // Creates a new document PdfDocument doc = new PdfDocument(); PdfSecurity security = doc.Security; security.SetPermissions(PdfPermissionsFlags.AssembleDocument); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() 'Document security Dim security As PdfSecurity = doc.Security security.SetPermissions(PdfPermissionsFlags.AssembleDocument) 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class Logically ANDs flag and inverted mask and return result. The mask of set bit that should be cleared in the result. The ANDed value of flag and inverted mask. // Creates a new document PdfDocument doc = new PdfDocument(); PdfSecurity security = doc.Security; security.ResetPermissions(PdfPermissionsFlags.AssembleDocument); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() 'Document security Dim security As PdfSecurity = doc.Security security.ResetPermissions(PdfPermissionsFlags.AssembleDocument) 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class Gets or sets the owner password, If the PDF document is password protected you can use the owner password to open the document and change its permissions. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations; doc.Security.UserPassword = "123"; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations doc.Security.UserPassword = "123" 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class Gets or sets the user password which is required when the PDF document is opened in a viewer. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations; doc.Security.UserPassword = "123"; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations doc.Security.UserPassword = "123" 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class Gets or sets the permissions when the document is opened with user password. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations | PdfPermissionsFlags.Print; doc.Security.UserPassword = "123"; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations | PdfPermissionsFlags.Print doc.Security.UserPassword = "123" 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class Gets or sets the encryptor. Gets or sets the length of the encryption key for encryption. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations; doc.Security.UserPassword = "123"; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations doc.Security.UserPassword = "123" 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class Gets or sets the type of encryption algorithm used. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations | PdfPermissionsFlags.Print; doc.Security.UserPassword = "123"; doc.Security.Algorithm = PdfEncryptionAlgorithm.AES; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations | PdfPermissionsFlags.Print doc.Security.UserPassword = "123" doc.Security.Algorithm = PdfEncryptionAlgorithm.AES 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Gets or sets a value indicating whether this is enabled. Gets or sets a value indicating whether this document is encrypt only attachment or not. Specifies length of the encryption key for encryption. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations; doc.Security.UserPassword = "123"; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations doc.Security.UserPassword = "123" 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class The key is 40 bit long. The key is 128 bit long. The key is 256 bit long. The key is 256 bit long with revision 6. AES algorithm for PDF 2.0 security feature. Specifies the type of encryption algorithm used. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations | PdfPermissionsFlags.Print; doc.Security.UserPassword = "123"; doc.Security.Algorithm = PdfEncryptionAlgorithm.AES; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations | PdfPermissionsFlags.Print doc.Security.UserPassword = "123" doc.Security.Algorithm = PdfEncryptionAlgorithm.AES 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) The encryption algorithm is RC4. The encryption algorithm is AES. Specifies the available permissions set for the signature. // Creates a new document PdfDocument doc = new PdfDocument(); // Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit; doc.Security.OwnerPassword = "Syncfusion"; doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations; doc.Security.UserPassword = "123"; //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 10); page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, new PointF(10,10)); doc.Save("Security.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Set the documents permission settings doc.Security.KeySize = PdfEncryptionKeySize.Key128Bit doc.Security.OwnerPassword = "Syncfusion" doc.Security.Permissions = PdfPermissionsFlags.EditAnnotations doc.Security.UserPassword = "123" 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = doc.Pages.Add() Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 10) page.Graphics.DrawString("Permission",font,PdfBrushes.Blue, New PointF(10,10)) doc.Save("Security.pdf") doc.Close(True) Class Class Class Class Default value. Print the document. Edit content. Copy content. Add or modify text annotations, fill in interactive form fields. Fill form fields. (Only for 128 bits key). Copy accessibility content. Assemble document permission. (Only for 128 bits key). Full quality print. Enumerator that implements possible security handlers. The built-in password-based security handler. Specifies the naming of a system store. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Find by subject. PdfCertificate storeCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion"); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, storeCertificate, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Find by subject. Dim storeCertificate As PdfCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion") 'Creates a signature. Dim signature As New PdfSignature(document, page, storeCertificate, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) A certificate store that holds certificates with associated private keys. Root certificates. Certification authority certificates. Software Publisher Certificate. Certificate store for directly trusted people and resources Certificate store for directly trusted publishers Certificate store for third party certificate publishers Certificate store for other users Specifies the Location of the store // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); //Find by subject. PdfCertificate storeCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion", StoreRegion.LocalMachine); //Creates a signature. PdfSignature signature = new PdfSignature(document, page, storeCertificate, "Signature"); signature.Bounds = new RectangleF(new PointF(0, 0), new SizeF(100, 100)); signature.ContactInfo = "johndoe@owned.us"; signature.LocationInfo = "Honolulu, Hawaii"; signature.Reason = "I am author of this document."; //Save the document. document.Save("output.pdf"); //Close the document. document.Close(true); ' Creates a new document Dim document As New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() 'Find by subject. Dim storeCertificate As PdfCertificate = PdfCertificate.FindBySubject(StoreType.MY, "syncfusion", StoreRegion.LocalMachine) 'Creates a signature. Dim signature As New PdfSignature(document, page, storeCertificate, "Signature") signature.Bounds = New RectangleF(New PointF(0, 0), New SizeF(100, 100)) signature.ContactInfo = "johndoe@owned.us" signature.LocationInfo = "Honolulu, Hawaii" signature.Reason = "I am author of this document." 'Save the document. document.Save("output.pdf") 'Close the document. document.Close(True) Certificate store assigned to local machine Certificate store used by current user. Specifies the available permissions on certificated document. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate("Pdf.pfx", "123"); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.DocumentPermissions = PdfCertificationFlags.AllowComments; doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate("Pdf.pfx", "123") Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.DocumentPermissions = PdfCertificationFlags.AllowComments doc.Save("SignedPdfSample.pdf") doc.Close(True) Class Class Class Class Restrict any changes to the document. Only allow form fill-in actions on this document. Only allow commenting and form fill-in actions on this document. Enumeration of signature flags. No flags specified. If set, the document contains at least one signature field. This flag allows a viewer application to enable user interface items (such as menu items or pushbuttons) related to signature processing without having to scan the entire document for the presence of signature fields. If set, the document contains signatures that may be invalidated if the file is saved (written) in a way that alters its previous contents, as opposed to an incremental update. Merely updating the file by appending new information to the end of the previous version is safe. Viewer applications can use this flag to present a user requesting a full save with an additional alert box warning that signatures will be invalidated and requiring explicit confirmation before continuing with the operation. Represents where and how to import private key of the certificate. // Creates a new document PdfDocument doc = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = doc.Pages.Add(); PdfCertificate pdfCert = new PdfCertificate(certificateStream, "123",KeyStorageFlags.DefaultKeySet); PdfSignature signature = new PdfSignature(doc, page, pdfCert, "Signature"); signature.Bounds = new RectangleF(new PointF(5, 5),new SizeF(100,200)); doc.Save("SignedPdfSample.pdf"); doc.Close(true); ' Creates a new document Dim doc As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = doc.Pages.Add() Dim pdfCert As PdfCertificate = New PdfCertificate(certificateStream, "123",KeyStorageFlags.DefaultKeySet) Dim signature As PdfSignature = New PdfSignature(doc, page, pdfCert, "Signature") signature.Bounds = New RectangleF(New PointF(5, 5),New SizeF(100,200)) doc.Save("SignedPdfSample.pdf") doc.Close(True) The default key set is used. The user key set is usually the default. Private keys are stored in the current user store rather than the local computer store. This occurs even if the certificate specifies that the keys should go in the local computer store. Private keys are stored in the local computer store rather than the current user store. Imported keys are marked as exportable. Notify the user through a dialog box or other method that the key is accessed. The Cryptographic Service Provider (CSP) in use defines the precise behavior. The key associated with a PFX file is persisted when importing a certificate. To encrypt all the document contents. To encrypt all the document contents except metadata. To encrypt atttachment files only. list of parent cell index cell index of PdfGrid which moves to next page Initializes a new instance of the class with the grid. The parent grid. Layouts the specified graphics. The graphics. The location. Layouts the specified graphics. The graphics. The bounds. Layouts the element. Lay outing parameters. Lay outing result. Layouts the on page. The param. Draw ParentGrid Rows when the ChildGrid has draw in secondPage Rearranges the pages. The layouted pages. Draws the row. The row. Start index of the cell. End index of the cell. Draws row till it fits the page and then calculates height for the next page. The RowLayoutResult. Row being drawn. Height of the row. Draws row The RowLayoutResult. Row being drawn. Height of the row. Recalculate row height for the split cell to be drawn. Raises BeforePageLayout event. The current page. The current bounds. The current row. If true, stop lay outing. Raises PageLayout event if needed. Page layout result. Event arguments. Raises the before cell layout. The graphics. Index of the row. Index of the cell. The bounds of the cell. The cell value. Raises the after cell layout event. The graphics. Index of the row. Index of the cell. The bounds of the cell. The value of the cell. Checks if the given format is default format or not. Determines the column draw ranges. Rearranges the pages Gets the next page. Gets the format. The format. Gets the layout result. Check row cell text is fit to cell or not Gets the grid. The grid. Initializes a new instance of the class. Gets or sets a value indicating whether this instance is finish. true if this instance is finish; otherwise, false. Gets or sets the bounds. The bounds. Provides parameters definition for PdfGrid layout. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Layout format PdfGridLayoutFormat format = new PdfGridLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.PaginateBounds = new RectangleF(0, 0, 400, 500); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10),format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Layout format Dim format As New PdfGridLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.PaginateBounds = New RectangleF(0, 0, 400, 500) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10),format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Layout format PdfGridLayoutFormat format = new PdfGridLayoutFormat(); format.Break = PdfLayoutBreakType.FitPage; format.PaginateBounds = new RectangleF(0, 0, 400, 500); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10),format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Layout format Dim format As New PdfGridLayoutFormat() format.Break = PdfLayoutBreakType.FitPage format.PaginateBounds = New RectangleF(0, 0, 400, 500) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10),format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with a base format. The base format. Represents the results of the PdfGrid including bounds and resultant page. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. PdfGridLayoutResult result = pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. Dim result As PdfGridLayoutResult = pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with the current page and bounds. The current page. The current bounds. The page might be null, which means that lay outing was performed on PdfGraphics. The Syncfusion.Pdf.Grid namespace contains classes for creating tables by entering the data manually or from an external data source. Represents a flexible grid that consists of columns and rows. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Internal variable to store layout format. check whether the Grid is drawn. RowLayoutBoundsWidth. list of drawn page index by PdfGrid Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified graphics. The graphics. The location. The width. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page.Graphics, new PointF(10, 10), 100); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page.Graphics, New PointF(10, 10), 100) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified graphics. The graphics. The x. The y. The width. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page.Graphics, 10, 10, 100); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page.Graphics, 10, 10, 100) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified graphics. The graphics. The bounds. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page.Graphics, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page.Graphics, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The location. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The location. The format. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Creating layout format PdfGridLayoutFormat format=new PdfGridLayoutFormat(); format.Layout=PdfLayoutType.Paginate; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Creating layout format Dim format As New PdfGridLayoutFormat() format.Layout = PdfLayoutType.Paginate 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The bounds. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new RectangleF(0, 0, 100, 100)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New RectangleF(0, 0, 100, 100)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The bounds. The format. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Creating layout format PdfGridLayoutFormat format=new PdfGridLayoutFormat(); format.Layout=PdfLayoutType.Paginate; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new RectangleF(0, 0, 100, 100), format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Creating layout format Dim format As New PdfGridLayoutFormat() format.Layout = PdfLayoutType.Paginate 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New RectangleF(0, 0, 100, 100), format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The x. The y. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The x. The y. The format. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Creating layout format PdfGridLayoutFormat format=new PdfGridLayoutFormat(); format.Layout=PdfLayoutType.Paginate; //Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10, format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Creating layout format Dim format As New PdfGridLayoutFormat() format.Layout = PdfLayoutType.Paginate 'Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10, format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The x. The y. The width. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10, 100); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10, 100) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the in the specified . The page. The x. The y. The width. The format. The grid layout result //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Creating layout format PdfGridLayoutFormat format=new PdfGridLayoutFormat(); format.Layout=PdfLayoutType.Paginate; //Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10, 100, format); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Creating layout format Dim format As New PdfGridLayoutFormat() format.Layout = PdfLayoutType.Paginate 'Draw grid to the page of PDF document. pdfGrid.Draw(page, 10, 10, 100, format) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Layouts the element. Layout parameters. Returns the results of layout. Draws an element on the Graphics. Graphics context where the element should be printed. Applies the span. Measures this instance. Apply built-in table style to the grid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Apply built-in table style to the table enum of PdfGridBuiltinStyle Apply built-in table style to the table enum of PdfGridBuiltinStyle The PdfGridBuiltinStyleSettings //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Create Bold style font Create Regular style font Create Italic style font Change font style Sets the data source. Populates the grid. Populates the header row. Calculates the column widths. Calculates the width of the columns. The bounds. Gets the headers collection from the PdfGrid.[Read-Only] Represents the headers of the PdfGrid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add(); dataTable.Columns.Add(); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; // Add a new header to PdfGrid. pdfGrid.Headers.Add(1); // Get the header collection. PdfGridHeaderCollection collection = pdfGrid.Headers; // Set the header names. collection[0].Cells[0].Value = "Header1"; collection[0].Cells[1].Value = "Header2"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add() dataTable.Columns.Add() 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable ' Add a new header to PdfGrid. pdfGrid.Headers.Add(1) ' Get the header collection. Dim collection As PdfGridHeaderCollection = pdfGrid.Headers ' Set the header names. collection(0).Cells(0).Value = "Header1" collection(0).Cells(1).Value = "Header2" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the row collection from the PdfGrid.[Read-Only] Represents the rows collection of the PdfGrid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Get the rows collection from the PdfGrid PdfGridRowCollection rowCollection = pdfGrid.Rows; rowCollection[0].Cells[0].Value = "Row Collection Sample"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Get the rows collection from the PdfGrid Dim rowCollection As PdfGridRowCollection = pdfGrid.Rows rowCollection(0).Cells(0).Value = "Row Collection Sample" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the data bind to the PdfGrid by associating it with an external data source. The data source. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the data member. The data member. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Create data table. DataTable stdTable = new DataTable("StdTable"); /// /Add columns stdTable.Columns.Add("ID"); stdTable.Columns.Add("Name"); //Add rows. stdTable.Rows.Add(new object[] { "S01", "George" }); stdTable.Rows.Add(new object[] { "S02", "Stefan" }); //Create new data set. DataSet dataSet = new DataSet(); dataSet.Tables.Add(dataTable); dataSet.Tables.Add(stdTable); //Set data member. pdfGrid.DataMember = "StdTable"; //Assign data source. pdfGrid.DataSource = dataSet; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Create data table. Dim stdTable As New DataTable("StdTable") 'Add columns stdTable.Columns.Add("ID") stdTable.Columns.Add("Name") 'Add rows. stdTable.Rows.Add(New Object() { "S01", "George"}) stdTable.Rows.Add(New Object() { "S02", "Stefan"}) 'Create new data set. Dim dataSet As New DataSet() dataSet.Tables.Add(dataTable) dataSet.Tables.Add(stdTable) 'Set data member. pdfGrid.DataMember = "StdTable" 'Assign data source. pdfGrid.DataSource = dataSet 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the grid style. Represents the style information applied to a PdfGrid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Adding different style PdfGridStyle style = new PdfGridStyle(); style.BackgroundBrush = PdfBrushes.Cyan; style.TextBrush = PdfBrushes.BlueViolet; style.TextPen = new PdfPen(PdfBrushes.Black, 0.25F); //Add style to the PdfGrid pdfGrid.Style = style; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Adding different style Dim style As New PdfGridStyle() style.BackgroundBrush = PdfBrushes.Cyan style.TextBrush = PdfBrushes.BlueViolet style.TextPen = New PdfPen(PdfBrushes.Black, 0.25F) 'Add style to the PdfGrid pdfGrid.Style = style 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the first row. The first row. Gets the column collection of the PdfGrid.[Read-Only] Represents the columns collection of the PdfGrid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Get the column collection from the PdfGrid PdfGridColumnCollection columnCollection = pdfGrid.Columns; columnCollection[0].Width = 100; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Get the column collection from the PdfGrid Dim columnCollection As PdfGridColumnCollection = pdfGrid.Columns columnCollection(0).Width = 100 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the size. The size. Gets or sets a value indicating whether to split or cut rows that overflow a page. Default Value: true //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Set row break. pdfGrid.AllowRowBreakAcrossPages = true; //Get the rows collection from the PdfGrid PdfGridRowCollection rowCollection = pdfGrid.Rows; rowCollection[0].Cells[0].Value = "Row Collection Sample"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Set row break. pdfGrid.AllowRowBreakAcrossPages = True 'Get the rows collection from the PdfGrid Dim rowCollection As PdfGridRowCollection = pdfGrid.Rows rowCollection(0).Cells(0).Value = "Row Collection Sample" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or set if grid is nested grid. Gets or sets the parent cell of the nested grid. Gets layout format of the grid. Gets a value indicating whether the start cell layout event should be raised. Gets a value indicating whether the end cell layout event should be raised. The event raised on starting cell lay outing. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table=new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender,PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If End Sub The event raised on finished cell layout. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.EndCellLayout += new PdfGridEndCellLayoutEventHandler(table_EndCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_EndCellLayout(object sender, PdfGridEndCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.EndCellLayout, AddressOf table_EndCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_EndCellLayout(ByVal sender As Object, ByVal args As PdfGridEndCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Represents the schema of a cell in a . //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set cell style. cell.Style.BackgroundBrush = new PdfSolidBrush(Color.Red); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set cell style. cell.Style.BackgroundBrush = New PdfSolidBrush(Color.Red) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Alignment of the image. Rowspanned cell remaining height d Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set cell style. cell.Style.BackgroundBrush = new PdfSolidBrush(Color.Red); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set cell style. cell.Style.BackgroundBrush = New PdfSolidBrush(Color.Red) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with the row. The row of the cell. Draws the specified graphics. The graphics. The bounds. Calculates the width. Calcualtes the height. Adjusts the outer layout area. The bounds. Adjusts the text layout area. The bounds. Draws the cell border constructed by drawing lines. The Current Graphics. The CellStyle. The bounds. Sets the transparency. The graphics. The pen. Gets the next cell. Gets the text font. Gets the text brush. Gets the text pen. Gets the background brush. Returns the column width Find inner column width Gets the width of the PdfGrid cell.[Read-Only] The width of the cell which is set by the column width. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set cell style. cell.Style.BackgroundBrush = new PdfSolidBrush(Color.Red); //Get cell width. float cellWidth = cell.Width; //Get cell height. float cellHeight = cell.Height; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set cell style. cell.Style.BackgroundBrush = New PdfSolidBrush(Color.Red) 'Get cell width. Dim cellWidth As Single = cell.Width 'Get cell height. Dim cellHeight As Single = cell.Height 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the height of the PdfGrid cell.[Read-Only] The height. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set cell style. cell.Style.BackgroundBrush = new PdfSolidBrush(Color.Red); //Get cell width. float cellWidth = cell.Width; //Get cell height. float cellHeight = cell.Height; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set cell style. cell.Style.BackgroundBrush = New PdfSolidBrush(Color.Red) 'Get cell width. Dim cellWidth As Single = cell.Width 'Get cell height. Dim cellHeight As Single = cell.Height 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value that indicates the total number of rows that cell spans within a PdfGrid. The number of rows that cell should span. The default value is 1. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value that indicates the total number of columns that cell spans within a PdfGrid. The number of columns that cell should span. The default value is 1. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the cell style. Represents the style information applied to individual cells within a PdfGrid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the cell content is HTML text or not //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the value of the cell. Value can be string or PdfGrid, PdfGrid will create a nested grid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the string format. The string format. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the parent row. The parent row. Gets or sets a value indicating whether this instance is cell merge continue. true if this instance is cell merge continue; otherwise, false. Gets or sets a value indicating whether this instance is cell merge start. true if this instance is cell merge start; otherwise, false. Gets or sets a value indicating whether this instance is row merge start. true if this instance is row merge start; otherwise, false. Gets or sets a value indicating whether this instance is row merge continue. true if this instance is row merge continue; otherwise, false. Gets the next cell. The next cell. Gets or sets the remaining string after the row split between pages. Gets or sets whether drawing of cell is completed. Gets or sets the image alignment type of the PdfGridCell background image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Get or set the tag for the element //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //PDF grid cell PdfGridCell cell = pdfGrid.Rows[0].Cells[0]; //Set row span cell.RowSpan = 2; //set column span. cell.ColumnSpan = 2; //Check whether the text is HTML text? bool isHtmlText = cell.IsHtmlText; //Set Value. cell.Value = "George"; //Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center; //Set image position. cell.ImagePosition = PdfGridImagePosition.Fit; //Set PDF tag. cell.PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'PDF grid cell Dim cell As PdfGridCell = pdfGrid.Rows(0).Cells(0) 'Set row span cell.RowSpan = 2; 'set column span. cell.ColumnSpan = 2; 'Check whether the text is HTML text? Dim isHtmlText As Boolean = cell.IsHtmlText 'Set Value. cell.Value = "George" 'Set string format. cell.StringFormat.Alignment = PdfTextAlignment.Center 'Set image position. cell.ImagePosition = PdfGridImagePosition.Fit 'Set PDF tag. cell.PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Provides access to an ordered, strongly typed collection of objects. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Get grid cells for the particular row. PdfGridCellCollection collection = pdfGrid.Rows[0].Cells; //Get cells count. int count = collection.Count; //Get cell PdfGridCell cell = collection[0]; //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Get grid cells for the particular row. Dim collection As PdfGridCellCollection = pdfGrid.Rows(0).Cells 'Get cells count. Dim count As Integer = collection.Count 'Get cell Dim cell As PdfGridCell = collection(0) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with the row. The row of cell collection. Adds this instance. Adds the specified cell. The cell. Returns the index of a particular cell in the collection. The cell. Index of the particular cell. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Get grid cells for the particular row. PdfGridCellCollection collection = pdfGrid.Rows[0].Cells; //Get cells count. int count = collection.Count; //Get cell PdfGridCell cell = collection[0]; //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Get the index of the cell. int index = collection.IndexOf(cell); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Get grid cells for the particular row. Dim collection As PdfGridCellCollection = pdfGrid.Rows(0).Cells 'Get cells count. Dim count As Integer = collection.Count 'Get cell Dim cell As PdfGridCell = collection(0) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Get the index of the cell. Dim index As Integer = collection.IndexOf(cell) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Get grid cells for the particular row. PdfGridCellCollection collection = pdfGrid.Rows[0].Cells; //custom collection enumerator. foreach (PdfGridCell cell in collection) { cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); } //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Get grid cells for the particular row. Dim collection As PdfGridCellCollection = pdfGrid.Rows(0).Cells 'custom collection enumerator. For Each cell As PdfGridCell In collection cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") Next 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the at the specified index.[Read-Only] The index of the required PdfGridCell //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Get grid cells for the particular row. PdfGridCellCollection collection = pdfGrid.Rows[0].Cells; //Get cells count. int count = collection.Count; //Get cell PdfGridCell cell = collection[0]; //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Get grid cells for the particular row. Dim collection As PdfGridCellCollection = pdfGrid.Rows(0).Cells 'Get cells count. Dim count As Integer = collection.Count 'Get cell Dim cell As PdfGridCell = collection(0) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the cells count.[Read-Only] The count representing the number of cells present in a Row. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable("EmpDetails"); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Get grid cells for the particular row. PdfGridCellCollection collection = pdfGrid.Rows[0].Cells; //Get cells count. int count = collection.Count; //Get cell PdfGridCell cell = collection[0]; //Set cell style. cell.Style.BackgroundImage = new PdfBitmap("Autumn leaves.jpg"); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable("EmpDetails") 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Get grid cells for the particular row. Dim collection As PdfGridCellCollection = pdfGrid.Rows(0).Cells 'Get cells count. Dim count As Integer = collection.Count 'Get cell Dim cell As PdfGridCell = collection(0) 'Set cell style. cell.Style.BackgroundImage = New PdfBitmap("Autumn leaves.jpg") 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Column collection enumerator. Initializes a new instance of the struct. The column collection. Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Checks the index. Gets the current. The current. Represents the schema of a column in a . //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a new PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create PDF grid column. PdfGridColumn column1 = new PdfGridColumn(pdfGrid); column1.Width = 100; PdfGridColumn column2 = new PdfGridColumn(pdfGrid); column2.Width = 200; PdfGridColumn column3 = new PdfGridColumn(pdfGrid); column3.Width = 100; //Add three columns. pdfGrid.Columns.Add(column1); pdfGrid.Columns.Add(column2); pdfGrid.Columns.Add(column3); //Add header. pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Cells[0].Value = "Employee ID"; pdfGridHeader.Cells[1].Value = "Employee Name"; pdfGridHeader.Cells[2].Value = "Salary"; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty); //Save the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Create a new PDF document. Dim pdfDocument As New PdfDocument() Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a new PdfGrid. Dim pdfGrid As New PdfGrid() 'Create PDF grid column. Dim column1 As New PdfGridColumn(pdfGrid) column1.Width = 100 Dim column2 As New PdfGridColumn(pdfGrid) column2.Width = 200 Dim column3 As New PdfGridColumn(pdfGrid) column3.Width = 100 'Add three columns. pdfGrid.Columns.Add(column1) pdfGrid.Columns.Add(column2) pdfGrid.Columns.Add(column3) 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Cells(0).Value = "Employee ID" pdfGridHeader.Cells(1).Value = "Employee Name" pdfGridHeader.Cells(2).Value = "Salary" 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty) 'Save the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Initializes a new instance of the class with the parent grid. The parent grid. //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a new PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create PDF grid column. PdfGridColumn column1 = new PdfGridColumn(pdfGrid); column1.Width = 100; PdfGridColumn column2 = new PdfGridColumn(pdfGrid); column2.Width = 200; PdfGridColumn column3 = new PdfGridColumn(pdfGrid); column3.Width = 100; //Add three columns. pdfGrid.Columns.Add(column1); pdfGrid.Columns.Add(column2); pdfGrid.Columns.Add(column3); //Add header. pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Cells[0].Value = "Employee ID"; pdfGridHeader.Cells[1].Value = "Employee Name"; pdfGridHeader.Cells[2].Value = "Salary"; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty); //Save the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Create a new PDF document. Dim pdfDocument As New PdfDocument() Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a new PdfGrid. Dim pdfGrid As New PdfGrid() 'Create PDF grid column. Dim column1 As New PdfGridColumn(pdfGrid) column1.Width = 100 Dim column2 As New PdfGridColumn(pdfGrid) column2.Width = 200 Dim column3 As New PdfGridColumn(pdfGrid) column3.Width = 100 'Add three columns. pdfGrid.Columns.Add(column1) pdfGrid.Columns.Add(column2) pdfGrid.Columns.Add(column3) 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Cells(0).Value = "Employee ID" pdfGridHeader.Cells(1).Value = "Employee Name" pdfGridHeader.Cells(2).Value = "Salary" 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty) 'Save the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Gets or sets the width of the . The width. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Create Cell Style PdfGridCellStyle style = new PdfGridCellStyle(); style.TextBrush = PdfBrushes.Cyan; //Gets the width of the 1st column float columnWidth = pdfGrid.Columns[0].Width; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Create Cell Style Dim style As New PdfGridCellStyle() style.TextBrush = PdfBrushes.Cyan 'Gets the width of the 1st column Dim columnWidth As Single = pdfGrid.Columns(0).Width 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the information about the text formatting. The format. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Creating new string formatting PdfStringFormat stringFormat = new PdfStringFormat(); stringFormat.Alignment = PdfTextAlignment.Right; //Set string format pdfGrid.Columns[0].Format = stringFormat; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Creating new string formatting Dim stringFormat As New PdfStringFormat() stringFormat.Alignment = PdfTextAlignment.Right 'Set string format pdfGrid.Columns(0).Format = stringFormat 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the parent .[Read-Only] The grid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Gets the parent grid PdfGrid parentGrid = pdfGrid.Columns[0].Grid; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); /// 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Gets the parent grid Dim parentGrid As PdfGrid = pdfGrid.Columns(0).Grid 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Provides access to an ordered, strongly typed collection of objects. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with the parent grid. The parent grid. Clears this instance. Add a new column to the . The added column //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a new PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Add three columns. pdfGrid.Columns.Add(); pdfGrid.Columns.Add(); pdfGrid.Columns.Add(); //Add header. pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Cells[0].Value = "Employee ID"; pdfGridHeader.Cells[1].Value = "Employee Name"; pdfGridHeader.Cells[2].Value = "Salary"; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty); //Save the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Create a new PDF document. Dim pdfDocument As New PdfDocument() Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a new PdfGrid. Dim pdfGrid As New PdfGrid() 'Add three columns. pdfGrid.Columns.Add() pdfGrid.Columns.Add() pdfGrid.Columns.Add() 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Cells(0).Value = "Employee ID" pdfGridHeader.Cells(1).Value = "Employee Name" pdfGridHeader.Cells(2).Value = "Salary" 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty) 'Save the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Adds the number of specified count. The count. //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a new PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Add three columns. pdfGrid.Columns.Add(3); //Add header. pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Cells[0].Value = "Employee ID"; pdfGridHeader.Cells[1].Value = "Employee Name"; pdfGridHeader.Cells[2].Value = "Salary"; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty); //Save the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Create a new PDF document. Dim pdfDocument As New PdfDocument() Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a new PdfGrid. Dim pdfGrid As New PdfGrid() 'Add three columns. pdfGrid.Columns.Add(3) 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Cells(0).Value = "Employee ID" pdfGridHeader.Cells(1).Value = "Employee Name" pdfGridHeader.Cells(2).Value = "Salary" 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty) 'Save the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Adds the specified column. The column. //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a new PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create PDF grid column. PdfGridColumn column1 = new PdfGridColumn(pdfGrid); column1.Width = 100; PdfGridColumn column2 = new PdfGridColumn(pdfGrid); column2.Width = 200; PdfGridColumn column3 = new PdfGridColumn(pdfGrid); column3.Width = 100; //Add three columns. pdfGrid.Columns.Add(column1); pdfGrid.Columns.Add(column2); pdfGrid.Columns.Add(column3); //Add header. pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Cells[0].Value = "Employee ID"; pdfGridHeader.Cells[1].Value = "Employee Name"; pdfGridHeader.Cells[2].Value = "Salary"; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty); //Save the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Create a new PDF document. Dim pdfDocument As New PdfDocument() Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a new PdfGrid. Dim pdfGrid As New PdfGrid() 'Create PDF grid column. Dim column1 As New PdfGridColumn(pdfGrid) column1.Width = 100 Dim column2 As New PdfGridColumn(pdfGrid) column2.Width = 200 Dim column3 As New PdfGridColumn(pdfGrid) column3.Width = 100 'Add three columns. pdfGrid.Columns.Add(column1) pdfGrid.Columns.Add(column2) pdfGrid.Columns.Add(column3) 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Cells(0).Value = "Employee ID" pdfGridHeader.Cells(1).Value = "Employee Name" pdfGridHeader.Cells(2).Value = "Salary" 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty) 'Save the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Calculates the column widths. Gets the widths of the columns. The total width. The start column. The end column. An array containing widths. Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. //Create a new PDF document. PdfDocument pdfDocument = new PdfDocument(); PdfPage pdfPage = pdfDocument.Pages.Add(); //Create a new PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Add three columns. pdfGrid.Columns.Add(3); foreach(PdfGridColumn column in pdfGrid.Columns) { //Set width. column.Width = 150; } //Add header. pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Cells[0].Value = "Employee ID"; pdfGridHeader.Cells[1].Value = "Employee Name"; pdfGridHeader.Cells[2].Value = "Salary"; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty); //Save the document. pdfDocument.Save("Output.pdf"); //Close the document pdfDocument.Close(true); 'Create a new PDF document. Dim pdfDocument As New PdfDocument() Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Create a new PdfGrid. Dim pdfGrid As New PdfGrid() 'Add three columns. pdfGrid.Columns.Add(3) For Each column As PdfGridColumn In pdfGrid.Columns 'Set width. column.Width = 150 Next 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Cells(0).Value = "Employee ID" pdfGridHeader.Cells(1).Value = "Employee Name" pdfGridHeader.Cells(2).Value = "Salary" 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Draw the PdfGrid. pdfGrid.Draw(pdfPage, PointF.Empty) 'Save the document. pdfDocument.Save("Output.pdf") 'Close the document pdfDocument.Close(True) Gets the at the specified index.[Read-Only] //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the number of columns in the .[Read-Only] The count. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Get the columns count. int count = pdfGrid.Columns.Count; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Get the columns count. Dim count As Integer = pdfGrid.Columns.Count 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the widths. The widths. Column collection enumerator. Initializes a new instance of the struct. The column collection. Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Checks the index. Gets the current. The current. Provides customization of the settings for the particular row. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Adding new Row PdfGridRow row = new PdfGridRow(pdfGrid); pdfGrid.Rows.Add(row); row.Cells[0].Value = "E03"; row.Cells[1].Value = "Bran"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Adding new Row Dim row As New PdfGridRow(pdfGrid) pdfGrid.Rows.Add(row) row.Cells(0).Value = "E03" row.Cells(1).Value = "Bran" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Check whether the row height set explicity. check whether the row is Grid header Initializes a new instance of the class with the parent grid. The parent grid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Adding new Row PdfGridRow row = new PdfGridRow(pdfGrid); pdfGrid.Rows.Add(row); row.Cells[0].Value = "E03"; row.Cells[1].Value = "Bran"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Adding new Row Dim row As New PdfGridRow(pdfGrid) pdfGrid.Rows.Add(row) row.Cells(0).Value = "E03" row.Cells(1).Value = "Bran" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Calculates the height. Measures the width. Enables you to set the appearance of the row in a . The cell style. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Create Cell Style PdfGridCellStyle style = new PdfGridCellStyle(); style.TextBrush = PdfBrushes.Cyan; //Apply style to the specific row pdfGrid.Rows[0].ApplyStyle(style); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Create Cell Style Dim style As New PdfGridCellStyle() style.TextBrush = PdfBrushes.Cyan 'Apply style to the specific row pdfGrid.Rows(0).ApplyStyle(style) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the cells from the selected row.[Read-Only] The cells. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Usage of cell collection pdfGrid.Rows[0].Cells[0].Value = "E03"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Usage of cell collection pdfGrid.Rows(0).Cells(0).Value = "E03" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the parent grid. The parent grid. Gets or sets the IsHeaderRow Gets or sets the row style. The row style. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Create row style PdfGridRowStyle rowStyle = new PdfGridRowStyle(); rowStyle.BackgroundBrush = PdfBrushes.Cyan; //Apply style to the row pdfGrid.Rows[0].Style = rowStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Create row style Dim rowStyle As New PdfGridRowStyle() rowStyle.BackgroundBrush = PdfBrushes.Cyan 'Apply style to the row pdfGrid.Rows(0).Style = rowStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the height of the row. The height. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Apply row height pdfGrid.Rows[0].Height = 100; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Apply row height pdfGrid.Rows(0).Height = 100 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the width. The width. Gets or sets a value indicating whether [row span exists]. true if [row span exists]; otherwise, false. Gets or sets a value indicating whether [column span exists]. true if [column span exists]; otherwise, false. Height of the row yet to be drawn after split. Gets or sets the index of the cell at which the row breaks when AllowHorizonalOverflow is true. Holds the result of nested grid. Returns index of the row. Check whether the Row has row span or row merge continue. Get or set the tag for the element //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Apply row height pdfGrid.Rows[0].Height = 100; //Set PDF tag. pdfGrid.Rows[0].PdfTag = new PdfStructureElement(PdfTagType.TableRow); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Apply row height pdfGrid.Rows(0).Height = 100 'Set PDF tag. pdfGrid.Rows(0).PdfTag = New PdfStructureElement(PdfTagType.TableRow) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Provides access to an ordered, strongly typed collection of objects. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Add new row PdfGridRow row = pdfGrid.Rows.Add(); row.Cells[0].Value = "E03"; row.Cells[1].Value = "Bran"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Add new row Dim row As PdfGridRow = pdfGrid.Rows.Add() row.Cells(0).Value = "E03" row.Cells(1).Value = "Bran" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with the parent grid. The parent grid. Add new row to the grid. The added row //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Add new row PdfGridRow row = pdfGrid.Rows.Add(); row.Cells[0].Value = "E03"; row.Cells[1].Value = "Bran"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Add new row Dim row As PdfGridRow = pdfGrid.Rows.Add() row.Cells(0).Value = "E03" row.Cells(1).Value = "Bran" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Add the row to the grid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Adding new Row PdfGridRow row = new PdfGridRow(pdfGrid); pdfGrid.Rows.Add(row); row.Cells[0].Value = "E03"; row.Cells[1].Value = "Bran"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Adding new Row Dim row As New PdfGridRow(pdfGrid) pdfGrid.Rows.Add(row) row.Cells(0).Value = "E03" row.Cells(1).Value = "Bran" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Sets the row span and column span to a cell. Index of the row. Index of the cell. The row span. The col span. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Set Span to the cell pdfGrid.Rows.SetSpan(0, 0, 2, 2); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Set Span to the cell pdfGrid.Rows.SetSpan(0, 0, 2, 2) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Applies the style to all the rows in the grid. The style. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Create Cell Style PdfGridCellStyle style = new PdfGridCellStyle(); style.TextBrush = PdfBrushes.Cyan; //Apply style to the specific row pdfGrid.Rows.ApplyStyle(style); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Create Cell Style Dim style As New PdfGridCellStyle() style.TextBrush = PdfBrushes.Cyan 'Apply style to the specific row pdfGrid.Rows.ApplyStyle(style) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Provides customization of the settings for the header. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Header collection pdfGrid.Headers[0].Cells[0].Value="Column1"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Header collection pdfGrid.Headers(0).Cells(0).Value = "Column1" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with the parent grid. The parent grid. Adds the specified row. The row. enables you to quickly and easily add rows to the header at run time. The count. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Add new row to the header PdfGridRow[] header = pdfGrid.Headers.Add(1); header[1].Cells[0].Value = "New Header"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Add new row to the header Dim header As PdfGridRow() = pdfGrid.Headers.Add(1) header(1).Cells(0).Value = "New Header" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Removes all the header information in the . //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Removes all the header in the PdfGrid pdfGrid.Headers.Clear(); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Removes all the header in the PdfGrid pdfGrid.Headers.Clear() 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Enables you to set the appearance of the header row in a . The style. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Create Cell Style PdfGridCellStyle style = new PdfGridCellStyle(); style.TextBrush = PdfBrushes.Cyan; //Apply style to the header pdfGrid.Headers.ApplyStyle(style); //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Create Cell Style Dim style As New PdfGridCellStyle() style.TextBrush = PdfBrushes.Cyan 'Apply style to the header pdfGrid.Headers.ApplyStyle(style) 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Returns an enumerator that iterates through a collection. An object that can be used to iterate through the collection. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Header collection foreach (PdfGridRow hRow in pdfGrid.Headers) { hRow.Cells[0].Value = "Column1"; } //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Header collection pdfGrid.Headers(0).Cells(0).Value = "Column1" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets a object that represents the header row in a control.[Read-Only] //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Header collection pdfGrid.Headers[0].Cells[0].Value="Column1"; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Header collection pdfGrid.Headers(0).Cells(0).Value = "Column1" 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the number of header in the .[Read-Only] The count. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Gets the number of rows in the header int count = pdfGrid.Headers.Count; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Gets the number of rows in the header Dim count As Integer = pdfGrid.Headers.Count 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Column collection enumerator. Initializes a new instance of the struct. The row collection. Advances the enumerator to the next element of the collection. true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection. The collection was modified after the enumerator was created. Sets the enumerator to its initial position, which is before the first element in the collection. The collection was modified after the enumerator was created. Checks the index. Gets the current. The current. The class used represents the cell border of the PDF grid //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = new PdfBorders(); border.All = PdfPens.Blue; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As New PdfBorders() border.All = PdfPens.Blue 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initialize a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = new PdfBorders(); border.All = PdfPens.Blue; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As New PdfBorders() border.All = PdfPens.Blue 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the left. The left. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = new PdfBorders(); border.Left = PdfPens.Red; border.Right = PdfPens.Blue; border.Top = PdfPens.Green; border.Bottom = PdfPens.Orange; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; pdfGrid.Style.CellSpacing = 2; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As New PdfBorders() border.Left = PdfPens.Red border.Right = PdfPens.Blue border.Top = PdfPens.Green border.Bottom = PdfPens.Orange 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle pdfGrid.Style.CellSpacing = 2 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the right. The right. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = new PdfBorders(); border.Left = PdfPens.Red; border.Right = PdfPens.Blue; border.Top = PdfPens.Green; border.Bottom = PdfPens.Orange; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; pdfGrid.Style.CellSpacing = 2; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As New PdfBorders() border.Left = PdfPens.Red border.Right = PdfPens.Blue border.Top = PdfPens.Green border.Bottom = PdfPens.Orange 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle pdfGrid.Style.CellSpacing = 2 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the top. The top. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = new PdfBorders(); border.Left = PdfPens.Red; border.Right = PdfPens.Blue; border.Top = PdfPens.Green; border.Bottom = PdfPens.Orange; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; pdfGrid.Style.CellSpacing = 2; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As New PdfBorders() border.Left = PdfPens.Red border.Right = PdfPens.Blue border.Top = PdfPens.Green border.Bottom = PdfPens.Orange 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle pdfGrid.Style.CellSpacing = 2 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the bottom. The bottom. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = new PdfBorders(); border.Left = PdfPens.Red; border.Right = PdfPens.Blue; border.Top = PdfPens.Green; border.Bottom = PdfPens.Orange; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; pdfGrid.Style.CellSpacing = 2; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As New PdfBorders() border.Left = PdfPens.Red border.Right = PdfPens.Blue border.Top = PdfPens.Green border.Bottom = PdfPens.Orange 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle pdfGrid.Style.CellSpacing = 2 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Sets all. All. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = new PdfBorders(); border.All = PdfPens.Blue; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As New PdfBorders() border.All = PdfPens.Blue 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets a value indicating whether this instance is all. true if this instance is all; otherwise, false. Gets the default border. The default. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle rowStyle = new PdfGridCellStyle(); //Creating Border PdfBorders border = PdfBorders.Default; border.All = PdfPens.Blue; //setting border to the style rowStyle.Borders = border; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = rowStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim rowStyle As New PdfGridCellStyle() 'Creating Border Dim border As PdfBorders = PdfBorders.Default border.All = PdfPens.Blue 'setting border to the style rowStyle.Borders = border 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = rowStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) The class used represents the edges of the grid cells Initializes a new instance of the class. Initializes a new instance of the class with left,right,top and bottom values. The left. The right. The top. The bottom. Gets or sets the left value of the edge The left value of the edge. Gets or sets the right value of the edge. The right value of the edge. Gets or sets the top value of the edge The top value of the edge. Gets or sets the bottom value of the edge. The bottom value of the edge. Sets value to all sides left,right,top and bottom The integer value to all sides Gets a value indicating whether this instance is all. true if this instance is all; otherwise, false. The class used represents the cell padding of the PDF grid //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Adding cell padding gridStyle.CellPadding = new PdfPaddings(5, 5, 5, 5); //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Adding cell padding gridStyle.CellPadding = New PdfPaddings(5, 5, 5, 5) 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Create new padding instance. PdfPaddings paddings = new PdfPaddings(); paddings.Left = 5; paddings.Top = 10; paddings.Bottom = 10; paddings.Right = 5; //Adding cell padding gridStyle.CellPadding = paddings; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Create new padding instance. Dim paddings As PdfPaddings = New PdfPaddings() paddings.Left = 5 paddings.Top = 10 paddings.Bottom = 10 paddings.Right = 5 'Adding cell padding gridStyle.CellPadding = paddings 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class with spacing of all sides Left,Right,Top,Bottom The left space. The right space. The top space. The bottom space. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Adding cell padding gridStyle.CellPadding = new PdfPaddings(5, 5, 5, 5); //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Adding cell padding gridStyle.CellPadding = New PdfPaddings(5, 5, 5, 5) 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the left space of padding. The left space. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Create new padding instance. PdfPaddings paddings = new PdfPaddings(); paddings.Left = 5; paddings.Top = 10; paddings.Bottom = 10; paddings.Right = 5; //Adding cell padding gridStyle.CellPadding = paddings; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Create new padding instance. Dim paddings As PdfPaddings = New PdfPaddings() paddings.Left = 5 paddings.Top = 10 paddings.Bottom = 10 paddings.Right = 5 'Adding cell padding gridStyle.CellPadding = paddings 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the right space of padding. The right space. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Create new padding instance. PdfPaddings paddings = new PdfPaddings(); paddings.Left = 5; paddings.Top = 10; paddings.Bottom = 10; paddings.Right = 5; //Adding cell padding gridStyle.CellPadding = paddings; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Create new padding instance. Dim paddings As PdfPaddings = New PdfPaddings() paddings.Left = 5 paddings.Top = 10 paddings.Bottom = 10 paddings.Right = 5 'Adding cell padding gridStyle.CellPadding = paddings 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the top space of padding. The top space. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Create new padding instance. PdfPaddings paddings = new PdfPaddings(); paddings.Left = 5; paddings.Top = 10; paddings.Bottom = 10; paddings.Right = 5; //Adding cell padding gridStyle.CellPadding = paddings; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Create new padding instance. Dim paddings As PdfPaddings = New PdfPaddings() paddings.Left = 5 paddings.Top = 10 paddings.Bottom = 10 paddings.Right = 5 'Adding cell padding gridStyle.CellPadding = paddings 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the bottom space of padding. The bottom space. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Create new padding instance. PdfPaddings paddings = new PdfPaddings(); paddings.Left = 5; paddings.Top = 10; paddings.Bottom = 10; paddings.Right = 5; //Adding cell padding gridStyle.CellPadding = paddings; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Create new padding instance. Dim paddings As PdfPaddings = New PdfPaddings() paddings.Left = 5 paddings.Top = 10 paddings.Bottom = 10 paddings.Right = 5 'Adding cell padding gridStyle.CellPadding = paddings 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Sets space value to all sides of a cell Left,Right,Top,Bottom. The space value of all sides Left,Right,Top,Bottom. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Create new padding instance. PdfPaddings paddings = new PdfPaddings(); paddings.All = 5; //Adding cell padding gridStyle.CellPadding = paddings; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Create new padding instance. Dim paddings As PdfPaddings = New PdfPaddings() paddings.All = 5 'Adding cell padding gridStyle.CellPadding = paddings 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Represents the grid built-in style settings. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply style bands to the columns in a table, //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply style bands to the rows in a table //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply first-column formatting to the first column of the specified table //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply heading-row formatting to the first row of the table. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply first-column formatting to the first column of the specified table. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply last-row formatting to the last row of the specified table. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Base class for the grid style //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink; //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Creates a new object that is a copy of the current instance. A new object that is a copy of this instance. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink; //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Clone the PDF grid style instance. PdfGridStyle style1 = gridStyle.Clone() as PdfGridStyle; style1.Font = new PdfStandardFont(PdfFontFamily.Courier, 8); pdfGrid.Style = style1; pdfGrid.Draw(page, new PointF(10, 100)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Clone the PDF grid style. Dim style1 As PdfGridStyle = TryCast(gridStyle.Clone(), PdfGridStyle) style1.Font = New PdfStandardFont(PdfFontFamily.Courier, 8) pdfGrid.Style = style1 pdfGrid.Draw(page, New PointF(10, 100)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the background brush. The background brush of the PdfGrid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink; //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the text brush. The text brush of the PdfGrid. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink; //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the text pen. The text pen. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink; //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue; //Set text pen. gridStyle.TextPen = PdfPens.Red; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue 'Set text pen. gridStyle.TextPen = PdfPens.Red 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the font. The font. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink; //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue; //Set text pen. gridStyle.TextPen = PdfPens.Red; //Set font. gridStyle.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 16, PdfFontStyle.Bold); //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set background brush. gridStyle.BackgroundBrush = PdfBrushes.Pink 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue 'Set text pen. gridStyle.TextPen = PdfPens.Red 'Set font. gridStyle.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 16, PdfFontStyle.Bold) 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Provides customization of the appearance for the . //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Setting text pen for grid gridStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set cell padding gridStyle.CellPadding = new PdfPaddings(5,5,5,5); //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; //Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set cell padding gridStyle.CellPadding = New PdfPaddings(5,5,5,5) 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside 'Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the cell spacing of the . The cell spacing. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set cell padding gridStyle.CellPadding = new PdfPaddings(5,5,5,5); //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; //Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set cell padding gridStyle.CellPadding = New PdfPaddings(5,5,5,5) 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside 'Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the cell padding. The cell padding. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set cell padding gridStyle.CellPadding = new PdfPaddings(5,5,5,5); //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; //Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set cell padding gridStyle.CellPadding = New PdfPaddings(5,5,5,5) 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside 'Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the border overlap style of the . The border overlap style. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set cell padding gridStyle.CellPadding = new PdfPaddings(5,5,5,5); //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; //Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set cell padding gridStyle.CellPadding = New PdfPaddings(5,5,5,5) 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside 'Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to allow horizontal overflow. true if [allow horizontal overflow]; otherwise, false. Defalult Value: false //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set cell padding gridStyle.CellPadding = new PdfPaddings(5,5,5,5); //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; //Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set cell padding gridStyle.CellPadding = New PdfPaddings(5,5,5,5) 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside 'Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the type of the horizontal overflow of the . The type of the horizontal overflow. Default value: PdfHorizontalOverflowType.LastPage //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set cell padding gridStyle.CellPadding = new PdfPaddings(5,5,5,5); //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; //Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set cell padding gridStyle.CellPadding = New PdfPaddings(5,5,5,5) 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside 'Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Provides customization of the appearance for the //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid row style PdfGridRowStyle rowStyle = new PdfGridRowStyle(); //Setting text pen for row rowStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Rows[0].Style = rowStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid row style Dim rowStyle As New PdfGridRowStyle() 'Setting text pen for row rowStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Rows(0).Style = rowStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid row style PdfGridRowStyle rowStyle = new PdfGridRowStyle(); //Setting text pen for row rowStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Rows[0].Style = rowStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid row style Dim rowStyle As New PdfGridRowStyle() 'Setting text pen for row rowStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Rows(0).Style = rowStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Provides customization of the appearance for the //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle cellStyle = new PdfGridCellStyle(); //Setting text pen for cell cellStyle.TextBrush = PdfBrushes.Blue; //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = cellStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim cellStyle As New PdfGridCellStyle() 'Setting text pen for cell cellStyle.TextBrush = PdfBrushes.Blue 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = cellStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Initializes a new instance of the class. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle cellStyle = new PdfGridCellStyle(); //Create new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; //Set string format to grid cell. cellStyle.StringFormat = format; //Set borders. PdfBorders borders = new PdfBorders(); borders.All = PdfPens.Red; cellStyle.Borders = borders; //Set background image. cellStyle.BackgroundImage = new PdfBitmap("Autumn Leaves.jpg"); //Set cell paddings. cellStyle.CellPadding = new PdfPaddings(5, 5, 5, 5); //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = cellStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim cellStyle As New PdfGridCellStyle() 'Create new PDF string format instance. Dim format As New PdfStringFormat() format.Alignment = PdfTextAlignment.Center 'Set string format to grid cell. cellStyle.StringFormat = format 'Set borders. Dim borders As New PdfBorders() borders.All = PdfPens.Red cellStyle.Borders = borders 'Set background image. cellStyle.BackgroundImage = New PdfBitmap("Autumn Leaves.jpg") 'Set cell paddings. cellStyle.CellPadding = New PdfPaddings(5, 5, 5, 5) 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = cellStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets the string format of the . The string format. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle cellStyle = new PdfGridCellStyle(); //Create new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; //Set string format to grid cell. cellStyle.StringFormat = format; //Set borders. PdfBorders borders = new PdfBorders(); borders.All = PdfPens.Red; cellStyle.Borders = borders; //Set background image. cellStyle.BackgroundImage = new PdfBitmap("Autumn Leaves.jpg"); //Set cell paddings. cellStyle.CellPadding = new PdfPaddings(5, 5, 5, 5); //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = cellStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim cellStyle As New PdfGridCellStyle() 'Create new PDF string format instance. Dim format As New PdfStringFormat() format.Alignment = PdfTextAlignment.Center 'Set string format to grid cell. cellStyle.StringFormat = format 'Set borders. Dim borders As New PdfBorders() borders.All = PdfPens.Red cellStyle.Borders = borders 'Set background image. cellStyle.BackgroundImage = New PdfBitmap("Autumn Leaves.jpg") 'Set cell paddings. cellStyle.CellPadding = New PdfPaddings(5, 5, 5, 5) 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = cellStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the border of the . The border. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle cellStyle = new PdfGridCellStyle(); //Create new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; //Set string format to grid cell. cellStyle.StringFormat = format; //Set borders. PdfBorders borders = new PdfBorders(); borders.All = PdfPens.Red; cellStyle.Borders = borders; //Set background image. cellStyle.BackgroundImage = new PdfBitmap("Autumn Leaves.jpg"); //Set cell paddings. cellStyle.CellPadding = new PdfPaddings(5, 5, 5, 5); //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = cellStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim cellStyle As New PdfGridCellStyle() 'Create new PDF string format instance. Dim format As New PdfStringFormat() format.Alignment = PdfTextAlignment.Center 'Set string format to grid cell. cellStyle.StringFormat = format 'Set borders. Dim borders As New PdfBorders() borders.All = PdfPens.Red cellStyle.Borders = borders 'Set background image. cellStyle.BackgroundImage = New PdfBitmap("Autumn Leaves.jpg") 'Set cell paddings. cellStyle.CellPadding = New PdfPaddings(5, 5, 5, 5) 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = cellStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the background image in the The background image. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle cellStyle = new PdfGridCellStyle(); //Create new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; //Set string format to grid cell. cellStyle.StringFormat = format; //Set borders. PdfBorders borders = new PdfBorders(); borders.All = PdfPens.Red; cellStyle.Borders = borders; //Set background image. cellStyle.BackgroundImage = new PdfBitmap("Autumn Leaves.jpg"); //Set cell paddings. cellStyle.CellPadding = new PdfPaddings(5, 5, 5, 5); //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = cellStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim cellStyle As New PdfGridCellStyle() 'Create new PDF string format instance. Dim format As New PdfStringFormat() format.Alignment = PdfTextAlignment.Center 'Set string format to grid cell. cellStyle.StringFormat = format 'Set borders. Dim borders As New PdfBorders() borders.All = PdfPens.Red cellStyle.Borders = borders 'Set background image. cellStyle.BackgroundImage = New PdfBitmap("Autumn Leaves.jpg") 'Set cell paddings. cellStyle.CellPadding = New PdfPaddings(5, 5, 5, 5) 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = cellStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets the edges. The edges. Gets or sets the cell padding. The cell padding. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid cell style PdfGridCellStyle cellStyle = new PdfGridCellStyle(); //Create new PDF string format instance. PdfStringFormat format = new PdfStringFormat(); format.Alignment = PdfTextAlignment.Center; //Set string format to grid cell. cellStyle.StringFormat = format; //Set borders. PdfBorders borders = new PdfBorders(); borders.All = PdfPens.Red; cellStyle.Borders = borders; //Set background image. cellStyle.BackgroundImage = new PdfBitmap("Autumn Leaves.jpg"); //Set cell paddings. cellStyle.CellPadding = new PdfPaddings(5, 5, 5, 5); //Applying style to grid pdfGrid.Rows[0].Cells[0].Style = cellStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid cell style Dim cellStyle As New PdfGridCellStyle() 'Create new PDF string format instance. Dim format As New PdfStringFormat() format.Alignment = PdfTextAlignment.Center 'Set string format to grid cell. cellStyle.StringFormat = format 'Set borders. Dim borders As New PdfBorders() borders.All = PdfPens.Red cellStyle.Borders = borders 'Set background image. cellStyle.BackgroundImage = New PdfBitmap("Autumn Leaves.jpg") 'Set cell paddings. cellStyle.CellPadding = New PdfPaddings(5, 5, 5, 5) 'Applying style to grid pdfGrid.Rows(0).Cells(0).Style = cellStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Describe the possible values of PdfHorizontalOverflowType. If a grid is drawn which doesn't fits within a single page, it will be splited to several pages. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a PdfGrid. PdfGrid pdfGrid = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); //Assign data source. pdfGrid.DataSource = dataTable; //Using the Column collection pdfGrid.Columns[0].Width = 100; //Adding grid style PdfGridStyle gridStyle = new PdfGridStyle(); //Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = true; //Set cell padding gridStyle.CellPadding = new PdfPaddings(5,5,5,5); //Adding cell spacing between cells gridStyle.CellSpacing = 0.5F; //Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; //Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage; //Applying style to grid pdfGrid.Style = gridStyle; //Draw grid to the page of PDF document. pdfGrid.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a PdfGrid. Dim pdfGrid As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() {"E01", "Clay"}) dataTable.Rows.Add(New Object() {"E02", "Thomas"}) 'Assign data source. pdfGrid.DataSource = dataTable 'Using the Column collection pdfGrid.Columns(0).Width = 100 'Adding grid style Dim gridStyle As New PdfGridStyle() 'Allow grid to overflow horizontally gridStyle.AllowHorizontalOverflow = True 'Set cell padding gridStyle.CellPadding = New PdfPaddings(5,5,5,5) 'Adding cell spacing between cells gridStyle.CellSpacing = 0.5F 'Set border ovelay style. gridStyle.BorderOverlapStyle = PdfBorderOverlapStyle.Inside 'Set horizontal overflow type. gridStyle.HorizontalOverflowType = PdfHorizontalOverflowType.LastPage 'Applying style to grid pdfGrid.Style = gridStyle 'Draw grid to the page of PDF document. pdfGrid.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draws the overflowing grid as next page Draws the overflowing grid as last page Delegate for handling StartCellLayoutEvent. The sender of the event. The arguments of the event. This event is raised when laying out a cell on a page. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table=new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender,PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If End Sub Class Class Delegate for handling EndCellLayoutEvent. The sender of the event. The arguments of the event. This event is raised when you have finished laying out a page. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.EndCellLayout += new PdfGridEndCellLayoutEventHandler(table_EndCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_EndCellLayout(object sender, PdfGridEndCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.EndCellLayout, AddressOf table_EndCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_EndCellLayout(ByVal sender As Object, ByVal args As PdfGridEndCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Class Class Arguments of BeginPageLayoutEvent. Class Initializes a new instance of the class. The bounds. The page. The start row. Gets the start row index.[Read-Only] The start row. Arguments of EndPageLayoutEvent. Class Initializes a new instance of the class. The result. The start row. The end row. Represents arguments of StartCellLayout Event. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender, PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If End Sub Class Class Represents the abstract class of the . // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender, PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If End Sub Initializes a new instance of the class. The graphics, on which the cell should be drawn. Index of the row. The cell inder. The bounds of the cell. The value. Gets the index of the row. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender, PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If End Sub Gets the index of the cell. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender, PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } //Get the cell index. int index = args.CellIndex; } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If 'Get the cell index. Dim index As Integer = args.CellIndex End Sub Gets the value. The value might be null or an empty string, which means that either no text were acquired or all text was on the previous page. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender, PdfGridBeginCellLayoutEventArgs args) { //Get the cell value. string text = args.Value; if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) 'Get value Dim text As String = args.Value If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) /// End If End Sub Gets the bounds of the cell. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender, PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If End Sub Gets the graphics, on which the cell should be drawn. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.BeginCellLayout += new PdfGridBeginCellLayoutEventHandler(table_BeginCellLayout); table.DataSource = dataTable; table.Style.CellPadding = 16; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_BeginCellLayout(object sender, PdfGridBeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.BeginCellLayout, AddressOf table_BeginCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As PdfGridBeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White,args.Bounds) End If End Sub Initializes a new instance of the class. The graphics, on which the cell should be drawn. Index of the row. The cell inder. The bounds of the cell. The value. Gets or sets a value that indicates whether the cell is drawn or not in the PDF document. Gets or sets cell style of a grid. Represents arguments of EndCellLayout Event. // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.EndCellLayout += new PdfGridEndCellLayoutEventHandler(table_EndCellLayout); table.DataSource = dataTable; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_EndCellLayout(object sender, PdfGridEndCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.EndCellLayout, AddressOf table_EndCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_EndCellLayout(ByVal sender As Object, ByVal args As PdfGridEndCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Class Class Initializes a new instance of the class. The graphics, on which the cell should be drawn. Index of the row. The cell inder. The bounds of the cell. The value. Get the PdfGridCellStyle // Creates a new document PdfDocument doc = new PdfDocument(); RectangleF rect = new RectangleF(0, 0, 500, 50); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); PdfPage page = doc.Pages.Add(); PdfPageTemplateElement top = new PdfPageTemplateElement(rect); PdfGrid table = new PdfGrid(); // Subscribe the cell layout event table.EndCellLayout += new PdfGridEndCellLayoutEventHandler(table_EndCellLayout); table.DataSource = dataTable; // Draws the table in page table.Draw(page.Graphics); doc.Save("Tables.pdf"); // Cell layout event handler void table_EndCellLayout(object sender, PdfGridEndCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Creates a new document Dim doc As PdfDocument = New PdfDocument() Dim rect As RectangleF = New RectangleF(0, 0, 500, 50) 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) Dim page As PdfPage = doc.Pages.Add() Dim top As PdfPageTemplateElement = New PdfPageTemplateElement(rect) Dim table As PdfGrid = New PdfGrid() ' Subscribe the cell layout event AddHandler table.EndCellLayout, AddressOf table_EndCellLayout table.DataSource = dataTable table.Style.CellPadding = 16 ' Draws the table in page table.Draw(page.Graphics) doc.Save("Tables.pdf") ' Cell layout event handler Private Sub table_EndCellLayout(ByVal sender As Object, ByVal args As PdfGridEndCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Represents base class for markers. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Marker font. Marker brush. Marker pen. The string format of the marker. Marker alignment. Gets or sets marker font. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set font. marker.Font = font; //Set pen. marker.Pen = PdfPens.Red; //Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left; //Set marker string format. marker.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set font. marker.Font = font 'Set pen. marker.Pen = PdfPens.Red 'Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left 'Set marker string format. marker.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets marker brush. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set font. marker.Font = font; //Set pen. marker.Pen = PdfPens.Red; //Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left; //Set marker string format. marker.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set font. marker.Font = font 'Set pen. marker.Pen = PdfPens.Red 'Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left 'Set marker string format. marker.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets marker pen. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set font. marker.Font = font; //Set pen. marker.Pen = PdfPens.Red; //Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left; //Set marker string format. marker.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set font. marker.Font = font 'Set pen. marker.Pen = PdfPens.Red 'Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left 'Set marker string format. marker.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets the format. The format. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set font. marker.Font = font; //Set pen. marker.Pen = PdfPens.Red; //Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left; //Set marker string format. marker.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set font. marker.Font = font 'Set pen. marker.Pen = PdfPens.Red 'Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left 'Set marker string format. marker.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets a value indicating whether the marker is situated at the left of the list or at the right of the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set font. marker.Font = font; //Set pen. marker.Pen = PdfPens.Red; //Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left; //Set marker string format. marker.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set font. marker.Font = font 'Set pen. marker.Pen = PdfPens.Red 'Set marker alignment. marker.Alignment = PdfListMarkerAlignment.Left 'Set marker string format. marker.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Indicates is alignment right. Represents marker for ordered list. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold); //Create a unordered list PdfOrderedMarker list = new PdfOrderedMarker(PdfNumberStyle.LowerRoman, font); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker = list; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold) 'Create a unordered list Dim list As PdfOrderedMarker = New PdfOrderedMarker(PdfNumberStyle.LowerRoman, font) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker = list 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Class Holds numbering style. Start number for ordered list. Delimiter for numbers. Finalizer for numbers. Current index of item. Initializes a new instance of the class. Number style of marker. Number delimiter of marker. Number suffix of marker. Number font of marker. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, ".", ".", font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, ".", ".", font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. Number style of marker. Number suffix of the marker. Number font of marker. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, ".", font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, ".", font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. Number style of marker. Number font of marker. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Draw marker in specified point at graphics. Pdf graphics. The location point. Draw marker in specified point at page. The page. The point. Gets the marker number. Number in string. Gets or sets the list numbering style. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker.Alignment = PdfListMarkerAlignment.Right; subList.Marker.Delimiter = "."; subList.Marker.StartNumber = 2; subList.Marker.Style = PdfNumberStyle.UpperRoman; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker.Alignment = PdfListMarkerAlignment.Right subList.Marker.Delimiter = "." subList.Marker.StartNumber = 2 subList.Marker.Style = PdfNumberStyle.UpperRoman 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Class Gets ar sets start number for ordered list. Default value is 1. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker.Alignment = PdfListMarkerAlignment.Right; subList.Marker.Delimiter = "."; subList.Marker.StartNumber = 2; subList.Marker.Style = PdfNumberStyle.UpperRoman; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker.Alignment = PdfListMarkerAlignment.Right subList.Marker.Delimiter = "." subList.Marker.StartNumber = 2 subList.Marker.Style = PdfNumberStyle.UpperRoman 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Class Gets or sets the delimiter. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker.Alignment = PdfListMarkerAlignment.Right; subList.Marker.Delimiter = "."; subList.Marker.StartNumber = 2; subList.Marker.Style = PdfNumberStyle.UpperRoman; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker.Alignment = PdfListMarkerAlignment.Right subList.Marker.Delimiter = "." subList.Marker.StartNumber = 2 subList.Marker.Style = PdfNumberStyle.UpperRoman 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Class Gets or sets the suffix of the marker. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker.Alignment = PdfListMarkerAlignment.Right; subList.Marker.Suffix = "."; subList.Marker.StartNumber = 2; subList.Marker.Style = PdfNumberStyle.UpperRoman; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Creates a new page and adds it as the last page of the document Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker.Alignment = PdfListMarkerAlignment.Right subList.Marker.Suffix = "." subList.Marker.StartNumber = 2 subList.Marker.Style = PdfNumberStyle.UpperRoman 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Class Gets or sets the index of the current item. Represents bullet for the list. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Holds the marker text. Holds the marker style. Holds the marker image. Marker temlapte. Marker size. Font used when draws styled marker Initializes a new instance of the class. The text of the marker. Marker font. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); list.Marker = new PdfUnorderedMarker("list", font); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() list.Marker = New PdfUnorderedMarker("list", font) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Initializes a new instance of the class. The style of the marker. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); list.Marker = new PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk); //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() list.Marker = New PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk) 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Initializes a new instance of the class. The image of the marker. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); list.Marker = new PdfUnorderedMarker(new PdfBitmap("Bullet.jpg")); //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() list.Marker = New PdfUnorderedMarker(New PdfBitmap("Bullet.jpg")) 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Initializes a new instance of the class. Template of the marker. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Create a new PDF template instance. PdfTemplate template = new PdfTemplate(100, 100); template.Graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(0, 0, 100, 100)); //Set template to marker. list.Marker = new PdfUnorderedMarker(template); //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Create a new PDF template instance. Dim template As PdfTemplate = New PdfTemplate(100, 100) template.Graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(0, 0, 100, 100)) 'Set template to marker. list.Marker = New PdfUnorderedMarker(template) 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Draws the specified graphics. The graphics. The point. The brush. The pen. Draws the specified page. The page. The point. The brush. The pen. Gets the styled text. Returns symbol represented of style. Gets or sets template of the marker. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Create a new PDF template instance. PdfTemplate template = new PdfTemplate(100, 100); template.Graphics.DrawRectangle(PdfBrushes.Red, new RectangleF(0, 0, 100, 100)); //Set template to marker. list.Marker.Template = template; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Create a new PDF template instance. Dim template As PdfTemplate = New PdfTemplate(100, 100) template.Graphics.DrawRectangle(PdfBrushes.Red, New RectangleF(0, 0, 100, 100)) 'Set template to marker. list.Marker.Template = template 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Gets or sets image of the marker. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Set the list image list.Marker.Image = new PdfBitmap("Bullet.jpg"); //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Set the list image list.Marker.Image = new PdfBitmap("Bullet.jpg") 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Gets or sets marker text. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Set the marker Text list.Marker.Text = "List: "; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Set the marker Text list.Marker.Text = "List: " 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Gets or sets the style. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Gets or sets the size. Gets or sets the unicode font. Specifies the marker style. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Marker have no style. Marker is like a disk. Marker is like a square. Marker is like a Asterisk. Marker is like a circle. Marker is custom string. Marker is custom image. Marker is custom template. Represents marker alignment. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(); //Set the marker style list.Marker.Alignment = PdfListMarkerAlignment.Left //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 20f; font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold); //Apply formattings to list list.Font = font; list.StringFormat = format; //Set list indent list.Indent = 10; //Add items to the list list.Items.Add("List of Essential Studio products"); list.Items.Add("IO products"); //Set text indent list.TextIndent = 10; //Draw list list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("UnOrderList.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList() 'Set the marker alignment list.Marker.Alignment = PdfListMarkerAlignment.Left 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14, PdfFontStyle.Bold) 'Create string format Dim format As PdfStringFormat = New PdfStringFormat() format.LineSpacing = 20f font = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Bold) 'Apply formattings to list list.Font = font list.StringFormat = format 'Set list indent list.Indent = 10 'Add items to the list list.Items.Add("List of Essential Studio products") list.Items.Add("IO products") 'Set text indent list.TextIndent = 10 'Draw list list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("UnOrderList.pdf") Class Class Class Class Left alignment for marker. Right alignment for marker. Represents base class for lists. Class //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) The characters for splitting. Creates an item collection. The text. The item collection initialized properly. Holds collection of items. Tabulation for items. Indent between marker and text. List's font. The pen for the list. The brush for the list. The string format for the list. Creates new list. Creates new list with items. Collection of list items. Initializes a new instance of the class. The font. Draws an list on the Graphics. Graphics context where the list should be printed. X co-ordinate of the list. Y co-ordinate of the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Draws list on the Graphics. Pdf graphics. Layouts list at page. Pdf layout parameters. Returns layout results. Rise the BeginItemLayout event. The instance containing the event data. Rise the EndItemLayout event. The instance containing the event data. Gets items of the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets tabulation for the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets the indent from the marker to the list item text. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets the list font. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets list brush. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets list pen. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets the format of the list. The format. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(graphics, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(graphics, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets a value indicating whether to raise begin item layout event. Gets a value indicating whether to raise end item layout event. Event that rises when item begin layout. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Begin item layout event. list.BeginItemLayout += List_BeginItemLayout; //End item layout event. list.EndItemLayout += List_EndItemLayout; //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(page, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); private void List_EndItemLayout(object sender, EndItemLayoutEventArgs args) { //End item layout event. } private void List_BeginItemLayout(object sender, BeginItemLayoutEventArgs args) { args.Item.Text += "_BeiginItem"; } 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Begin item layout event. AddHandler list.BeginItemLayout, AddressOf List_BeginItemLayout 'End item layout event. AddHandler list.EndItemLayout, AddressOf List_EndItemLayout 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(page, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Private Sub List_EndItemLayout(sender As Object, args As EndItemLayoutEventArgs) 'End item layout event. End Sub Private Sub List_BeginItemLayout(sender As Object, args As BeginItemLayoutEventArgs) args.Item.Text += "_BeiginItem" End Sub Event that rises when item end layout. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Begin item layout event. list.BeginItemLayout += List_BeginItemLayout; //End item layout event. list.EndItemLayout += List_EndItemLayout; //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(page, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); private void List_EndItemLayout(object sender, EndItemLayoutEventArgs args) { //End item layout event. } private void List_BeginItemLayout(object sender, BeginItemLayoutEventArgs args) { args.Item.Text += "_BeiginItem"; } 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Begin item layout event. AddHandler list.BeginItemLayout, AddressOf List_BeginItemLayout 'End item layout event. AddHandler list.EndItemLayout, AddressOf List_EndItemLayout 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(page, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Private Sub List_EndItemLayout(sender As Object, args As EndItemLayoutEventArgs) 'End item layout event. End Sub Private Sub List_BeginItemLayout(sender As Object, args As BeginItemLayoutEventArgs) args.Item.Text += "_BeiginItem" End Sub Represents the list item of the list. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Creates an item PdfListItem item = new PdfListItem("Tools"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Creates an item Dim item As PdfListItem = New PdfListItem("Tools") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Holds item font. Holds item text. Holds text format. Holds pen. Holds brush. Sub list. Text indent for current item. Creates new empty pdf list item. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Create new PDF list items. PdfListItem item1 = new PdfListItem(); item1.Text = "PDF"; PdfListItem item2 = new PdfListItem(); item2.Text = "XlsIO"; list.Items.Add(item1); list.Items.Add(item2); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a new list. Dim list As New PdfOrderedList() 'Create new PDF list items. Dim item1 As New PdfListItem() item1.Text = "PDF" Dim item2 As New PdfListItem() item2.Text = "XlsIO" list.Items.Add(item1) list.Items.Add(item2) 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Creates new pdf list item with default settings. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Create new PDF list items. PdfListItem item1 = new PdfListItem("PDF"); PdfListItem item2 = new PdfListItem("XlsIO"); list.Items.Add(item1); list.Items.Add(item2); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a new list. Dim list As New PdfOrderedList() 'Create new PDF list items. Dim item1 As New PdfListItem("PDF") Dim item2 As New PdfListItem("XlsIO") list.Items.Add(item1) list.Items.Add(item2) 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The text of item. The font of item. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Create new PDF list items. PdfListItem item1 = new PdfListItem("PDF", font); PdfListItem item2 = new PdfListItem("XlsIO", font); list.Items.Add(item1); list.Items.Add(item2); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a new list. Dim list As New PdfOrderedList() 'Create new PDF list items. Dim item1 As New PdfListItem("PDF", font) Dim item2 As New PdfListItem("XlsIO", font) list.Items.Add(item1) list.Items.Add(item2) 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The text of item. The font of item. The string format. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Create new PDF list items. PdfListItem item1 = new PdfListItem("PDF", font, format); PdfListItem item2 = new PdfListItem("XlsIO", font, format); list.Items.Add(item1); list.Items.Add(item2); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a new list. Dim list As New PdfOrderedList() 'Create new PDF list items. Dim item1 As New PdfListItem("PDF", font, format) Dim item2 As New PdfListItem("XlsIO", font, format) list.Items.Add(item1) list.Items.Add(item2) 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Creates new list item. The item text. The item font. The string format of item. The item pen. The item brush. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Create new PDF list items. PdfListItem item1 = new PdfListItem("PDF", font, format, PdfPens.Red, PdfBrushes.Black); PdfListItem item2 = new PdfListItem("XlsIO", font, format, PdfPens.Red, PdfBrushes.Black); list.Items.Add(item1); list.Items.Add(item2); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a new list. Dim list As New PdfOrderedList() 'Create new PDF list items. Dim item1 As New PdfListItem("PDF", font, format, PdfPens.Red, PdfBrushes.Black) Dim item2 As New PdfListItem("XlsIO", font, format, PdfPens.Red, PdfBrushes.Black) list.Items.Add(item1) list.Items.Add(item2) 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Gets or sets item font. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Creates an item PdfListItem item = new PdfListItem("Tools"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Creates an item Dim item As PdfListItem = New PdfListItem("Tools") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Gets or sets item text. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Creates an item PdfListItem item = new PdfListItem("Tools"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Text = "Grid"; gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Creates an item Dim item As PdfListItem = New PdfListItem("Tools") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) gridItem.Text = "Grid" ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Gets or sets item string format. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Creates an item PdfListItem item = new PdfListItem("Tools"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Creates an item Dim item As PdfListItem = New PdfListItem("Tools") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) gridItem.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Gets or sets list item pen. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Creates an item PdfListItem item = new PdfListItem("Tools"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Pen = new PdfPen(PdfBrushes.Blue); gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Creates an item Dim item As PdfListItem = New PdfListItem("Tools") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) gridItem.Pen = New PdfPen(PdfBrushes.Blue) ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Gets or sets list item brush. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Creates an item PdfListItem item = new PdfListItem("Tools"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Brush = PdfBrushes.BlueViolet; gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Creates an item Dim item As PdfListItem = New PdfListItem("Tools") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) gridItem.Brush = PdfBrushes.BlueViolet ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Gets or sets sublist for item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(); // Creates an item PdfListItem item = new PdfListItem("Backoffice"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Brush = PdfBrushes.BlueViolet; gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker.Brush = PdfBrushes.Black; subList.Indent = 20; subList.Items.Add("Essential PDF"); subList.Items.Add("Essential DocIO"); subList.Items.Add("Essrntial XlsIO"); list.Items[0].SubList = subList; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection() ' Creates an item Dim item As PdfListItem = New PdfListItem("Backoffice") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Brush = PdfBrushes.BlueViolet gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker.Brush = PdfBrushes.Black subList.Indent = 20 subList.Items.Add("Essential PDF") subList.Items.Add("Essential DocIO") subList.Items.Add("Essrntial XlsIO") list.Items(0).SubList = subList list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Gets or sets indent for item. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(); // Creates an item PdfListItem item = new PdfListItem("Backoffice"); item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.TextIndent = 10; gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker.Brush = PdfBrushes.Black; subList.Indent = 20; subList.Items.Add("Essential PDF"); subList.Items.Add("Essential DocIO"); subList.Items.Add("Essrntial XlsIO"); list.Items[0].SubList = subList; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection() ' Creates an item Dim item As PdfListItem = New PdfListItem("Backoffice") item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.TextIndent = 10 gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker.Brush = PdfBrushes.Black subList.Indent = 20 subList.Items.Add("Essential PDF") subList.Items.Add("Essential DocIO") subList.Items.Add("Essrntial XlsIO") list.Items(0).SubList = subList list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Get or set the tag for the element //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Create new PDF list items. PdfListItem item1 = new PdfListItem(); item1.Text = "PDF"; item1.PdfTag = new PdfStructureElement(PdfTagType.ListItem); PdfListItem item2 = new PdfListItem(); item2.Text = "XlsIO"; item2.PdfTag = new PdfStructureElement(PdfTagType.ListItem); list.Items.Add(item1); list.Items.Add(item2); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a new list. Dim list As New PdfOrderedList() 'Create new PDF list items. Dim item1 As New PdfListItem() item1.Text = "PDF" item1.PdfTag = New PdfStructureElement(PdfTagType.ListItem) Dim item2 As New PdfListItem() item2.Text = "XlsIO" item2.PdfTag = New PdfStructureElement(PdfTagType.ListItem) list.Items.Add(item1) list.Items.Add(item2) 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Represents collection of list items. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Initializes a new instance of the class. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. //Create new list items. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF"); collection.Add("XlsIO"); collection.Add("DocIO"); collection.Add("PPT"); PdfUnorderedList list = new PdfUnorderedList(collection); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new list items. Dim collection As PdfListItemCollection = New PdfListItemCollection() collection.Add("PDF") collection.Add("XlsIO") collection.Add("DocIO") collection.Add("PPT") 'Create a PDF unordered list. Dim list As New PdfUnorderedList(collection) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. A string array that contains items separated by the new line character. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Adds the specified item. The item. The item index in collection. // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(); // Creates an item PdfListItem item = new PdfListItem("Backoffice"); item.TextIndent = 10; item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Brush = PdfBrushes.BlueViolet; gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item); listItemCollection.Add(gridItem); ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection() ' Creates an item Dim item As PdfListItem = New PdfListItem("Backoffice") item.TextIndent = 10 item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Brush = PdfBrushes.BlueViolet gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Adding items in collection listItemCollection.Add(item) listItemCollection.Add(gridItem) Adds the specified item. The item. The item indent. // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(); // Creates an item PdfListItem item = new PdfListItem("Backoffice"); item.TextIndent = 10; item.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Creates Grid list item PdfListItem gridItem = new PdfListItem("Grid"); gridItem.Brush = PdfBrushes.BlueViolet; gridItem.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Adding items in collection listItemCollection.Add(item, 10); listItemCollection.Add(gridItem, 10); ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection() ' Creates an item Dim item As PdfListItem = New PdfListItem("Backoffice") item.TextIndent = 10 item.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Creates Grid list item Dim gridItem As PdfListItem = New PdfListItem("Grid") gridItem.Brush = PdfBrushes.BlueViolet gridItem.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) ' Adding items in collection listItemCollection.Add(item, 10) listItemCollection.Add(gridItem, 10) Adds the item with a specified text. The text. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. //Create new list items. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF"); collection.Add("XlsIO"); collection.Add("DocIO"); collection.Add("PPT"); PdfUnorderedList list = new PdfUnorderedList(collection); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new list items. Dim collection As PdfListItemCollection = New PdfListItemCollection() collection.Add("PDF") collection.Add("XlsIO") collection.Add("DocIO") collection.Add("PPT") 'Create a PDF unordered list. Dim list As New PdfUnorderedList(collection) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Adds the specified text. The text. The item indent. List item. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. //Create new list items. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF", 10); collection.Add("XlsIO", 10); collection.Add("DocIO",10); collection.Add("PPT", 10); PdfUnorderedList list = new PdfUnorderedList(collection); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new list items. Dim collection As PdfListItemCollection = New PdfListItemCollection() collection.Add("PDF", 10) collection.Add("XlsIO", 10) collection.Add("DocIO", 10) collection.Add("PPT", 10) 'Create a PDF unordered list. Dim list As New PdfUnorderedList(collection) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Adds the specified text. The text. The font. The item index in collection. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. //Create new list items. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF", font); collection.Add("XlsIO", font); collection.Add("DocIO", font); collection.Add("PPT", font); PdfUnorderedList list = new PdfUnorderedList(collection); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new list items. Dim collection As PdfListItemCollection = New PdfListItemCollection() collection.Add("PDF", font) collection.Add("XlsIO", font) collection.Add("DocIO", font) collection.Add("PPT", font) 'Create a PDF unordered list. Dim list As New PdfUnorderedList(collection) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Adds the specified text. The text. The font. The item indent. List item. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. //Create new list items. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF", font, 10); collection.Add("XlsIO", font, 10); collection.Add("DocIO", font, 10); collection.Add("PPT", font, 10); PdfUnorderedList list = new PdfUnorderedList(collection); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new list items. Dim collection As PdfListItemCollection = New PdfListItemCollection() collection.Add("PDF", font, 10) collection.Add("XlsIO", font, 10) collection.Add("DocIO", font, 10) collection.Add("PPT", font, 10) 'Create a PDF unordered list. Dim list As New PdfUnorderedList(collection) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Inserts item at the specified index. The specified index. The item. The item index string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); PdfListItem newItem = new PdfListItem("PDF"); // Insert a new item in the collection listItemCollection.Insert(0, newItem); Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) Dim newItem As PdfListItem = New PdfListItem("PDF") ' Insert a new item in the collection listItemCollection.Insert(0, newItem) Inserts the specified index. The index. The item. The item indent. string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); PdfListItem newItem = new PdfListItem("PDF"); // Insert a new item in the collection listItemCollection.Insert(0, newItem, 10); Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) Dim newItem As PdfListItem = New PdfListItem("PDF") ' Insert a new item in the collection listItemCollection.Insert(0, newItem, 10) Removes the specified item from the list. The specified item. string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); PdfListItem toolsItem = new PdfListItem("Tools"); // Remove 'Tools' list item listItemCollection.Remove(toolsItem); Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) Dim toolsItem As PdfListItem = New PdfListItem("Tools") ' Remove 'Tools' list item listItemCollection.Remove(toolsItem) Removes the item at the specified index from the list. he specified index. string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Remove the firse item from the collection listItemCollection.RemoveAt(0); Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Remove the firse item from the collection listItemCollection.RemoveAt(0) Determines the index of a specific item in the list. The item to locate in the list. The index of item if found in the list; otherwise, -1. string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Creates 'Tools' list item PdfListItem toolsItem = new PdfListItem("Tools"); int indexOf = listItemCollection.IndexOf(toolsItem); Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Creates 'Tools' list item Dim toolsItem As PdfListItem = New PdfListItem("Tools") Dim indexOf As Integer = listItemCollection.IndexOf(toolsItem) Clears collection. string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); // Clears the list listItemCollection.Clear(); Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) ' Clears the list listItemCollection.Clear() Gets the PdfListItem from collection at the specified index. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics Dim products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Dim listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) 'Create a unordered list Dim list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Layouts list. Class Current graphics for lay outing. Indicates end of lay outing. List that layouts at the moment. Stack than contains ListInfo. Index of item that lay outing. The indent of current list. Height in which it stop lay outing. Lay outing bounds. Current page for layout. Size for item lay outing. If true it use paginate bounds if it is set. Current brush for lay outing. Current pen for layout. Current font for layout. Current string format. Marker maximum width. Initializes a new instance of the class. The element. Layouts on the specified Graphics. The Graphics. The x-coordinate of element. The y-coordinate of element. Layouts on the specified Graphics. The graphics to draw. The location point. Layouts on the specified Graphics. The graphics to draw. The location boundaries. Layouts the element. Lay outing parameters. Lay outing result. Gets the width of the marker max. The list. The info. Sets the current parameters. The list. Sets the current parameters. The item. Layouts the on the page. The page layout result. Returns page layout result. Draws the item. The page result. The x position. The current list. The index of the item. The indent of the list. The list info. The current item. The current height. The y position. Determines whether is null or empty the specified text. The text. true if is null or empty the specified text, otherwise, false. Afters the item layouted. The item that layout. The page at which item layouted. Before the item layout. The item that layouts. The page at which item layout. After the page layouted. The current bounds. The current page. The current list. Before the page layout. The current bounds. The current page. The cuurent list. Creates the marker result. The index of the item. The current list. The list info. The current item. Returns marker layout result. Craetes the unordered marker result. The current list. The current item. Size of the marker. Creates the ordered marker result. The list. The item. The index. The info. if it is to find max width, set to true. Sets the marker alingment. The marker. The marker format. Markers string format. Draws the marker. The current list. The current item. The current marker result. The current Y position. The current X position. Returns true if marker have been drawn. Draws the unordered marker. The current list. The current marker result. The current item. The current X position. The current Y position. Draws the ordered marker. The current list. The marker result. The current item. The current X position. The current Y position. Gets the markers font. The marker. The item. Returns font of the marker Gets the marker format. The marker. The item. Markers format. Gets the marker pen. The marker. The item. Markers pen. Gets the marker brush. The marker. The item. Markers brush. Gets or sets element. Represents information about list. Index of list. Represents list. The number of item at specified index. Lists brush. Lists pen. Lists font. Lists format. Marker width; Initializes a new instance of the class. The list. The index of the list. The number if list is ordered list otherwise null. Initializes a new instance of the class. The list. The index. Gets or sets the index. The indexof the list. Gets or sets the list. The list. Gets or sets the number. The number of ordered list. Gets or sets the brush. Gets or sets the pen. Gets or sets the font. Gets or sets the format. The format. Represents Page Layout result. If true item finished layout on page. Y-ordinate of broken item of marker. Text of item that was not draw. Text of marker that was not draw. If true marker start draw. Width of marker. X-coordinate of marker. Represents begin page layout event arguments. Class //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; string[] products = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" }; // Creates an item collection PdfListItemCollection listItemCollection = new PdfListItemCollection(products); //Create a unordered list PdfUnorderedList list = new PdfUnorderedList(listItemCollection); //Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk; // Event handler list.BeginPageLayout += new BeginPageLayoutEventHandler(list_BeginPageLayout); list.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); // Event handler void list_BeginPageLayout(object sender, BeginPageLayoutEventArgs e) { // Set the new bounds for the list e.Bounds = new RectangleF(0, 0, e.Page.GetClientSize().Width, e.Page.GetClientSize().Height); } 'Create a new PDf document Private document As PdfDocument = New PdfDocument() 'Create a page Private page As PdfPage = document.Pages.Add() Private graphics As PdfGraphics = page.Graphics Private products() As String = { "Tools", "Grid", "Chart", "Edit", "Diagram", "XlsIO", "Grouping", "Calculate", "PDF", "HTMLUI", "DocIO" } ' Creates an item collection Private listItemCollection As PdfListItemCollection = New PdfListItemCollection(products) 'Create a unordered list Private list As PdfUnorderedList = New PdfUnorderedList(listItemCollection) 'Set the marker style list.Marker.Style = PdfUnorderedMarkerStyle.Disk ' Event handler AddHandler list.BeginPageLayout, AddressOf list_BeginPageLayout list.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") ' Event handler Private Sub list_BeginPageLayout(ByVal sender As Object, ByVal e As BeginPageLayoutEventArgs) ' Set the new bounds for the list e.Bounds = New RectangleF(0, 0, e.Page.GetClientSize().Width, e.Page.GetClientSize().Height) End Sub List that that starts layout. Initializes a new instance of the class. The bounds of the list. The page in which list layouts. The list that starts layout. Gets the list that starts layout. The list that starts layout. // Event handler void list_BeginPageLayout(object sender, BeginPageLayoutEventArgs e) { PdfUnorderedList list = sender as PdfUnorderedList; list.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12); // Set the new bounds for the list e.Bounds = new RectangleF(0, 0, e.Page.GetClientSize().Width, e.Page.GetClientSize().Height); } ' Event handler Private Sub list_BeginPageLayout(ByVal sender As Object, ByVal e As BeginPageLayoutEventArgs) Dim list As PdfUnorderedList = TryCast(sender, PdfUnorderedList) list.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12) ' Set the new bounds for the list e.Bounds = New RectangleF(0, 0, e.Page.GetClientSize().Width, e.Page.GetClientSize().Height) End Sub Represents begin page layout event arguments. Class List that ended layout. Initializes a new instance of the class. The layout result. The list that ended layout. Gets the list that ended layout. The list that ended layout. The Syncfusion.Pdf.Lists namespace contains classes for creating structure elements in PDF document. Represents the ordered list. Class //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold); //Create a unordered list PdfOrderedMarker list = new PdfOrderedMarker(PdfNumberStyle.LowerRoman, font); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker = list; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold) 'Create a unordered list Dim list As PdfOrderedMarker = New PdfOrderedMarker(PdfNumberStyle.LowerRoman, font) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker = list 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Marker of the list. True if user want to use numbering hierarchy, otherwise false. Initialize a new instance of the class. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList() 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The font. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(font); //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Set marker to the ordered list. list.Marker = marker; //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList(font) 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Set marker to the ordered list. list.Marker = marker 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The style. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create Ordered list PdfOrderedList list = new PdfOrderedList(PdfNumberStyle.Numeric); //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create Ordered list Dim list As New PdfOrderedList(PdfNumberStyle.Numeric) 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Creates ordered list using items. Items for a list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create new PDF list item instance. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF"); collection.Add("XlsIO"); collection.Add("DocIO"); collection.Add("PPT"); //Create Ordered list PdfOrderedList list = new PdfOrderedList(collection); //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new PDF list item instance. Dim collection As New PdfListItemCollection() collection.Add("PDF") collection.Add("XlsIO") collection.Add("DocIO") collection.Add("PPT") 'Create Ordered list Dim list As New PdfOrderedList(collection) 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The marker for the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Create Ordered list PdfOrderedList list = new PdfOrderedList(marker); //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Add items to the list list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Create Ordered list Dim list As New PdfOrderedList() 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Add items to the list list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The item collection. The marker for the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create new order list marker. PdfOrderedMarker marker = new PdfOrderedMarker(PdfNumberStyle.Numeric, font); //Set marker brush. marker.Brush = PdfBrushes.Black; //Create new PDF list item instance. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF"); collection.Add("XlsIO"); collection.Add("DocIO"); collection.Add("PPT"); //Create Ordered list PdfOrderedList list = new PdfOrderedList(collection, marker); //Set line indent. list.Indent = 20; //Set format for sub list. list.Font = font; list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); // Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new order list marker. Dim marker As New PdfOrderedMarker(PdfNumberStyle.Numeric, font) 'Set marker brush. marker.Brush = PdfBrushes.Black 'Create new PDF list item instance. Dim collection As New PdfListItemCollection() collection.Add("PDF") collection.Add("XlsIO") collection.Add("DocIO") collection.Add("PPT") 'Create Ordered list Dim list As New PdfOrderedList(collection, marker) 'Set line indent. list.Indent = 20 'Set format for sub list list.Font = font list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Creates the marker. The style of the list marker. Returns marker with specified style. Gets or sets marker of the list items. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold); //Create a unordered list PdfOrderedMarker list = new PdfOrderedMarker(PdfNumberStyle.LowerRoman, font); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker = list; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold) 'Create a unordered list Dim list As PdfOrderedMarker = New PdfOrderedMarker(PdfNumberStyle.LowerRoman, font) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker = list 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Class True if user want to use numbering hierarchy, otherwise false. //Create a new PDf document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); PdfGraphics graphics = page.Graphics; //Create a font and write title PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold); //Create a unordered list PdfOrderedMarker list = new PdfOrderedMarker(PdfNumberStyle.LowerRoman, font); //Create Ordered list as sublist of parent list PdfOrderedList subList = new PdfOrderedList(); subList.Marker = list; subList.MarkerHierarchy = true; //Add items to the list subList.Items.Add("List of Essential Studio products"); subList.Items.Add("IO products"); subList.Items.Add("Grid products"); subList.Items.Add("Tools products"); //Draw list subList.Draw(page, new RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)); document.Save("List.pdf"); 'Create a new PDf document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() Dim graphics As PdfGraphics = page.Graphics 'Create a font and write title Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 14,PdfFontStyle.Bold) 'Create a unordered list Dim list As PdfOrderedMarker = New PdfOrderedMarker(PdfNumberStyle.LowerRoman, font) 'Create Ordered list as sublist of parent list Dim subList As PdfOrderedList = New PdfOrderedList() subList.Marker = list subList.MarkerHierarchy = True 'Add items to the list subList.Items.Add("List of Essential Studio products") subList.Items.Add("IO products") subList.Items.Add("Grid products") subList.Items.Add("Tools products") 'Draw list subList.Draw(page, New RectangleF(0, 130, page.Graphics.ClientSize.Width, page.Graphics.ClientSize.Height)) document.Save("List.pdf") Class Class Class Represents unordered list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. PdfUnorderedList list = new PdfUnorderedList(); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a PDF unordered list. Dim list As New PdfUnorderedList() list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Marker for the list. Initializes a new instance of the class. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. PdfUnorderedList list = new PdfUnorderedList(); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a PDF unordered list. Dim list As New PdfUnorderedList() list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Creates unordered list using items. Items for a list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. //Create new list items. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF"); collection.Add("XlsIO"); collection.Add("DocIO"); collection.Add("PPT"); PdfUnorderedList list = new PdfUnorderedList(collection); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new list items. Dim collection As PdfListItemCollection = New PdfListItemCollection() collection.Add("PDF") collection.Add("XlsIO") collection.Add("DocIO") collection.Add("PPT") 'Create a PDF unordered list. Dim list As New PdfUnorderedList(collection) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The font. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. PdfUnorderedList list = new PdfUnorderedList(font); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a PDF unordered list. Dim list As New PdfUnorderedList(font) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The marker for the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create new unorder marker instance. PdfUnorderedMarker marker = new PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk); //Create a PDF unordered list. PdfUnorderedList list = new PdfUnorderedList(marker); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new unorder marker instance. Dim marker As PdfUnorderedMarker = New PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk); 'Create a PDF unordered list. Dim list As New PdfUnorderedList(marker) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The items collection. The marker for the list. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. //Create new list items. PdfListItemCollection collection = new PdfListItemCollection(); collection.Add("PDF"); collection.Add("XlsIO"); collection.Add("DocIO"); collection.Add("PPT"); //Create new unorder marker instance. PdfUnorderedMarker marker = new PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk); PdfUnorderedList list = new PdfUnorderedList(collection, marker); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create new list items. Dim collection As PdfListItemCollection = New PdfListItemCollection() collection.Add("PDF") collection.Add("XlsIO") collection.Add("DocIO") collection.Add("PPT") 'Create new unorder marker instance. Dim marker As PdfUnorderedMarker = New PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk); 'Create a PDF unordered list. Dim list As New PdfUnorderedList(collection, marker) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class. The formatted text. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. string text = "PDF\nXlsIO\ndDocIO\nPPT"; PdfUnorderedList list = new PdfUnorderedList(text); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F Dim text As String = "PDF\nXlsIO\ndDocIO\nPPT"; 'Create a PDF unordered list. Dim list As New PdfUnorderedList(text) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Initializes a new instance of the class from formatted text that is splitted by new lines. The formatted text. The marker. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. string text = "PDF\nXlsIO\ndDocIO\nPPT"; //Create new unorder marker instance. PdfUnorderedMarker marker = new PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk); PdfUnorderedList list = new PdfUnorderedList(text, marker); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F Dim text As String = "PDF\nXlsIO\ndDocIO\nPPT"; 'Create new unorder marker instance. Dim marker As PdfUnorderedMarker = New PdfUnorderedMarker(PdfUnorderedMarkerStyle.Asterisk); 'Create a PDF unordered list. Dim list As New PdfUnorderedList(text, marker) list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Creates the marker. The style marker of the marker. Returns marker with specified style. Gets or sets the marker. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a PDF unordered list. PdfUnorderedList list = new PdfUnorderedList(); list.Marker.Style = PdfUnorderedMarkerStyle.Disk; //Set line indent. list.Indent = 20; //Set font list.Font = font; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); list.Items.Add("PPT"); //Draw the PDF list to page. list.Draw(page, new RectangleF(0, 20, size.Width, size.Height)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10F 'Create a PDF unordered list. Dim list As New PdfUnorderedList() list.Marker.Style = PdfUnorderedMarkerStyle.Disk 'Set line indent. list.Indent = 20 'Set font list.Font = font 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") list.Items.Add("PPT") 'Draw the PDF list to page. list.Draw(page, New RectangleF(0, 20, size.Width, size.Height)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Delegate for handling BeginItemLayoutEvent. The item that begin layout. Begin Item Layout arguments. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Begin item layout event. list.BeginItemLayout += List_BeginItemLayout; //End item layout event. list.EndItemLayout += List_EndItemLayout; //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(page, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); private void List_EndItemLayout(object sender, EndItemLayoutEventArgs args) { //End item layout event. } private void List_BeginItemLayout(object sender, BeginItemLayoutEventArgs args) { args.Item.Text += "_BeiginItem"; } 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Begin item layout event. AddHandler list.BeginItemLayout, AddressOf List_BeginItemLayout 'End item layout event. AddHandler list.EndItemLayout, AddressOf List_EndItemLayout 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(page, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Private Sub List_EndItemLayout(sender As Object, args As EndItemLayoutEventArgs) 'End item layout event. End Sub Private Sub List_BeginItemLayout(sender As Object, args As BeginItemLayoutEventArgs) args.Item.Text += "_BeiginItem" End Sub Delegate for handling EndItemLayoutEvent. The item that end layout. End Item Layout arguments. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Begin item layout event. list.BeginItemLayout += List_BeginItemLayout; //End item layout event. list.EndItemLayout += List_EndItemLayout; //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(page, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); private void List_EndItemLayout(object sender, EndItemLayoutEventArgs args) { //End item layout event. } private void List_BeginItemLayout(object sender, BeginItemLayoutEventArgs args) { args.Item.Text += "_BeiginItem"; } 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Begin item layout event. AddHandler list.BeginItemLayout, AddressOf List_BeginItemLayout 'End item layout event. AddHandler list.EndItemLayout, AddressOf List_EndItemLayout 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(page, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Private Sub List_EndItemLayout(sender As Object, args As EndItemLayoutEventArgs) 'End item layout event. End Sub Private Sub List_BeginItemLayout(sender As Object, args As BeginItemLayoutEventArgs) args.Item.Text += "_BeiginItem" End Sub Represents begin layout event arguments. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Begin item layout event. list.BeginItemLayout += List_BeginItemLayout; //End item layout event. list.EndItemLayout += List_EndItemLayout; //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(page, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); private void List_EndItemLayout(object sender, EndItemLayoutEventArgs args) { //End item layout event. } private void List_BeginItemLayout(object sender, BeginItemLayoutEventArgs args) { args.Item.Text += "_BeiginItem"; } 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Begin item layout event. AddHandler list.BeginItemLayout, AddressOf List_BeginItemLayout 'End item layout event. AddHandler list.EndItemLayout, AddressOf List_EndItemLayout 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(page, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Private Sub List_EndItemLayout(sender As Object, args As EndItemLayoutEventArgs) 'End item layout event. End Sub Private Sub List_BeginItemLayout(sender As Object, args As BeginItemLayoutEventArgs) args.Item.Text += "_BeiginItem" End Sub Item that layout. The page in which item start layout. Initializes a new instance of the class. The item that layout. The page in which item start layout. Gets the item. The item that layout. Gets the page. The page in which item start layout. Represents end layout event arguments. //Create a new instance of PdfDocument class. PdfDocument document = new PdfDocument(); //Add a new page to the document. PdfPage page = document.Pages.Add(); //Get the PDF page graphics. PdfGraphics graphics = page.Graphics; SizeF size = page.Graphics.ClientSize; //Create font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic); //Create string format PdfStringFormat format = new PdfStringFormat(); format.LineSpacing = 10f; //Create a new list. PdfOrderedList list = new PdfOrderedList(); //Begin item layout event. list.BeginItemLayout += List_BeginItemLayout; //End item layout event. list.EndItemLayout += List_EndItemLayout; //Set indent. list.Indent = 10; //Set text indent. list.TextIndent = 10; //Set font. list.Font = font; //Set brush. list.Brush = new PdfSolidBrush(Color.Red); //Set pen. list.Pen = PdfPens.Green; //Set string format. list.StringFormat = format; //Add items. list.Items.Add("PDF"); list.Items.Add("XlsIO"); list.Items.Add("DocIO"); //Draw the PDF list to page. list.Draw(page, 10,10); // Save and close the document. document.Save("Output.pdf"); document.Close(true); private void List_EndItemLayout(object sender, EndItemLayoutEventArgs args) { //End item layout event. } private void List_BeginItemLayout(object sender, BeginItemLayoutEventArgs args) { args.Item.Text += "_BeiginItem"; } 'Create a new instance of PdfDocument class. Dim document As New PdfDocument() 'Add a new page to the document. Dim page As PdfPage = document.Pages.Add() 'Get the PDF page graphics. Dim graphics As PdfGraphics = page.Graphics Dim size As SizeF = page.Graphics.ClientSize 'Create font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 10, PdfFontStyle.Italic) 'Create string format Dim format As New PdfStringFormat() format.LineSpacing = 10.0F 'Create a new list. Dim list As New PdfOrderedList() 'Begin item layout event. AddHandler list.BeginItemLayout, AddressOf List_BeginItemLayout 'End item layout event. AddHandler list.EndItemLayout, AddressOf List_EndItemLayout 'Set indent. list.Indent = 10 'Set text indent. list.TextIndent = 10 'Set font. list.Font = font 'Set brush. list.Brush = New PdfSolidBrush(Color.Red) 'Set pen. list.Pen = PdfPens.Green 'Set string format. list.StringFormat = format 'Add items. list.Items.Add("PDF") list.Items.Add("XlsIO") list.Items.Add("DocIO") 'Draw the PDF list to page. list.Draw(page, 10, 10) ' Save and close the document. document.Save("Output.pdf") document.Close(True) Private Sub List_EndItemLayout(sender As Object, args As EndItemLayoutEventArgs) 'End item layout event. End Sub Private Sub List_BeginItemLayout(sender As Object, args As BeginItemLayoutEventArgs) args.Item.Text += "_BeiginItem" End Sub Item that layouted. The page in which item ended layout. Initializes a new instance of the class. The item that layout. The page in which item end layout. Gets the item that layout. The item that layout. Gets the page in which item ended layout. The page in which item ended layout. Represents the lay outing of tables. Class Cell values of a row being shared by pages. The latest text results. Current cell width. Current page. The chached bounds of the current page. Holds the current graphics and is used when current page is not available (e.g. drawing on a graphics). Current bounds. Stores cell spacing value. Holds an array of integers that specify column spanning (horizontal mergin) The index of the row dropped to the next page. The index of the start column. Initializes a new instance of the class. The table. Layouts the table on the specified graphics. The graphics. The location. Layouts the table on the specified graphics. The graphics. The boundaries. Layouts the element. Lay outing parameters. Lay outing result. Gets the format. The format structure passed through parameters. PdfLightTableLayoutFormat class instance. Gets the layout result. The page result. Table layout result. Layouts the table part on a page. Start row index. The lay outing parameters. if set to true the current page is the first one. Result of the lay outing. Crops a row to make it fit the starting and ending columns. The row. The cropped row. Resizes rectangle so that the border will be drawn insize the bounds specified. The bounds. The pen. Create Bold style font Create Regular style font Create Italic style font Draws a row. The param. Index of the row. The row data. The row bouds. Height of the row. if it is header, set to true. if it is stop, set to true. Indicator if the row was drawn partly. Sets the transparency. The graphics. The pen. Validates the span map. Determines whether the specified row is incomplete. The results. true if the specified results is incomplete; otherwise, false. Determines the height of the row. The param. Index of the row. The row. The row bouds. The results. The cell style. The height of the row. Drops lay outing to the next page. The results. The count. The row. Returns the width of the cell specified by the index. Index of the cell. The width of the cell. Reduces the height (or width) according to overlapped and border width value. The height. Width of the border. if it is overlapped, set to true. The proper height. Draws a cell. The layout result. The bounds. Index of the row. Index of the cell. The cell style. The result of the drawing. Gets the cell style. Index of the row. if set to true the cell is in header. The cell style. Gets the widths. The bounds. An array containing the widhts. Retrieves the next row. Start index of the row. The param. The next row. Gets the alpha channel value. The brush. The alpha channel value. Raises BeforePageLayout event. The current page. The current bounds. The current row. If true, stop lay outing. Raises PageLayout event if needed. Page layout result. Event arguments. Raises the before row layout. Index of the row. The cell style. The arguments modified by the user. Raises the after row layout. Index of the row. if set to true the row was drawn completely. The row bouds. Indicator whether the user stopped lay outing. Raises the before cell layout. The graphics. Index of the row. Index of the cell. The bounds of the cell. The cell value. Raises the after cell layout event. The graphics. Index of the row. Index of the cell. The bounds of the cell. The value of the cell. Gets shape element. Read only. The last page where the text was drawn. The bounds of the element on the last page where it was drawn. Indicates whether the lay outing has been finished. The index of the first row on the page. The index of the last row on the page. Represents the result of PdfLightTable which contains bounds and resultant page. // Create a new document PdfDocument doc = new PdfDocument(); //Create a new page PdfPage page = doc.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // Adding rows PdfRowCollection rowCollection = table.Rows; // Gets the first row from the collection. rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Create the layout format PdfLightTableLayoutFormat format = new PdfLightTableLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitElement; // Draw the table PdfLightTableLayoutResult result = table.Draw(page, new PointF(0, 0), format); //Save the document. doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a new document Dim doc As New PdfDocument() 'Create a new page Dim page As PdfPage = doc.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' Adding rows Dim rowCollection As PdfRowCollection = table.Rows ' Gets the first row from the collection. rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Create the layout format Dim format As New PdfLightTableLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitElement ' Draw the table Dim result As PdfLightTableLayoutResult = table.Draw(page, New PointF(0, 0), format) 'Save the document. doc.Save("Output.pdf") 'Close the document doc.Close(True) Class Holds text layout results for the last row. The index of the last row. Initializes a new instance of the class. The current page. The current bounds. Index of the row. The cell results. Gets the at the specified index. Gets the index of the last row. Read-Only. // Create a new document PdfDocument doc = new PdfDocument(); //Create a new page PdfPage page = doc.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // Adding rows PdfRowCollection rowCollection = table.Rows; // Gets the first row from the collection. rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Create the layout format PdfLightTableLayoutFormat format = new PdfLightTableLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitElement; // Draw the table PdfLightTableLayoutResult result = table.Draw(page, new PointF(0, 0), format); // Gets the last row index int lastRow = result.LastRowIndex; //Save the document. doc.Save("Output.pdf"); //Close the document doc.Close(true); ' Create a new document Dim doc As New PdfDocument() 'Create a new page Dim page As PdfPage = doc.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' Adding rows Dim rowCollection As PdfRowCollection = table.Rows ' Gets the first row from the collection. rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Create the layout format Dim format As New PdfLightTableLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitElement ' Draw the table Dim result As PdfLightTableLayoutResult = table.Draw(page, New PointF(0, 0), format) ' Gets the last row index Dim lastRow As Integer = result.LastRowIndex 'Save the document. doc.Save("Output.pdf") 'Close the document doc.Close(True) Represents the arguments of BeginPageLayoutEvent. Class Initializes a new instance of the class. The bounds of the table. The page to be drawn. The starting row to be drawn at first. Gets the start row. Read-Only. The index of the start row. Represents the arguments of LightTableEndPageLayout Event. Class Initializes a new instance of the class. The PdfLightTable layout result. The starting row to be drawn at first. The ending row to be drawn at last. Gets the start row. Read-Only. The index of the start row. Gets the end row. Read-Only. The index of the last row. The Syncfusion.Pdf.Tables namespace contains classes for creating tables. Create table by entering the data manually or from an external data source. //Create a new PDF document. PdfDocument document = new PdfDocument(); // Add a page. PdfPage page = document.Pages.Add(); //Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); //Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the DataTable. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the DataTable. table.Rows.Add(new string[] { "abc", "21", "Male" }); // Assign data source. pdfLightTable.DataSource = table; // Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); // Save the document. document.Save("output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the DataTable. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the DataTable. table.Rows.Add(New String() {"abc", "21", "Male"}) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("output.pdf") 'Close the document document.Close(True) Stores current column collection. Stores current row collection. The table name from the data set. Indicates the datasource type. Specifies whether to break the last row of the table or not when the space is not enough Draw the in the specified with specified graphics ,location and width. Graphics context where the element should be printed. The location of the element. The width of the table. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the DataTable. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the DataTable. table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, new PointF(0, 0),500); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the DataTable. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the DataTable. table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, New PointF(0, 0),500) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the with the specified ,x and y coordinates and width. Graphics context where the element should be drawn. The x co-ordinate of the element. The y co-ordinate of the element. The width of the table. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the DataTable. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the DataTable. table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, 10, 10, 500); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the DataTable. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the DataTable. table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, 10, 10, 500) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified and bounds. Graphics context where the element should be drawn. The bounds of the table should be drawn. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the DataTable. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the DataTable. table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, new RectangleF(0, 0,500,500)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the DataTable. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the DataTable. table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, New RectangleF(0, 0,500,500)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified and location. The page of the table should be drawn. The x,y coordinates of the table. The PdfLightTable layout result //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the DataTable. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the DataTable. table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the DataTable. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the DataTable. table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified ,location and . The page of the table should be drawn. The x,y coordinates of the table. The PdfLightTable layout format. The PdfLightTable layout result. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the Data Table. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the Data Table.//you can add multiple rows table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Set properties to paginate the table. PdfLightTableLayoutFormat layoutFormat = new PdfLightTableLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0), layoutFormat); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the Data Table. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the Data Table.//you can add multiple rows table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Set properties to paginate the table. Dim layoutFormat As New PdfLightTableLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0), layoutFormat) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified and bounds. The page of the table should be drawn. The bounds of the table. The PdfLightTable layout result //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the DataTable. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the DataTable. table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page, new RectangleF(0,0,500,500)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the DataTable. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the DataTable. table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page, New RectangleF(0,0,500,500)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified ,bounds and layout format. The page of the table should be drawn. The bounds of the table. The PdfLightTable layout format. The PdfLightTable layout result //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the Data Table. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the Data Table.//you can add multiple rows table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Set properties to paginate the table. PdfLightTableLayoutFormat layoutFormat = new PdfLightTableLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Draw PdfLightTable. pdfLightTable.Draw(page, new RectangleF(0, 0,500,500), layoutFormat); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the Data Table. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the Data Table.//you can add multiple rows table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Set properties to paginate the table. Dim layoutFormat As New PdfLightTableLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Draw PdfLightTable. pdfLightTable.Draw(page, New RectangleF(0, 0,500,500), layoutFormat) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified and x, y coordinates. The page of the table should be drawn. The X co-ordinate of the element. The y coordinate of the element. The PdfLightTable layout result //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the DataTable. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the DataTable. table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page, 10, 10); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the DataTable. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the DataTable. table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page, 10, 10) 'Save the document. document.Save("Output.pdf") 'Close the document Draw the in the specified , x,y coordinates and layout format. The page of the table should be drawn. The x co-ordinate of the element. The y coordinate of the element. The PdfLightTable layout format. The PdfLightTable layout result. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the Data Table. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the Data Table.//you can add multiple rows table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Set properties to paginate the table. PdfLightTableLayoutFormat layoutFormat = new PdfLightTableLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Draw PdfLightTable. pdfLightTable.Draw(page, 10, 10, layoutFormat); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the Data Table. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the Data Table.//you can add multiple rows table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Set properties to paginate the table. Dim layoutFormat As New PdfLightTableLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Draw PdfLightTable. pdfLightTable.Draw(page, 10, 10, layoutFormat) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified ,x,y coordinates and width. The page of the table should be drawn. The x co-ordinate of the element. The y coordinate of the element. The width of the table. The PdfLightTable layout result //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the Data Table. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the Data Table.//you can add multiple rows table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page, 10, 10, 500); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the Data Table. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the Data Table.//you can add multiple rows table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page, 10, 10, 500) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Draw the in the specified ,x,y coordinates,width and layout format. The page of the table should be drawn. The x coordinate of the element. The y coordinate of the element. The width of the table. The PdfLightTable layout format. The PdfLightTable layout result. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the Data Table. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the Data Table.//you can add multiple rows table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Set properties to paginate the table. PdfLightTableLayoutFormat layoutFormat = new PdfLightTableLayoutFormat(); layoutFormat.Break = PdfLayoutBreakType.FitPage; layoutFormat.Layout = PdfLayoutType.Paginate; //Draw PdfLightTable. pdfLightTable.Draw(page, 10,10,500, layoutFormat); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the Data Table. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the Data Table.//you can add multiple rows table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Set properties to paginate the table. Dim layoutFormat As New PdfLightTableLayoutFormat() layoutFormat.Break = PdfLayoutBreakType.FitPage layoutFormat.Layout = PdfLayoutType.Paginate 'Draw PdfLightTable. pdfLightTable.Draw(page, 10,10,500, layoutFormat) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Apply built-in table style to the table enum of PdfLightTableBuiltinStyle //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Apply built-in table style to the table enum of PdfLightTableBuiltinStyle The PdfLightTableBuiltinStyleSettings //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Draw the in the specified and x,y coordinates. Graphics context where the element should be printed. The x co-ordinate of the element. The y co-ordinate of the element. //Create a new PDF document. PdfDocument document = new PdfDocument(); //Add a page. PdfPage page = document.Pages.Add(); // Create a PdfLightTable. PdfLightTable pdfLightTable = new PdfLightTable(); // Initialize DataTable to assign as DataSource to the light table. DataTable table = new DataTable(); //Include columns to the Data Table. table.Columns.Add("Name"); table.Columns.Add("Age"); table.Columns.Add("Sex"); //Include rows to the Data Table.//you can add multiple rows table.Rows.Add(new string[] { "abc", "21", "Male" }); //Assign data source. pdfLightTable.DataSource = table; //Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, 10, 10); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new PDF document. Dim document As New PdfDocument() 'Add a page. Dim page As PdfPage = document.Pages.Add() ' Create a PdfLightTable. Dim pdfLightTable As New PdfLightTable() ' Initialize DataTable to assign as DataSource to the light table. Dim table As New DataTable() 'Include columns to the Data Table. table.Columns.Add("Name") table.Columns.Add("Age") table.Columns.Add("Sex") 'Include rows to the Data Table.//you can add multiple rows table.Rows.Add(New String() { "abc", "21", "Male" }) 'Assign data source. pdfLightTable.DataSource = table 'Draw PdfLightTable. pdfLightTable.Draw(page.Graphics, 10, 10) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Layouts the element. Lay outing parameters. Returns lay outing results. Draws an element on the Graphics. Graphics context where the element should be printed. Raises the event. The instance containing the event data. Raises the event. The instance containing the event data. Raises the event. The instance containing the event data. Raises the event. The instance containing the event data. Gets the next row. The index. The array of the strings. Gets the column captions. Column captions Creates a data source consumer. The data source. The proper data source consumer Initializes the PdfLightTable data source. Creates the columns. The filled column collection. Creates the row. The filled row collection. Called when geting next row. Index of the row. The row data passed by the user. Called when getting column number. The number provided by the user. Called when getting row number. The number provided by the user. Gets the collection of columns contained in the table.Read-Only. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Creating Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Get the row collection PdfRowCollection rows = table.Rows; // Adding Rows rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //save the document document.Save("Output.pdf"); //Close the document. document.Close(true); 'Create a PDF document Dim document As PdfDocument = New PdfDocument() 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As PdfLightTable = New PdfLightTable() 'Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect 'Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns 'Creating Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) 'Adding Rows table.Rows.Add(New Object() {"111", "Maxim", "III"}) 'Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("output.pdf") 'Close the document. document.Close(True) Class Class Class Gets the collection of rows contained in the table.Read-Only. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Creating Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Get the row collection PdfRowCollection rows = table.Rows; // Adding Rows rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //save the document document.Save("Output.pdf"); //Close the document. document.Close(true); ' Create a PDF document Dim document As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = document.Pages.Add() Dim table As PdfLightTable = New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Creating Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Get the row collection Dim rows As PdfRowCollection = table.Rows ' Adding Rows rows.Add(New Object() {"111", "Maxim", "III"}) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document. document.Close(True) Class Class Class Gets or sets the value to distribute the available table width by weighted proportions of table columns. Boolean // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create table PdfLightTable table = new PdfLightTable(); //Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; //Get the columns collection PdfColumnCollection tableColumns = table.Columns; //Creating Columns PdfColumn name = new PdfColumn("Name"); name.Width = 10; //Set second column PdfColumn sirname = new PdfColumn("Sir name"); sirname.Width = 40; //Set third column PdfColumn rollNumber = new PdfColumn("Roll Number"); rollNumber.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); rollNumber.Width = 20; //Set table width float tableWidth = 300; //Enable the ColumnProportionalSizing based on table width table.ColumnProportionalSizing = true; //Add the column tableColumns.Add(name); tableColumns.Add(sirname); tableColumns.Add(rollNumber); //Adding Rows table.Rows.Add(new object[] { "Jan", "Hussaarts", "Developer" }); //Draw the table table.Draw(page, 0, 0, tableWidth); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); Dim document As PdfDocument = New PdfDocument Dim page As PdfPage = document.Pages.Add Dim table As PdfLightTable = New PdfLightTable 'Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect Dim tableColumns As PdfColumnCollection = table.Columns Dim name As PdfColumn = New PdfColumn("Name") name.Width = 10 Dim sirname As PdfColumn = New PdfColumn("Sir name") sirname.Width = 40 Dim rollNumber As PdfColumn = New PdfColumn("Roll Number") rollNumber.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) rollNumber.Width = 20 Dim tableWidth As Single = 300 'Enable the ColumnProportionalSizing based on table width table.ColumnProportionalSizing = true 'Add the column tableColumns.Add(name) tableColumns.Add(sirname) tableColumns.Add(rollNumber) 'Adding Rows table.Rows.Add(New Object() {"Jan", "Hussaarts", "Developer"}) 'Draw the table table.Draw(page, 0, 0, tableWidth) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(true) Gets or sets the data source to bind into PdfLightTable. //Create a new document. PdfDocument document = new PdfDocument(); //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create a new page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //set the data source table.DataSource = dataTable; //Draw the table table.Draw(page.Graphics); //save the document document.Save("Output.pdf"); //Close the document. document.Close(true); // Create a new document PdfDocument document = new PdfDocument(); //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create a new page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //set the data source table.DataSource = dataTable; //Draw the table table.Draw(page.Graphics); //save the document document.Save("Output.pdf"); //Close the document. document.Close(true); Class Class Class Gets or sets the data member which binds the specific data source when there is more than one data source. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Create a new document PdfDocument document = new PdfDocument(); //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create a new page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the data member table.DataMember = "ID1"; table.Style.CellPadding = 16; //Draw the table table.Draw(page.Graphics); //Save the document document.Save("Output.pdf"); //close the document document.Close(true); 'Create a new document Dim document As PdfDocument = New PdfDocument() 'Create DataTable for source Dim dataTable As DataTable = New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() {"Table Features Demo", ""} dataTable.Rows.Add(values) 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As PdfLightTable = New PdfLightTable() table.DataSource = dataTable 'Set the data member table.DataMember = "ID1" table.Style.CellPadding = 16 'Draw the table table.Draw(page.Graphics) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets the data source type of the PdfLightTable. // Create a new document PdfDocument document = new PdfDocument(); //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create a new page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //Set the data source type table.DataSourceType = PdfLightTableDataSourceType.TableDirect; //Set the data table table.DataSource = dataTable; Draw the table table.Draw(page.Graphics); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new document Dim document As PdfDocument = New PdfDocument() 'Create DataTable for source Dim dataTable As DataTable = New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() {"Table Features Demo", ""} dataTable.Rows.Add(values) 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As PdfLightTable = New PdfLightTable() 'Set the data source type table.DataSourceType = PdfLightTableDataSourceType.TableDirect 'Set the data source table.DataSource = dataTable ' Draw the table table.Draw(page.Graphics) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets the style properties in PdfLightTable. //Create a new document PdfDocument document = new PdfDocument(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create the page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //Create the font PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); // Alternative cell style PdfCellStyle altStyle = new PdfCellStyle(font, PdfBrushes.White, PdfPens.Green); altStyle.BackgroundBrush = PdfBrushes.DarkGray; // Table header cell style PdfCellStyle headerStyle = new PdfCellStyle(font, PdfBrushes.White, PdfPens.Brown); headerStyle.BackgroundBrush = PdfBrushes.Red; //Set the table style table.Style.AlternateStyle = altStyle; table.Style.HeaderStyle = headerStyle; //set the data source table.DataSource = dataTable; // Draw the table table.Draw(page.Graphics); //save the document document.Save("output.pdf"); //Close the document document.Close(true); 'Create a new document Dim document As PdfDocument = New PdfDocument() 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() {"Table Features Demo", ""} dataTable.Rows.Add(values) 'Create the page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As PdfLightTable = New PdfLightTable() 'Create the font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Alternative cell style Dim altStyle As PdfCellStyle = New PdfCellStyle(font, PdfBrushes.White, PdfPens.Green) altStyle.BackgroundBrush = PdfBrushes.DarkGray 'Table header cell style Dim headerStyle As PdfCellStyle = New PdfCellStyle(font, PdfBrushes.White, PdfPens.Brown) headerStyle.BackgroundBrush = PdfBrushes.Red 'Set the table style table.Style.AlternateStyle = altStyle table.Style.HeaderStyle = headerStyle 'set the data source table.DataSource = dataTable 'Draw the table table.Draw(page.Graphics) 'save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets a value indicating whether PdfLightTable should ignore sorting in data table. This property is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. // Create a new document PdfDocument document = new PdfDocument(); //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //create the page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Disabling sorting table.IgnoreSorting = true; //Set the data source table.DataSource = dataTable; //Draw the table table.Draw(page.Graphics); //save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new document Dim document As PdfDocument = New PdfDocument() 'Create DataTable for source Dim dataTable As DataTable = New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() {"Table Features Demo", ""} dataTable.Rows.Add(values) 'Create the page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As PdfLightTable = New PdfLightTable() ' Disabling sorting table.IgnoreSorting = True 'Set the data table table.DataSource = dataTable 'Draw the table in page table.Draw(page.Graphics) 'save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets a value indicating whether to raise start row layout event. Gets a value indicating whether to raise end row layout event. Gets a value indicating whether the start cell layout event should be raised. Gets a value indicating whether the end cell layout event should be raised. Gets a value indicating the row break is to be made or not. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Set row break. table.AllowRowBreakAcrossPages = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.GridTable1Light); //Draw light table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Set row break. table.AllowRowBreakAcrossPages = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.GridTable1Light) 'Draw light table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) The event raised on starting row lay outing. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { PdfLightTable table = (PdfLightTable)sender; int count = table.Columns.Count; int[] spanMap = new int[count]; // Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap[0] = 2; spanMap[1] = 3; args.ColumnSpanMap = spanMap; //Set row height. args.MinimalHeight = 30f; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then Dim table As PdfLightTable = CType(sender, PdfLightTable) Dim count As Integer = table.Columns.Count Dim spanMap(count - 1) As Integer ' Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap(0) = 2 spanMap(1) = 3 args.ColumnSpanMap = spanMap 'Set row height. args.MinimalHeight = 30f End If End Sub The event raised on having finished row lay outing. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); //Set the data source pdfLightTable.DataSource = dataTable; // Subscribe the end row event pdfLightTable.EndRowLayout += new EndRowLayoutEventHandler(table_EndRowLayout); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_EndRowLayout(object sender, EndRowLayoutEventArgs args) { if (args.RowIndex == 1) { // Cancel property used to cancel the table rendering operation args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() 'Set the data source pdfLightTable.DataSource = dataTable ' Subscribe the end row event AddHandler pdfLightTable.EndRowLayout, AddressOf table_EndRowLayout 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_EndRowLayout(ByVal sender As Object, ByVal args As EndRowLayoutEventArgs) If args.RowIndex = 1 Then ' Cancel property used to cancel the table rendering operation args.Cancel = True End If End Sub The event raised on starting cell lay outing. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub The event raised on having finished cell layout. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.EndCellLayout += new EndCellLayoutEventHandler(table_EndCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_EndCellLayout(object sender, EndCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.EndCellLayout, AddressOf table_EndCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_EndCellLayout(ByVal sender As Object, ByVal args As EndCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub The event raised when the next row data is requested. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub The event raised when the column number is requested. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndexThen args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub The event raised when the row number is requested. public string[][] datastring = new string[3][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; datastring[2] = new string[] { "333", "Criss", "99" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryRowCount += new QueryRowCountEventHandler(table_QueryRowCount); pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } void table_QueryRowCount(object sender, QueryRowCountEventArgs args) { args.RowCount = 2; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } datastring(2) = New String() { "333", "Criss", "99" } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryRowCount, AddressOf table_QueryRowCount AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Private Sub table_QueryRowCount(ByVal sender As Object, ByVal args As QueryRowCountEventArgs) args.RowCount = 2 End Sub Represents the styles of PdfLightTable. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); //Create Pdf pen for drawing border PdfPen borderPen = new PdfPen(PdfBrushes.DarkBlue); borderPen.Width = 0; //Create brush PdfColor color = new PdfColor(192, 201, 219); PdfSolidBrush brush = new PdfSolidBrush(color); //Create alternative cell styles PdfCellStyle altStyle = new PdfCellStyle(); altStyle.Font = font; altStyle.BackgroundBrush = brush; altStyle.BorderPen = borderPen; // Create default cell style PdfCellStyle defStyle = new PdfCellStyle(); defStyle.Font = font; defStyle.BackgroundBrush = PdfBrushes.White; defStyle.BorderPen = borderPen; // Create header cell style PdfCellStyle headerStyle = new PdfCellStyle(font, PdfBrushes.White, PdfPens.DarkBlue); brush = new PdfSolidBrush(new PdfColor(33, 67, 126)); headerStyle.BackgroundBrush = brush; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //Set the data source table.DataSource = dataTable; // Set the cell styles table.Style.AlternateStyle = altStyle; table.Style.DefaultStyle = defStyle; table.Style.HeaderStyle = headerStyle; // Draw the table table.Draw(page.Graphics, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) 'Create Pdf pen for drawing border Dim borderPen As PdfPen = New PdfPen(PdfBrushes.DarkBlue) borderPen.Width = 0 'Create brush Dim color As PdfColor = New PdfColor(192, 201, 219) Dim brush As PdfSolidBrush = New PdfSolidBrush(color) 'Create alternative cell styles Dim altStyle As PdfCellStyle = New PdfCellStyle() altStyle.Font = font altStyle.BackgroundBrush = brush altStyle.BorderPen = borderPen ' Create default cell style Dim defStyle As PdfCellStyle = New PdfCellStyle() defStyle.Font = font defStyle.BackgroundBrush = PdfBrushes.White defStyle.BorderPen = borderPen ' Create header cell style Dim headerStyle As PdfCellStyle = New PdfCellStyle(font, PdfBrushes.White, PdfPens.DarkBlue) brush = New PdfSolidBrush(New PdfColor(33, 67, 126)) headerStyle.BackgroundBrush = brush 'Create DataTable for source Dim dataTable As DataTable = New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() {"Table Features Demo", ""} dataTable.Rows.Add(values) 'Create the PdfLightTable Dim table As PdfLightTable = New PdfLightTable() 'Set the data source table.DataSource = dataTable 'Set the cell styles table.Style.AlternateStyle = altStyle table.Style.DefaultStyle = defStyle table.Style.HeaderStyle = headerStyle 'Draw the table table.Draw(page.Graphics, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Initializes a new instance of the class. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); //set the border overlap style PdfLightTableStyle style = new PdfLightTableStyle(); style.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; table.Style = style; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draws the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' set the border overlap style Dim style As PdfLightTableStyle = New PdfLightTableStyle() style.BorderOverlapStyle = PdfBorderOverlapStyle.Inside table.Style = style ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draws the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets the default cell style. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); //Create PdfPen for drawing border PdfPen borderPen = new PdfPen(PdfBrushes.DarkBlue); borderPen.Width = 0; // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.Font = font; defaultStyle.BackgroundBrush = PdfBrushes.White; defaultStyle.BorderPen = borderPen; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; // Set the default cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page.Graphics, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) 'Create PdfPen for drawing border Dim borderPen As New PdfPen(PdfBrushes.DarkBlue) borderPen.Width = 0 ' Create default cell style Dim defaultStyle As New PdfCellStyle() defaultStyle.Font = font defaultStyle.BackgroundBrush = PdfBrushes.White defaultStyle.BorderPen = borderPen 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) 'Create PdfLightTable Dim table As New PdfLightTable() 'Set the data source table.DataSource = dataTable ' Set the default cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page.Graphics, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets the alternate style which is the style of the odd rows. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); //Create PdfPen for drawing border PdfPen borderPen = new PdfPen(PdfBrushes.DarkBlue); borderPen.Width = 0; //Create brush PdfColor color = new PdfColor(192, 201, 219); PdfSolidBrush brush = new PdfSolidBrush(color); //Create alternative cell style PdfCellStyle alternateStyle = new PdfCellStyle(); alternateStyle.Font = font; alternateStyle.BackgroundBrush = brush; alternateStyle.BorderPen = borderPen; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //Set the data source table.DataSource = dataTable; // Set the cell styles table.Style.AlternateStyle = alternateStyle; // Draw the table table.Draw(page.Graphics, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) 'Create PdfPen for drawing border Dim borderPen As New PdfPen(PdfBrushes.DarkBlue) borderPen.Width = 0 'Create brush Dim color As New PdfColor(192, 201, 219) Dim brush As New PdfSolidBrush(color) 'Create alternative cell style Dim alternateStyle As New PdfCellStyle() alternateStyle.Font = font alternateStyle.BackgroundBrush = brush alternateStyle.BorderPen = borderPen 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim table As New PdfLightTable() 'Set the data source table.DataSource = dataTable ' Set the cell styles table.Style.AlternateStyle = alternateStyle ' Draw the table table.Draw(page.Graphics, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets a value indicating whether to use rows or column captions for forming header. // Create a new document PdfDocument document = new PdfDocument(); //Add a page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); //Set the header source table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Add a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) 'Set the header source table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the header rows count. // Create a new document PdfDocument document = new PdfDocument(); //Add a page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); table.Style.ShowHeader = true; table.Style.HeaderRowCount = 2; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Add a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) table.Style.ShowHeader = True table.Style.HeaderRowCount = 2 ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'close the document document.Close(True) Class Class Gets or sets the header cell style. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); // Create header cell style PdfCellStyle headerStyle = new PdfCellStyle(); headerStyle.Font = font; headerStyle.BackgroundBrush = PdfBrushes.White; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //Set the data source table.DataSource = dataTable; // Set the cell styles table.Style.HeaderStyle = headerStyle; // Draw the table table.Draw(page.Graphics, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) ' Create header cell style Dim headerStyle As New PdfCellStyle() headerStyle.Font = font headerStyle.BackgroundBrush = PdfBrushes.White 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim table As New PdfLightTable() 'Set the data source table.DataSource = dataTable ' Set the cell styles table.Style.HeaderStyle = headerStyle ' Draw the table table.Draw(page.Graphics, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets a value indicating whether to repeat header on each page. // Create a new document PdfDocument document = new PdfDocument(); //Add a page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions; table.Style.RepeatHeader = true; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Add a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions table.Style.RepeatHeader = True ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets a value indicating whether the header is visible. // Create a new document PdfDocument document = new PdfDocument(); //Add a page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); //Set the properties table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions; table.Style.ShowHeader = true; table.Style.HeaderRowCount = 2; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Add a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) 'Set the properties table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions table.Style.ShowHeader = True table.Style.HeaderRowCount = 2 ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets the space between cells. // Create a new document PdfDocument document = new PdfDocument(); //Add a page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions; //Set the cell spacing table.Style.CellSpacing = 10; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Add a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions 'Set the cell spacing table.Style.CellSpacing = 10 ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the space inside the cells. // Create a new document PdfDocument document = new PdfDocument(); //Add a page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions; // Set the cell padding table.Style.CellPadding = 8; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draws the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Add a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions ' Set the cell padding table.Style.CellPadding = 8 ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draws the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets a value indicating whether the cell borders should overlap its neighbor's borders or be drawn in the cell interior. Please, use this property with caution,because it might cause unexpected results if borders are not the same width and color. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); //set the border overlap style table.Style.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draws the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' set the border overlap style table.Style.BorderOverlapStyle = PdfBorderOverlapStyle.Inside ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draws the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the color of the table border. // Create a new document PdfDocument document = new PdfDocument(); PdfPage page = document.Pages.Add(); PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); //Add the border pen table.Style.BorderPen = PdfPens.BlueViolet; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() Dim page As PdfPage = document.Pages.Add() Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) 'Add the border pen table.Style.BorderPen = PdfPens.BlueViolet ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Represents the information about the cell style. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); //Create PdfPen for drawing border PdfPen borderPen = new PdfPen(PdfBrushes.DarkBlue); borderPen.Width = 0; // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.Font = font; defaultStyle.BackgroundBrush = PdfBrushes.White; defaultStyle.BorderPen = borderPen; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; // Set the default cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page.Graphics, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) 'Create PdfPen for drawing border Dim borderPen As New PdfPen(PdfBrushes.DarkBlue) borderPen.Width = 0 ' Create default cell style Dim defaultStyle As New PdfCellStyle() defaultStyle.Font = font defaultStyle.BackgroundBrush = PdfBrushes.White defaultStyle.BorderPen = borderPen 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) 'Create PdfLightTable Dim table As New PdfLightTable() 'Set the data source table.DataSource = dataTable ' Set the default cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page.Graphics, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Initializes a new instance of the class. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.Font = font; defaultStyle.BackgroundBrush = PdfBrushes.Red; defaultStyle.BorderPen = PdfPens.Blue; //set the string format defaultStyle.StringFormat = new PdfStringFormat(PdfTextAlignment.Justify); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); // Create a new table PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) ' Create default cell style Dim defaultStyle As New PdfCellStyle() defaultStyle.Font = font defaultStyle.BackgroundBrush = PdfBrushes.Red defaultStyle.BorderPen = PdfPens.Blue 'set the string format defaultStyle.StringFormat = New PdfStringFormat(PdfTextAlignment.Justify) 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) ' Create a new table Dim table As New PdfLightTable() table.DataSource = dataTable 'Set the cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Initializes a new instance of the class with specified font,brush and pen. The font of the cell text. the color which fills the cell text. The color of the cell border. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(font, PdfBrushes.Red, PdfPens.Blue); //set the string format defaultStyle.StringFormat = new PdfStringFormat(PdfTextAlignment.Justify); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); // Create a new table PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) ' Create default cell style Dim defaultStyle As New PdfCellStyle(font, PdfBrushes.Red, PdfPens.Blue) 'set the string format defaultStyle.StringFormat = New PdfStringFormat(PdfTextAlignment.Justify) 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) ' Create a new table Dim table As New PdfLightTable() table.DataSource = dataTable 'Set the cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets the font of the text. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); //Create PdfPen for drawing border PdfPen borderPen = new PdfPen(PdfBrushes.DarkBlue); borderPen.Width = 0; // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.Font = font; defaultStyle.BackgroundBrush = PdfBrushes.White; defaultStyle.BorderPen = borderPen; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; // Set the default cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page.Graphics, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) 'Create PdfPen for drawing border Dim borderPen As New PdfPen(PdfBrushes.DarkBlue) borderPen.Width = 0 ' Create default cell style Dim defaultStyle As New PdfCellStyle() defaultStyle.Font = font defaultStyle.BackgroundBrush = PdfBrushes.White defaultStyle.BorderPen = borderPen 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) 'Create PdfLightTable Dim table As New PdfLightTable() 'Set the data source table.DataSource = dataTable ' Set the default cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page.Graphics, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the string format of the cell text. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.Font = font; defaultStyle.BackgroundBrush = PdfBrushes.White; defaultStyle.BorderPen = PdfPens.Blue; //set the string format defaultStyle.StringFormat = new PdfStringFormat(PdfTextAlignment.Justify); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); // Create a new table PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) ' Create default cell style Dim defaultStyle As New PdfCellStyle() defaultStyle.Font = font defaultStyle.BackgroundBrush = PdfBrushes.White defaultStyle.BorderPen = PdfPens.Blue 'set the string format defaultStyle.StringFormat = New PdfStringFormat(PdfTextAlignment.Justify) 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) ' Create a new table Dim table As New PdfLightTable() table.DataSource = dataTable 'Set the cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the color which draws the text outlines. It should be null for default text representation. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.TextPen = PdfPens.BlueViolet; defaultStyle.BorderPen = PdfPens.Black; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); // Create a new table PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create default cell style Dim defaultStyle As New PdfCellStyle() defaultStyle.TextPen = PdfPens.BlueViolet defaultStyle.BorderPen = PdfPens.Black 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) ' Create a new table Dim table As New PdfLightTable() table.DataSource = dataTable 'Set the cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the color which fills the cell text. This brush will be used to fill glyphs interior, which is the default. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.TextPen = PdfPens.BlueViolet; defaultStyle.BorderPen = PdfPens.Black; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); // Create a new table PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create default cell style Dim defaultStyle As New PdfCellStyle() 'set the text brush defaultStyle.TextBrush = PdfBrushes.BlueViolet 'set the border pen defaultStyle.BorderPen = PdfPens.Black 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) ' Create a new table Dim table As New PdfLightTable() table.DataSource = dataTable 'Set the cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the color which draws the border of the cell. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.TextPen = PdfPens.BlueViolet; defaultStyle.BorderPen = PdfPens.Black; //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); // Create a new table PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create default cell style Dim defaultStyle As New PdfCellStyle() 'set the text brush defaultStyle.TextBrush = PdfBrushes.BlueViolet 'set the border pen defaultStyle.BorderPen = PdfPens.Black 'Create DataTable for source Dim dataTable As New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) ' Create a new table Dim table As New PdfLightTable() table.DataSource = dataTable 'Set the cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the color which fills the background of the cell. It's null by default. //Create PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Set font PdfFont font = new PdfStandardFont(PdfFontFamily.Helvetica, 8); // Create default cell style PdfCellStyle defaultStyle = new PdfCellStyle(); defaultStyle.Font = font; defaultStyle.BackgroundBrush = PdfBrushes.Red; defaultStyle.BorderPen = PdfPens.Blue; //set the string format defaultStyle.StringFormat = new PdfStringFormat(PdfTextAlignment.Justify); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); // Create a new table PdfLightTable table = new PdfLightTable(); table.DataSource = dataTable; //Set the cell style table.Style.DefaultStyle = defaultStyle; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Set font Dim font As PdfFont = New PdfStandardFont(PdfFontFamily.Helvetica, 8) ' Create default cell style Dim defaultStyle As New PdfCellStyle() defaultStyle.Font = font defaultStyle.BackgroundBrush = PdfBrushes.Red defaultStyle.BorderPen = PdfPens.Blue 'set the string format defaultStyle.StringFormat = New PdfStringFormat(PdfTextAlignment.Justify) 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Table Features Demo", "" } dataTable.Rows.Add(values) ' Create a new table Dim table As New PdfLightTable() table.DataSource = dataTable 'Set the cell style table.Style.DefaultStyle = defaultStyle ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Gets or sets the border of the PdfLightTable Represents the collection of the columns. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Add Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Add Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Add Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Add Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Initializes a new instance of the class. Add the specified in specified The . // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Add Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Add Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Add Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Add Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Gets the widths of the columns. The total width. An array containing widths. Gets the widths of the columns. The total width. The start column. The end column. An array containing widths. Gets the at the specified index.Read-Only. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Add Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); //Get the table colum by index. PdfColumn column = tableColumns[0]; // Add Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Add Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) 'Get the table colum by index. Dim column As PdfColumn = tableColumns(0) ' Add Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Represents a single column of the table. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Add Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Add Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Add Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Add Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Initializes a new instance of the class. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Creating Columns tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Create a new column PdfColumn rollNumber = new PdfColumn(); //Set the string format rollNumber.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //set the column name rollNumber.ColumnName = "Roll Number"; //Add the column tableColumns.Add(rollNumber); // Adding Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Creating Columns tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Create a new column Dim rollNumber As New PdfColumn() 'Set the string format rollNumber.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'set the column name rollNumber.ColumnName = "Roll Number" 'Add the column tableColumns.Add(rollNumber) ' Adding Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Initializes a new instance of the class with specified width. The width. Initializes a new instance of the class with specified column name. The name of the column. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Creating Columns tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Create a new column PdfColumn rollNumber = new PdfColumn(); //Set the string format rollNumber.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //set the column name rollNumber.ColumnName = "Roll Number"; //Add the column tableColumns.Add(rollNumber); // Adding Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Creating Columns tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Create a new column Dim rollNumber As New PdfColumn() 'Set the string format rollNumber.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'set the column name rollNumber.ColumnName = "Roll Number" 'Add the column tableColumns.Add(rollNumber) ' Adding Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets the string format of the column text The format of the cell text. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Creating Columns tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Create a new column PdfColumn rollNumber = new PdfColumn("Roll Number"); //Set the string format rollNumber.StringFormat = new PdfStringFormat(PdfTextAlignment.Right); //Add the column tableColumns.Add(rollNumber); // Adding Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Creating Columns tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Create a new column Dim rollNumber As New PdfColumn("Roll Number") 'Set the string format rollNumber.StringFormat = New PdfStringFormat(PdfTextAlignment.Right) 'Add the column tableColumns.Add(rollNumber) ' Adding Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets the width of the column. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Creating Columns tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Create a new column PdfColumn rollNumber = new PdfColumn("Roll Number"); //Set the string format rollNumber.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //set the width rollNumber.Width = 20; //Add the column tableColumns.Add(rollNumber); // Adding Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Creating Columns tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Create a new column Dim rollNumber As New PdfColumn("Roll Number") 'Set the string format rollNumber.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'set the width rollNumber.Width = 20 'Add the column tableColumns.Add(rollNumber) ' Adding Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets name of the column. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Creating Columns tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Create a new column PdfColumn rollNumber = new PdfColumn(); //Set the string format rollNumber.StringFormat = new PdfStringFormat(PdfTextAlignment.Left); //set the column name rollNumber.ColumnName = "Roll Number"; //Add the column tableColumns.Add(rollNumber); // Adding Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Creating Columns tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Create a new column Dim rollNumber As New PdfColumn() 'Set the string format rollNumber.StringFormat = New PdfStringFormat(PdfTextAlignment.Left) 'set the column name rollNumber.ColumnName = "Roll Number" 'Add the column tableColumns.Add(rollNumber) ' Adding Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Represents a single row of the table. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Add Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Add Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Add Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Add Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Initializes a new instance of the class. The width. Gets or sets the values which adds to the row. // Create a PDF document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Get the columns collection PdfColumnCollection tableColumns = table.Columns; // Add Columns tableColumns.Add(new PdfColumn("Roll Number")); tableColumns.Add(new PdfColumn("Name")); tableColumns.Add(new PdfColumn("Class")); // Add Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a PDF document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Get the columns collection Dim tableColumns As PdfColumnCollection = table.Columns ' Add Columns tableColumns.Add(New PdfColumn("Roll Number")) tableColumns.Add(New PdfColumn("Name")) tableColumns.Add(New PdfColumn("Class")) ' Add Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Represents the collection of the rows in a PdfLightTable. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // get the row collection PdfRowCollection rowCollection = table.Rows; //Add the rows rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' get the row collection Dim rowCollection As PdfRowCollection = table.Rows 'Add the rows rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Initializes a new instance of the class. Adds the specified row into collection. The to be added into list. Gets or sets the values which adds the row into . // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // get the row collection PdfRowCollection rowCollection = table.Rows; //Add the rows rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' get the row collection Dim rowCollection As PdfRowCollection = table.Rows 'Add the rows rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Gets the at the specified index. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // get the row collection PdfRowCollection rowCollection = table.Rows; //Add the rows rowCollection.Add(new object[] { "111", "Maxim", "III" }); //Get the row by index. PdfRow row = rowCollection[0]; // Draw the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' get the row collection Dim rowCollection As PdfRowCollection = table.Rows 'Add the rows rowCollection.Add(New Object() { "111", "Maxim", "III" }) //Get the row by index. Dim row As PdfRow = rowCollection(0) ' Draw the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Represents as a message deliverer from PdfLightTable class to the user. Class Initializes a new instance of the class with specified message. The message to be thrown. Represents the light table built-in style settings. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply style bands to the columns in a table, //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply style bands to the rows in a table //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply first-column formatting to the first column of the specified table //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply heading-row formatting to the first row of the table. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply first-column formatting to the first column of the specified table. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Gets or sets a value indicating whether to apply last-row formatting to the last row of the specified table. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Represents the parameters for PdfLightTable layout. // Creates a new document PdfDocument document = new PdfDocument(); //Creates a new page and adds it as the last page of the document PdfPage page = document.Pages.Add(); // Creates a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // Adding rows PdfRowCollection rowCollection = table.Rows; // Gets the first row from the collection. rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Creates the layout format PdfLightTableLayoutFormat format = new PdfLightTableLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitElement; format.StartColumnIndex = 1; format.EndColumnIndex = 2; // Draws the table with the layout format table.Draw(page, new PointF(0, 0), format); document.Save("Tables.pdf"); ' Creates a new document Dim document As PdfDocument = New PdfDocument() ' Create a page Dim page As PdfPage = document.Pages.Add() ' Creates a new table Dim table As PdfLightTable = New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' Adding rows Dim rowCollection As PdfRowCollection = table.Rows ' Gets the first row from the collection. rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Creates the layout format Dim format As PdfLightTableLayoutFormat = New PdfLightTableLayoutFormat() format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitElement format.StartColumnIndex = 1 format.EndColumnIndex = 2 ' Draws the table with the layout format table.Draw(page, New PointF(0, 0), format) document.Save("Tables.pdf") Class Class Class Initializes a new instance of the class. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // Adding rows PdfRowCollection rowCollection = table.Rows; // Gets the first row from the collection. rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Create the layout format PdfLightTableLayoutFormat format = new PdfLightTableLayoutFormat(); //set the column index format.StartColumnIndex = 1; format.EndColumnIndex = 2; format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitElement; // Draw the table PdfLightTableLayoutResult result = table.Draw(page, new PointF(0, 0), format); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' Adding rows Dim rowCollection As PdfRowCollection = table.Rows ' Gets the first row from the collection. rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Create the layout format Dim format As New PdfLightTableLayoutFormat() 'set the column index format.EndColumnIndex = 2 format.StartColumnIndex = 1 format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitElement ' Draw the table Dim result As PdfLightTableLayoutResult = table.Draw(page, New PointF(0, 0), format 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Initializes a new instance of the class with specified layout format. The layout format. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // Adding rows PdfRowCollection rowCollection = table.Rows; // Gets the first row from the collection. rowCollection.Add(new object[] { "111", "Maxim", "III" }); PdfLayoutFormat lformat = new PdfLayoutFormat(); lformat.Break = PdfLayoutBreakType.FitPage; lformat.Layout = PdfLayoutType.Paginate; lformat.PaginateBounds = new RectangleF(0, 0, 500, 700); // Create the layout format PdfLightTableLayoutFormat format = new PdfLightTableLayoutFormat(lformat); //set the column index format.StartColumnIndex = 1; format.EndColumnIndex = 2; // Draw the table PdfLightTableLayoutResult result = table.Draw(page, new PointF(0, 0), format); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' Adding rows Dim rowCollection As PdfRowCollection = table.Rows ' Gets the first row from the collection. rowCollection.Add(New Object() { "111", "Maxim", "III" }) Dim lformat As PdfLayoutFormat = New PdfLayoutFormat(); lformat.Break = PdfLayoutBreakType.FitPage; lformat.Layout = PdfLayoutType.Paginate; lformat.PaginateBounds = new RectangleF(0, 0, 500, 700); ' Create the layout format Dim format As New PdfLightTableLayoutFormat(lformat) 'set the column index format.EndColumnIndex = 2 format.StartColumnIndex = 1 ' Draw the table Dim result As PdfLightTableLayoutResult = table.Draw(page, New PointF(0, 0), format 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Gets or sets the start column index. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // Adding rows PdfRowCollection rowCollection = table.Rows; // Gets the first row from the collection. rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Create the layout format PdfLightTableLayoutFormat format = new PdfLightTableLayoutFormat(); //set the column index format.StartColumnIndex = 1; format.EndColumnIndex = 2; format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitElement; // Draw the table PdfLightTableLayoutResult result = table.Draw(page, new PointF(0, 0), format); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' Adding rows Dim rowCollection As PdfRowCollection = table.Rows ' Gets the first row from the collection. rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Create the layout format Dim format As New PdfLightTableLayoutFormat() 'set the column index format.EndColumnIndex = 2 format.StartColumnIndex = 1 format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitElement ' Draw the table Dim result As PdfLightTableLayoutResult = table.Draw(page, New PointF(0, 0), format 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Gets or sets the end column index. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); // Create a new table PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Creating Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); // Adding rows PdfRowCollection rowCollection = table.Rows; // Gets the first row from the collection. rowCollection.Add(new object[] { "111", "Maxim", "III" }); // Create the layout format PdfLightTableLayoutFormat format = new PdfLightTableLayoutFormat(); //set the column index format.StartColumnIndex = 1; format.EndColumnIndex = 2; format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitElement; // Draw the table PdfLightTableLayoutResult result = table.Draw(page, new PointF(0, 0), format); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() ' Create a new table Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Creating Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' Adding rows Dim rowCollection As PdfRowCollection = table.Rows ' Gets the first row from the collection. rowCollection.Add(New Object() { "111", "Maxim", "III" }) ' Create the layout format Dim format As New PdfLightTableLayoutFormat() 'set the column index format.EndColumnIndex = 2 format.StartColumnIndex = 1 format.Layout = PdfLayoutType.Paginate format.Break = PdfLayoutBreakType.FitElement ' Draw the table Dim result As PdfLightTableLayoutResult = table.Draw(page, New PointF(0, 0), format 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Class Represents the method that handles StartRowLayout event of PdfLightTable. The sender of the event. The arguments of the event. This event is raised when starting a row layout. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { PdfLightTable table = (PdfLightTable)sender; int count = table.Columns.Count; int[] spanMap = new int[count]; // Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap[0] = 2; spanMap[1] = 3; args.ColumnSpanMap = spanMap; //Set row height. args.MinimalHeight = 30f; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then Dim table As PdfLightTable = CType(sender, PdfLightTable) Dim count As Integer = table.Columns.Count Dim spanMap(count - 1) As Integer ' Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap(0) = 2 spanMap(1) = 3 args.ColumnSpanMap = spanMap 'Set row height. args.MinimalHeight = 30f End If End Sub Class Class Represents the method that will handle EndRowLayout event of PdfLightTable. The sender of the event. The arguments of the event. This event is raised when finishing a row in a layout. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); //Set the data source pdfLightTable.DataSource = dataTable; // Subscribe the end row event pdfLightTable.EndRowLayout += new EndRowLayoutEventHandler(table_EndRowLayout); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_EndRowLayout(object sender, EndRowLayoutEventArgs args) { if (args.RowIndex == 1) { // Cancel property used to cancel the table rendering operation args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() 'Set the data source pdfLightTable.DataSource = dataTable ' Subscribe the end row event AddHandler pdfLightTable.EndRowLayout, AddressOf table_EndRowLayout 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_EndRowLayout(ByVal sender As Object, ByVal args As EndRowLayoutEventArgs) If args.RowIndex = 1 Then ' Cancel property used to cancel the table rendering operation args.Cancel = True End If End Sub Class Class Represents the method that handles StartCellLayout event of PdfLightTable. The sender of the event. The arguments of the event. This event is raised when starts laying out a cell on a page. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Class Class Represents the method that will handle EndCellLayout event of PdfLightTable. The sender of the event. The arguments of the event. This event is raised when finished laying out a cell on a page. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.EndCellLayout += new EndCellLayoutEventHandler(table_EndCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_EndCellLayout(object sender, EndCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.EndCellLayout, AddressOf table_EndCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_EndCellLayout(ByVal sender As Object, ByVal args As EndCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Class Class Represents the method for handling NextRowEvent of PdfLightTable The sender of the event. The arguments of the event. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex ) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Class Class Represents the method for handling ColumnNumberEvent. The sender of the event. The arguments of the event. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Class Class Represents the method for handling RowNumberEvent The sender of the event. The arguments of the event. public string[][] datastring = new string[3][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; datastring[2] = new string[] { "333", "Criss", "99" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryRowCount += new QueryRowCountEventHandler(table_QueryRowCount); pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex ) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } void table_QueryRowCount(object sender, QueryRowCountEventArgs args) { args.RowCount = 2; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } datastring(2) = New String() { "333", "Criss", "99" } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryRowCount, AddressOf table_QueryRowCount AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Private Sub table_QueryRowCount(ByVal sender As Object, ByVal args As QueryRowCountEventArgs) args.RowCount = 2 End Sub Class Class Represents the arguments of StartRowLayout Event. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { PdfLightTable table = (PdfLightTable)sender; int count = table.Columns.Count; int[] spanMap = new int[count]; // Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap[0] = 2; spanMap[1] = 3; args.ColumnSpanMap = spanMap; //Set row height. args.MinimalHeight = 30f; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then Dim table As PdfLightTable = CType(sender, PdfLightTable) Dim count As Integer = table.Columns.Count Dim spanMap(count - 1) As Integer ' Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap(0) = 2 spanMap(1) = 3 args.ColumnSpanMap = spanMap 'Set row height. args.MinimalHeight = 30f End If End Sub Class Class Initializes a new instance of the class. Index of the row. The cell style. Gets the index of the row. Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { PdfLightTable table = (PdfLightTable)sender; int count = table.Columns.Count; int[] spanMap = new int[count]; // Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap[0] = 2; spanMap[1] = 3; args.ColumnSpanMap = spanMap; //Set row height. args.MinimalHeight = 30f; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then Dim table As PdfLightTable = CType(sender, PdfLightTable) Dim count As Integer = table.Columns.Count Dim spanMap(count - 1) As Integer ' Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap(0) = 2 spanMap(1) = 3 args.ColumnSpanMap = spanMap 'Set row height. args.MinimalHeight = 30f End If End Sub Gets or sets the cell style. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { args.CellStyle.TextPen = PdfPens.Red; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then args.CellStyle.TextPen = PdfPens.Red End If End Sub Gets or sets the span map. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { PdfLightTable table = (PdfLightTable)sender; int count = table.Columns.Count; int[] spanMap = new int[count]; // Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap[0] = 2; spanMap[1] = 3; args.ColumnSpanMap = spanMap; //Set row height. args.MinimalHeight = 30f; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then Dim table As PdfLightTable = CType(sender, PdfLightTable) Dim count As Integer = table.Columns.Count Dim spanMap(count - 1) As Integer ' Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap(0) = 2 spanMap(1) = 3 args.ColumnSpanMap = spanMap 'Set row height. args.MinimalHeight = 30f End If End Sub Gets or sets a value indicating whether table drawing should stop. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then args.Cancel = True End If End Sub Gets or sets a value indicating whether this row should be ignored. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { args.Skip = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then args.Skip = True End If End Sub Gets or sets a value indicating whether column string format should be ignored. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { args.IgnoreColumnFormat = true; PdfLightTable table = (PdfLightTable)sender; int count = table.Columns.Count; int[] spanMap = new int[count]; // Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap[0] = 2; spanMap[1] = 3; args.ColumnSpanMap = spanMap; //Set row height. args.MinimalHeight = 30f; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then args.IgnoreColumnFormat = True Dim table As PdfLightTable = CType(sender, PdfLightTable) Dim count As Integer = table.Columns.Count Dim spanMap(count - 1) As Integer ' Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap(0) = 2 spanMap(1) = 3 args.ColumnSpanMap = spanMap 'Set row height. args.MinimalHeight = 30f End If End Sub Sets the minimal height of the row. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the begin row event pdfLightTable.BeginRowLayout += new BeginRowLayoutEventHandler(table_BeginRowLayout); //Set the data source pdfLightTable.DataSource = dataTable; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_BeginRowLayout(object sender, BeginRowLayoutEventArgs args) { if (args.RowIndex == 1) { PdfLightTable table = (PdfLightTable)sender; int count = table.Columns.Count; int[] spanMap = new int[count]; // Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap[0] = 2; spanMap[1] = 3; args.ColumnSpanMap = spanMap; //Set row height. args.MinimalHeight = 30f; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the begin row event AddHandler pdfLightTable.BeginRowLayout, AddressOf table_BeginRowLayout 'Set the data source pdfLightTable.DataSource = dataTable 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_BeginRowLayout(ByVal sender As Object, ByVal args As BeginRowLayoutEventArgs) If args.RowIndex = 1 Then Dim table As PdfLightTable = CType(sender, PdfLightTable) Dim count As Integer = table.Columns.Count Dim spanMap(count - 1) As Integer ' Set just spanned cells. Other values are not important except negatives that are not allowed. spanMap(0) = 2 spanMap(1) = 3 args.ColumnSpanMap = spanMap 'Set row height. args.MinimalHeight = 30f End If End Sub Represents the arguments of EndRowLayoutEvent. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); //Set the data source pdfLightTable.DataSource = dataTable; // Subscribe the end row event pdfLightTable.EndRowLayout += new EndRowLayoutEventHandler(table_EndRowLayout); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_EndRowLayout(object sender, EndRowLayoutEventArgs args) { if (args.RowIndex == 1) { // Cancel property used to cancel the table rendering operation args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() 'Set the data source pdfLightTable.DataSource = dataTable ' Subscribe the end row event AddHandler pdfLightTable.EndRowLayout, AddressOf table_EndRowLayout 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_EndRowLayout(ByVal sender As Object, ByVal args As EndRowLayoutEventArgs) If args.RowIndex = 1 Then ' Cancel property used to cancel the table rendering operation args.Cancel = True End If End Sub Class Class Initializes a new instance of the class. Index of the row. if set to true the row was drawn completely. The row bounds. Gets the index of the row. Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); //Set the data source pdfLightTable.DataSource = dataTable; // Subscribe the end row event pdfLightTable.EndRowLayout += new EndRowLayoutEventHandler(table_EndRowLayout); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_EndRowLayout(object sender, EndRowLayoutEventArgs args) { if (args.RowIndex == 1) { // Cancel property used to cancel the table rendering operation args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() 'Set the data source pdfLightTable.DataSource = dataTable ' Subscribe the end row event AddHandler pdfLightTable.EndRowLayout, AddressOf table_EndRowLayout 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_EndRowLayout(ByVal sender As Object, ByVal args As EndRowLayoutEventArgs) If args.RowIndex = 1 Then ' Cancel property used to cancel the table rendering operation args.Cancel = True End If End Sub Gets a value indicating whether the row was drawn completely (nothing should be printed on the next page). Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); //Set the data source pdfLightTable.DataSource = dataTable; // Subscribe the end row event pdfLightTable.EndRowLayout += new EndRowLayoutEventHandler(table_EndRowLayout); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_EndRowLayout(object sender, EndRowLayoutEventArgs args) { bool isCompleted = args.LayoutCompleted; if (args.RowIndex == 1) { // Cancel property used to cancel the table rendering operation args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() 'Set the data source pdfLightTable.DataSource = dataTable ' Subscribe the end row event AddHandler pdfLightTable.EndRowLayout, AddressOf table_EndRowLayout 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_EndRowLayout(ByVal sender As Object, ByVal args As EndRowLayoutEventArgs) Dim isCompleted As Boolean = args.LayoutCompleted If args.RowIndex = 1 Then ' Cancel property used to cancel the table rendering operation args.Cancel = True End If End Sub Gets or sets a value indicating whether this row should be the last one printed. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); //Set the data source pdfLightTable.DataSource = dataTable; // Subscribe the end row event pdfLightTable.EndRowLayout += new EndRowLayoutEventHandler(table_EndRowLayout); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_EndRowLayout(object sender, EndRowLayoutEventArgs args) { if (args.RowIndex == 1) { // Cancel property used to cancel the table rendering operation args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() 'Set the data source pdfLightTable.DataSource = dataTable ' Subscribe the end row event AddHandler pdfLightTable.EndRowLayout, AddressOf table_EndRowLayout 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_EndRowLayout(ByVal sender As Object, ByVal args As EndRowLayoutEventArgs) If args.RowIndex = 1 Then ' Cancel property used to cancel the table rendering operation args.Cancel = True End If End Sub Gets or sets the row bounds. Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); //Set the data source pdfLightTable.DataSource = dataTable; // Subscribe the end row event pdfLightTable.EndRowLayout += new EndRowLayoutEventHandler(table_EndRowLayout); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_EndRowLayout(object sender, EndRowLayoutEventArgs args) { //Get row bounds. RectangleF bounds = args.Bounds; if (args.RowIndex == 1) { // Cancel property used to cancel the table rendering operation args.Cancel = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() 'Set the data source pdfLightTable.DataSource = dataTable ' Subscribe the end row event AddHandler pdfLightTable.EndRowLayout, AddressOf table_EndRowLayout 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_EndRowLayout(ByVal sender As Object, ByVal args As EndRowLayoutEventArgs) 'Get row bounds. Dim bounds As RectangleF = args.Bounds If args.RowIndex = 1 Then ' Cancel property used to cancel the table rendering operation args.Cancel = True End If End Sub The base class for cell layout arguments. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Initializes a new instance of the class. The graphics, on which the cell should be drawn. Index of the row. The cell inder. The bounds of the cell. The value. Gets the index of the row. Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Gets the index of the cell. Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { //Get cell index int cellIndex = args.CellIndex; if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) 'Get cell index Dim cellIndex As Integer = args.CellIndex If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Gets the value of the cell. Read-Only. The value might be null or an empty string, which means that either no text were acquired or all text was on the previous page. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { string text = args.Value; if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) Dim text As String = args.Value If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Gets the bounds of the cell. Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { RectangleF bounds = args.Bounds; if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) Dim bounds As RectangleF = args.Bounds If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Gets the graphics, on which the cell should be drawn. Read-Only. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Represents arguments of StartCellLayout Event. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Class Class Initializes a new instance of the class. The graphics, on which the cell should be drawn. Index of the row. The cell index. The bounds of the cell. The value. Gets or sets a value indicating whether the value of this cell should be skipped. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.BeginCellLayout += new BeginCellLayoutEventHandler(table_BeginCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_BeginCellLayout(object sender, BeginCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } if(args.RowIndex == 2) { args.Skip = true; } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.BeginCellLayout, AddressOf table_BeginCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_BeginCellLayout(ByVal sender As Object, ByVal args As BeginCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If if args.RowIndex =2 Then args.Skip = True End If End Sub Represents arguments of EndCellLayout Event. // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create DataTable for source DataTable dataTable = new DataTable("myTable"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Roll Number", "Student Name" }; dataTable.Rows.Add(values); values = new object[] { "011", "Cris" }; dataTable.Rows.Add(values); values = new object[] { "011", "Clay" }; dataTable.Rows.Add(values); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Subscribe the cell layout event pdfLightTable.EndCellLayout += new EndCellLayoutEventHandler(table_EndCellLayout); pdfLightTable.DataSource = dataTable; pdfLightTable.Style.CellPadding = 16; //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); // Cell layout event handler void table_EndCellLayout(object sender, EndCellLayoutEventArgs args) { if (args.RowIndex == 1) { args.Graphics.DrawRectangle(new PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds); } } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create DataTable for source Dim dataTable As New DataTable("myTable") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = { "Roll Number", "Student Name" } dataTable.Rows.Add(values) values = New Object() { "011", "Cris" } dataTable.Rows.Add(values) values = New Object() { "011", "Clay" } dataTable.Rows.Add(values) 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Subscribe the cell layout event AddHandler pdfLightTable.EndCellLayout, AddressOf table_EndCellLayout pdfLightTable.DataSource = dataTable pdfLightTable.Style.CellPadding = 16 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) ' Cell layout event handler Private Sub table_EndCellLayout(ByVal sender As Object, ByVal args As EndCellLayoutEventArgs) If args.RowIndex = 1 Then args.Graphics.DrawRectangle(New PdfPen(PdfBrushes.Red, 2), PdfBrushes.White, args.Bounds) End If End Sub Class Class Initializes a new instance of the class. The graphics, on which the cell should be drawn. Index of the row. The index of the cell. The bounds of the cell. The value. Represents arguments of the NextRowEvent. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Class Class Initializes a new instance of the class. The column count. Index of the row. Gets or sets the row data. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Gets the column count. Read-Only. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Gets the index of the row. Read-Only. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Represents the arguments of the ColumnNumberEvent. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndexThen args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Class Class Initializes a new instance of the class. Gets or sets the column number. public string[][] datastring = new string[2][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } ' Create a new document' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndexThen args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Represents the arguments of the RowNumberEvent. public string[][] datastring = new string[3][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; datastring[2] = new string[] { "333", "Criss", "99" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryRowCount += new QueryRowCountEventHandler(table_QueryRowCount); pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } void table_QueryRowCount(object sender, QueryRowCountEventArgs args) { args.RowCount = 2; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } datastring(2) = New String() { "333", "Criss", "99" } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryRowCount, AddressOf table_QueryRowCount AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Private Sub table_QueryRowCount(ByVal sender As Object, ByVal args As QueryRowCountEventArgs) args.RowCount = 2 End Sub Class Class Initializes a new instance of the class. Gets or sets the column number. public string[][] datastring = new string[3][]; // Specify values for the table datastring[0] = new string[] { "111", "Maxim", "100" }; datastring[1] = new string[] { "222", "Calvin", "95" }; datastring[2] = new string[] { "333", "Criss", "99" }; // Create a new document PdfDocument document = new PdfDocument(); //Create a Page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable pdfLightTable = new PdfLightTable(); // Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External; //Subscribing Events pdfLightTable.QueryRowCount += new QueryRowCountEventHandler(table_QueryRowCount); pdfLightTable.QueryColumnCount += new QueryColumnCountEventHandler(table_QueryColumnCount); pdfLightTable.QueryNextRow += new QueryNextRowEventHandler(table_QueryNextRow); //Draw PdfLightTable. pdfLightTable.Draw(page, new PointF(0, 0)); //Save the document. document.Save("Output.pdf"); //Close the document document.Close(true); void table_QueryColumnCount(object sender, QueryColumnCountEventArgs args) { args.ColumnCount = 3; } void table_QueryNextRow(object sender, QueryNextRowEventArgs args) { if (datastring.Length > args.RowIndex) args.RowData = new string[] { datastring[args.RowIndex][0], datastring[args.RowIndex][1], datastring[args.RowIndex][2] }; } void table_QueryRowCount(object sender, QueryRowCountEventArgs args) { args.RowCount = 2; } Public datastring(2)() As String ' Specify values for the table datastring(0) = New String() { "111", "Maxim", "100" } datastring(1) = New String() { "222", "Calvin", "95" } datastring(2) = New String() { "333", "Criss", "99" } ' Create a new document Dim document As New PdfDocument() 'Create a Page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim pdfLightTable As New PdfLightTable() ' Setting the DataSourceType as Direct pdfLightTable.DataSourceType = PdfLightTableDataSourceType.External 'Subscribing Events AddHandler pdfLightTable.QueryRowCount, AddressOf table_QueryRowCount AddHandler pdfLightTable.QueryColumnCount, AddressOf table_QueryColumnCount AddHandler pdfLightTable.QueryNextRow, AddressOf table_QueryNextRow 'Draw PdfLightTable. pdfLightTable.Draw(page, New PointF(0, 0)) 'Save the document. document.Save("Output.pdf") 'Close the document document.Close(True) Private Sub table_QueryColumnCount(ByVal sender As Object, ByVal args As QueryColumnCountEventArgs) args.ColumnCount = 3 End Sub Private Sub table_QueryNextRow(ByVal sender As Object, ByVal args As QueryNextRowEventArgs) If datastring.Length > args.RowIndex Then args.RowData = New String() { datastring(args.RowIndex)(0), datastring(args.RowIndex)(1), datastring(args.RowIndex)(2) } End If End Sub Private Sub table_QueryRowCount(ByVal sender As Object, ByVal args As QueryRowCountEventArgs) args.RowCount = 2 End Sub Specifies the values where the header should formed from. // Create a new document PdfDocument document = new PdfDocument(); //Add a page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); //Set the header source table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draw the table table.Draw(page, new PointF(0, 0)); //save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Add a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) 'Set the header source table.Style.HeaderSource = PdfHeaderSource.ColumnCaptions ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draw the table table.Draw(page, New PointF(0, 0)) 'save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class The header is formed from column captions' values. The header is formed from rows. Specifies the data source type. // Create a new document PdfDocument document = new PdfDocument(); //Create DataTable for source DataTable dataTable = new DataTable("Table"); dataTable.Columns.Add("ID1"); dataTable.Columns[0].Caption = "id"; dataTable.Columns.Add("ID2"); object[] values = new object[] { "Table Features Demo", "" }; dataTable.Rows.Add(values); //Create a new page PdfPage page = document.Pages.Add(); //Create the PdfLightTable PdfLightTable table = new PdfLightTable(); //Set the data source type table.DataSourceType = PdfLightTableDataSourceType.TableDirect; //Set the data table table.DataSource = dataTable; Draw the table table.Draw(page.Graphics); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); 'Create a new document Dim document As PdfDocument = New PdfDocument() 'Create DataTable for source Dim dataTable As DataTable = New DataTable("Table") dataTable.Columns.Add("ID1") dataTable.Columns(0).Caption = "id" dataTable.Columns.Add("ID2") Dim values() As Object = New Object() {"Table Features Demo", ""} dataTable.Rows.Add(values) 'Create a page Dim page As PdfPage = document.Pages.Add() 'Create the PdfLightTable Dim table As PdfLightTable = New PdfLightTable() 'Set the data source type table.DataSourceType = PdfLightTableDataSourceType.TableDirect 'Set the data source table.DataSource = dataTable ' Draw the table table.Draw(page.Graphics) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Class Class Specifies that the PdfLightTable has been bind to an external data source. Specifies that the values are directly bind to the PdfLightTable. Specifies the values of the border overlap style. // Create a new document PdfDocument document = new PdfDocument(); //Create a new page PdfPage page = document.Pages.Add(); //Create PdfLightTable PdfLightTable table = new PdfLightTable(); // Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect; // Create new Columns table.Columns.Add(new PdfColumn("Roll Number")); table.Columns.Add(new PdfColumn("Name")); table.Columns.Add(new PdfColumn("Class")); //set the border overlap style table.Style.BorderOverlapStyle = PdfBorderOverlapStyle.Inside; // Add new Rows table.Rows.Add(new object[] { "111", "Maxim", "III" }); // Draws the table table.Draw(page, new PointF(0, 0)); //Save the document document.Save("Output.pdf"); //Close the document document.Close(true); ' Create a new document Dim document As New PdfDocument() 'Create a new page Dim page As PdfPage = document.Pages.Add() 'Create PdfLightTable Dim table As New PdfLightTable() ' Set the DataSourceType as Direct table.DataSourceType = PdfLightTableDataSourceType.TableDirect ' Create new Columns table.Columns.Add(New PdfColumn("Roll Number")) table.Columns.Add(New PdfColumn("Name")) table.Columns.Add(New PdfColumn("Class")) ' set the border overlap style table.Style.BorderOverlapStyle = PdfBorderOverlapStyle.Inside ' Add new Rows table.Rows.Add(New Object() { "111", "Maxim", "III" }) ' Draws the table table.Draw(page, New PointF(0, 0)) 'Save the document document.Save("Output.pdf") 'Close the document document.Close(True) Cell borders overlap (are drawn using the same coordinates). Cell borders are drawn in the cell's interior. Specifies PdfGrid built-in table styles. //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF grid instance. PdfGrid table = new PdfGrid(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF grid build style settings instance. PdfGridBuiltinStyleSettings settings = new PdfGridBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings); //Draw grid to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF grid instance. Dim table As New PdfGrid() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF grid build style settings instance. Dim settings As New PdfGridBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True Apply built-in table style table.ApplyBuiltinStyle(PdfGridBuiltinStyle.GridTable3, settings) 'Draw grid to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Specifies the grid to render Plain Table 1 style. Specifies the grid to render Plain Table 2 style. Specifies the grid to render Plain Table 3 style. Specifies the grid to render Plain Table 4 style. Specifies the grid to render Plain Table 5 style. Specifies the grid to render Grid Table 1 Light style. Specifies the grid to render Grid Table 1 Light - Accent 1 style. Specifies the grid to render Grid Table 1 Light - Accent 2 style. Specifies the grid to render Grid Table 1 Light - Accent 3 style. Specifies the grid to render Grid Table 1 Light - Accent 4 style. Specifies the grid to render Grid Table 1 Light - Accent 5 style. Specifies the grid to render Grid Table 1 Light - Accent 6 style. Specifies the grid to render Grid Table 2 style. Specifies the grid to render Grid Table 2 - Accent 1 style. Specifies the grid to render Grid Table 2 - Accent 2 style. Specifies the grid to render Grid Table 2 - Accent 3 style. Specifies the grid to render Grid Table 2 - Accent 4 style. Specifies the grid to render Grid Table 2 - Accent 5 style. Specifies the grid to render Grid Table 2 - Accent 6 style. Specifies the grid to render Grid Table 3 style. Specifies the grid to render Grid Table 3 - Accent 1 style. Specifies the grid to render Grid Table 3 - Accent 2 style. Specifies the grid to render Grid Table 3 - Accent 3 style. Specifies the grid to render Grid Table 3 - Accent 4 style. Specifies the grid to render Grid Table 3 - Accent 5 style. Specifies the grid to render Grid Table 3 - Accent 6 style. Specifies the grid to render Grid Table 4 style. Specifies the grid to render Grid Table 4 - Accent 1 style. Specifies the grid to render Grid Table 4 - Accent 2 style. Specifies the grid to render Grid Table 4 - Accent 3 style. Specifies the grid to render Grid Table 4 - Accent 4 style. Specifies the grid to render Grid Table 4 - Accent 5 style. Specifies the grid to render Grid Table 4 - Accent 6 style. Specifies the grid to render Grid Table 5 Dark style. Specifies the grid to render Grid Table 5 Dark - Accent 1 style. Specifies the grid to render Grid Table 5 Dark - Accent 2 style. Specifies the grid to render Grid Table 5 Dark - Accent 3 style. Specifies the grid to render Grid Table 5 Dark - Accent 4 style. Specifies the grid to render Grid Table 5 Dark - Accent 5 style. Specifies the grid to render Grid Table 5 Dark - Accent 6 style. Specifies the grid to render Grid Table 6 Colorful style. Specifies the grid to render Grid Table 6 Colorful - Accent 1 style. Specifies the grid to render Grid Table 6 Colorful - Accent 2 style. Specifies the grid to render Grid Table 6 Colorful - Accent 3 style. Specifies the grid to render Grid Table 6 Colorful - Accent 4 style. Specifies the grid to render Grid Table 6 Colorful - Accent 5 style. Specifies the grid to render Grid Table 6 Colorful - Accent 6 style. Specifies the grid to render Grid Table 7 Colorful style. Specifies the grid to render Grid Table 7 Colorful - Accent 1 style. Specifies the grid to render Grid Table 7 Colorful - Accent 2 style. Specifies the grid to render Grid Table 7 Colorful - Accent 3 style. Specifies the grid to render Grid Table 7 Colorful - Accent 4 style. Specifies the grid to render Grid Table 7 Colorful - Accent 5 style. Specifies the grid to render Grid Table 7 Colorful - Accent 6 style. Specifies the grid to render Light Table 1 Light style. Specifies the grid to render Light Table 1 Light - Accent 1 style. Specifies the grid to render Light Table 1 Light - Accent 2 style. Specifies the grid to render Light Table 1 Light - Accent 3 style. Specifies the grid to render Light Table 1 Light - Accent 4 style. Specifies the grid to render Light Table 1 Light - Accent 5 style. Specifies the grid to render Light Table 1 Light - Accent 6 style. Specifies the grid to render Light Table 2 style. Specifies the grid to render Light Table 2 - Accent 1 style. Specifies the grid to render Light Table 2 - Accent 2 style. Specifies the grid to render Light Table 2 - Accent 3 style. Specifies the grid to render Light Table 2 - Accent 4 style. Specifies the grid to render Light Table 2 - Accent 5 style. Specifies the grid to render Light Table 2 - Accent 6 style. Specifies the grid to render Light Table 3 style. Specifies the grid to render Light Table 3 - Accent 1 style. Specifies the grid to render Light Table 3 - Accent 2 style. Specifies the grid to render Light Table 3 - Accent 3 style. Specifies the grid to render Light Table 3 - Accent 4 style. Specifies the grid to render Light Table 3 - Accent 5 style. Specifies the grid to render Light Table 3 - Accent 6 style. Specifies the grid to render Light Table 4 style. Specifies the grid to render Light Table 4 - Accent 1 style. Specifies the grid to render Light Table 4 - Accent 2 style. Specifies the grid to render Light Table 4 - Accent 3 style. Specifies the grid to render Light Table 4 - Accent 4 style. Specifies the grid to render Light Table 4 - Accent 5 style. Specifies the grid to render Light Table 4 - Accent 6 style. Specifies the grid to render Light Table 5 Dark style. Specifies the grid to render Light Table 5 Dark - Accent 1 style. Specifies the grid to render Light Table 5 Dark - Accent 2 style. Specifies the grid to render Light Table 5 Dark - Accent 3 style. Specifies the grid to render Light Table 5 Dark - Accent 4 style. Specifies the grid to render Light Table 5 Dark - Accent 5 style. Specifies the grid to render Light Table 5 Dark - Accent 6 style. Specifies the grid to render Light Table 6 Colorful style. Specifies the grid to render Light Table 6 Colorful - Accent 1 style. Specifies the grid to render Light Table 6 Colorful - Accent 2 style. Specifies the grid to render Light Table 6 Colorful - Accent 3 style. Specifies the grid to render Light Table 6 Colorful - Accent 4 style. Specifies the grid to render Light Table 6 Colorful - Accent 5 style. Specifies the grid to render Light Table 6 Colorful - Accent 6 style. Specifies the grid to render Light Table 7 Colorful style. Specifies the grid to render Light Table 7 Colorful - Accent 1 style. Specifies the grid to render Light Table 7 Colorful - Accent 2 style. Specifies the grid to render Light Table 7 Colorful - Accent 3 style. Specifies the grid to render Light Table 7 Colorful - Accent 4 style. Specifies the grid to render Light Table 7 Colorful - Accent 5 style. Specifies the grid to render Light Table 7 Colorful - Accent 6 style. Specifies the grid to render Table Grid Light style. Specifies the grid to render Table Grid style. Specified PdfLightTable built-in table styles //Create a new PDF document. PdfDocument doc = new PdfDocument(); //Add a page. PdfPage page = doc.Pages.Add(); //Create a new PDF light table instance. PdfLightTable table = new PdfLightTable(); //Create a DataTable. DataTable dataTable = new DataTable(); //Add columns to the DataTable dataTable.Columns.Add("ID"); dataTable.Columns.Add("Name"); //Add rows to the DataTable. dataTable.Rows.Add(new object[] { "E01", "Clay" }); dataTable.Rows.Add(new object[] { "E02", "Thomas" }); dataTable.Rows.Add(new object[] { "E03", "George" }); dataTable.Rows.Add(new object[] { "E04", "Stefan" }); dataTable.Rows.Add(new object[] { "E05", "Mathew" }); //Assign data source. table.DataSource = dataTable; //Create PDF light table build style settings instance. dfLightTableBuiltinStyleSettings settings = new PdfLightTableBuiltinStyleSettings(); settings.ApplyStyleForBandedColumns = true; settings.ApplyStyleForBandedRows = true; settings.ApplyStyleForFirstColumn = true; settings.ApplyStyleForHeaderRow = true; settings.ApplyStyleForLastColumn = true; settings.ApplyStyleForLastRow = true; //Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings); //Draw table to the page of PDF document. table.Draw(page, new PointF(10, 10)); //Save the document. doc.Save("Output.pdf"); //close the document doc.Close(true); 'Create a new PDF document. Dim doc As New PdfDocument() 'Add a page. Dim page As PdfPage = doc.Pages.Add() 'Create a new PDF light table instance. Dim table As New PdfLightTable() 'Create a DataTable. Dim dataTable As New DataTable() 'Add columns to the DataTable dataTable.Columns.Add("ID") dataTable.Columns.Add("Name") 'Add rows to the DataTable. dataTable.Rows.Add(New Object() { "E01", "Clay"}) dataTable.Rows.Add(New Object() { "E02", "Thomas"}) dataTable.Rows.Add(New Object() { "E03", "George"}) dataTable.Rows.Add(New Object() { "E04", "Stefan"}) dataTable.Rows.Add(New Object() { "E05", "Mathew"}) 'Assign data source. table.DataSource = dataTable 'Create PDF light table build style settings instance. Dim settings As New PdfLightTableBuiltinStyleSettings() settings.ApplyStyleForBandedColumns = True settings.ApplyStyleForBandedRows = True settings.ApplyStyleForFirstColumn = True settings.ApplyStyleForHeaderRow = True settings.ApplyStyleForLastColumn = True settings.ApplyStyleForLastRow = True 'Apply built-in table style table.ApplyBuiltinStyle(PdfLightTableBuiltinStyle.ListTable6ColorfulAccent4, settings) 'Draw table to the page of PDF document. table.Draw(page, New PointF(10, 10)) 'Save the document. doc.Save("Output.pdf") 'close the document doc.Close(True) Specifies the table to render Plain Table 1 style. Specifies the table to render Plain Table 2 style. Specifies the table to render Plain Table 3 style. Specifies the table to render Plain Table 4 style. Specifies the table to render Plain Table 5 style. Specifies the table to render Grid Table 1 Light style. Specifies the table to render Grid Table 1 Light - Accent 1 style. Specifies the table to render Grid Table 1 Light - Accent 2 style. Specifies the table to render Grid Table 1 Light - Accent 3 style. Specifies the table to render Grid Table 1 Light - Accent 4 style. Specifies the table to render Grid Table 1 Light - Accent 5 style. Specifies the table to render Grid Table 1 Light - Accent 6 style. Specifies the table to render Grid Table 2 style. Specifies the table to render Grid Table 2 - Accent 1 style. Specifies the table to render Grid Table 2 - Accent 2 style. Specifies the table to render Grid Table 2 - Accent 3 style. Specifies the table to render Grid Table 2 - Accent 4 style. Specifies the table to render Grid Table 2 - Accent 5 style. Specifies the table to render Grid Table 2 - Accent 6 style. Specifies the table to render Grid Table 3 style. Specifies the table to render Grid Table 3 - Accent 1 style. Specifies the table to render Grid Table 3 - Accent 2 style. Specifies the table to render Grid Table 3 - Accent 3 style. Specifies the table to render Grid Table 3 - Accent 4 style. Specifies the table to render Grid Table 3 - Accent 5 style. Specifies the table to render Grid Table 3 - Accent 6 style. Specifies the table to render Grid Table 4 style. Specifies the table to render Grid Table 4 - Accent 1 style. Specifies the table to render Grid Table 4 - Accent 2 style. Specifies the table to render Grid Table 4 - Accent 3 style. Specifies the table to render Grid Table 4 - Accent 4 style. Specifies the table to render Grid Table 4 - Accent 5 style. Specifies the table to render Grid Table 4 - Accent 6 style. Specifies the table to render Grid Table 5 Dark style. Specifies the table to render Grid Table 5 Dark - Accent 1 style. Specifies the table to render Grid Table 5 Dark - Accent 2 style. Specifies the table to render Grid Table 5 Dark - Accent 3 style. Specifies the table to render Grid Table 5 Dark - Accent 4 style. Specifies the table to render Grid Table 5 Dark - Accent 5 style. Specifies the table to render Grid Table 5 Dark - Accent 6 style. Specifies the table to render Grid Table 6 Colorful style. Specifies the table to render Grid Table 6 Colorful - Accent 1 style. Specifies the table to render Grid Table 6 Colorful - Accent 2 style. Specifies the table to render Grid Table 6 Colorful - Accent 3 style. Specifies the table to render Grid Table 6 Colorful - Accent 4 style. Specifies the table to render Grid Table 6 Colorful - Accent 5 style. Specifies the table to render Grid Table 6 Colorful - Accent 6 style. Specifies the table to render Grid Table 7 Colorful style. Specifies the table to render Grid Table 7 Colorful - Accent 1 style. Specifies the table to render Grid Table 7 Colorful - Accent 2 style. Specifies the table to render Grid Table 7 Colorful - Accent 3 style. Specifies the table to render Grid Table 7 Colorful - Accent 4 style. Specifies the table to render Grid Table 7 Colorful - Accent 5 style. Specifies the table to render Grid Table 7 Colorful - Accent 6 style. Specifies the table to render Light Table 1 Light style. Specifies the table to render Light Table 1 Light - Accent 1 style. Specifies the table to render Light Table 1 Light - Accent 2 style. Specifies the table to render Light Table 1 Light - Accent 3 style. Specifies the table to render Light Table 1 Light - Accent 4 style. Specifies the table to render Light Table 1 Light - Accent 5 style. Specifies the table to render Light Table 1 Light - Accent 6 style. Specifies the table to render Light Table 2 style. Specifies the table to render Light Table 2 - Accent 1 style. Specifies the table to render Light Table 2 - Accent 2 style. Specifies the table to render Light Table 2 - Accent 3 style. Specifies the table to render Light Table 2 - Accent 4 style. Specifies the table to render Light Table 2 - Accent 5 style. Specifies the table to render Light Table 2 - Accent 6 style. Specifies the table to render Light Table 3 style. Specifies the table to render Light Table 3 - Accent 1 style. Specifies the table to render Light Table 3 - Accent 2 style. Specifies the table to render Light Table 3 - Accent 3 style. Specifies the table to render Light Table 3 - Accent 4 style. Specifies the table to render Light Table 3 - Accent 5 style. Specifies the table to render Light Table 3 - Accent 6 style. Specifies the table to render Light Table 4 style. Specifies the table to render Light Table 4 - Accent 1 style. Specifies the table to render Light Table 4 - Accent 2 style. Specifies the table to render Light Table 4 - Accent 3 style. Specifies the table to render Light Table 4 - Accent 4 style. Specifies the table to render Light Table 4 - Accent 5 style. Specifies the table to render Light Table 4 - Accent 6 style. Specifies the table to render Light Table 5 Dark style. Specifies the table to render Light Table 5 Dark - Accent 1 style. Specifies the table to render Light Table 5 Dark - Accent 2 style. Specifies the table to render Light Table 5 Dark - Accent 3 style. Specifies the table to render Light Table 5 Dark - Accent 4 style. Specifies the table to render Light Table 5 Dark - Accent 5 style. Specifies the table to render Light Table 5 Dark - Accent 6 style. Specifies the table to render Light Table 6 Colorful style. Specifies the table to render Light Table 6 Colorful - Accent 1 style. Specifies the table to render Light Table 6 Colorful - Accent 2 style. Specifies the table to render Light Table 6 Colorful - Accent 3 style. Specifies the table to render Light Table 6 Colorful - Accent 4 style. Specifies the table to render Light Table 6 Colorful - Accent 5 style. Specifies the table to render Light Table 6 Colorful - Accent 6 style. Specifies the table to render Light Table 7 Colorful style. Specifies the table to render Light Table 7 Colorful - Accent 1 style. Specifies the table to render Light Table 7 Colorful - Accent 2 style. Specifies the table to render Light Table 7 Colorful - Accent 3 style. Specifies the table to render Light Table 7 Colorful - Accent 4 style. Specifies the table to render Light Table 7 Colorful - Accent 5 style. Specifies the table to render Light Table 7 Colorful - Accent 6 style. Specifies the table to render Table Grid Light style. Specifies the table to render Table Grid style. Represents DataSource for tables Data table Rows count Columns count Data column An array Use sorting data Cached rows Initializes a new instance of the PdfDataSource class Initializes a new instance of the PdfDataSource class using DataTable Data table Initializes a new instance of the PdfDataSource class using DataSet Data set Table name Initializes a new instance of the PdfDataSource class using DataView Data View Initializes a new instance of the PdfDataSource class using DataColumn Data column Initializes a new instance of the PdfDataSource class using array Source array Gets row of data for visible columns The index An array of text values or null indicating reaching the end. Verify is the column read only The index Is current column read only Gets Column Mapping type The index Column mapping type Gets Column Data type The index Column data type Get column default value The index Column default value Gets whether column allow DBNull The index Allow DBNull Gets array base type The array Base type for array Gets columns names Columns names Gets columns captions. Columns captions Verify is the input array valid Array to check Columns count Is array valid Set data Table Data table Handles the RowDeleted event of the dataTable control. The source of the event. The instance containing the event data. Handles the RowChanged event of the dataTable control. The source of the event. The instance containing the event data. Handles the ColumnChanged event of the dataTable control. The source of the event. The instance containing the event data. Refreshes the cache. Gets visible columns count Returns visible columns count Convert input index to real index The index Gets real table index Gets row from array The array The index Returns array of values Gets row from data column The column The index Returns array of values Gets row from table The Data Table The index Returns array of values Gets table form DataSet The DataSet Table name Returns table Gets table from DataView The DataView Returns table True if use data sorting, otherwise false Gets rows counts Gets column count Gets visible columns names Gets visible columns captions Artifacts in the PDF document can be graphic objects or other markings that are not a part of the authored content and will include things such as headers, footers, page numbers, watermarks, cut marks, color bars, background images, lines separating content, or decorative images. //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Represents the tag for the element To know more about refer this link . //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element with tag type heading. PdfStructureElement header = new PdfStructureElement(PdfTagType.Heading); //Initialize new instance of structure element with tag type HeadingLevel1. PdfStructureElement header1 = new PdfStructureElement(PdfTagType.HeadingLevel1); header1.Parent = header; //Initialize new instance of structure element with tag type Paragraph. PdfStructureElement structElement = new PdfStructureElement(PdfTagType.Paragraph); structElement.Parent = header1; //Create PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element with tag type heading. Dim header As PdfStructureElement = New PdfStructureElement(PdfTagType.Heading) 'Initialize new instance of structure element with tag type HeadingLevel1. Dim header1 As PdfStructureElement = New PdfStructureElement(PdfTagType.HeadingLevel1) header1.Parent = header 'Initialize new instance of structure element with tag type Paragraph. Dim structElement As PdfStructureElement = New PdfStructureElement(PdfTagType.Paragraph) structElement.Parent = header1 'Create PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Gets or sets the order for the element To know more about refer this link . //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Initialize the instance of PdfArtifact //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Initialize the instance of PdfArtifact Type of the artifact //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(PdfArtifactType.Layout); //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact(PdfArtifactType.Layout) 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Initialize the instance of PdfArtifact Type of the artifact represents the attachment for artifact //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(PdfArtifactType.Layout,new PdfAttached(PdfEdge.Left)); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact(PdfArtifactType.Layout, New PdfAttached(PdfEdge.Left)) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Initialize the instance of PdfArtifact Type of the artifact attachment for artifact Subtype of the artifact //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(PdfArtifactType.Layout, new PdfAttached(PdfEdge.Left), PdfArtifactSubType.Watermark); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact(PdfArtifactType.Layout, New PdfAttached(PdfEdge.Left), PdfArtifactSubType.Watermark) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Initialize the instance of PdfArtifact Type of the artifact Bounding box of the artifact attachment for the artifact Subtype of the artifact //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(PdfArtifactType.Layout, new RectangleF(0, 0, 100, 100), new PdfAttached(PdfEdge.Left), PdfArtifactSubType.Watermark); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact(PdfArtifactType.Layout, New RectangleF(0, 0, 100, 100), New PdfAttached(PdfEdge.Left), PdfArtifactSubType.Watermark) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Gets or sets the bounding box for the artifact. //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Gets or sets the artifact type //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Gets or sets the subtype of the artifact //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set artifact subtype. artifact.SubType = PdfArtifactSubType.Footer; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set artifact subtype. artifact.SubType = PdfArtifactSubType.Footer 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Gets or sets the attachment for the artifact. //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Represents the type of the artifact Represents the logically attached artifcat on the page. //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Initialize the PdfAttached page edge //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Initialize the PdfAttached edge of the page edge of the page //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left, PdfEdge.Right); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left, PdfEdge.Right) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Initialize the PdfAttached left edge of the page right edge of the page top edge of the page bottom edge of the page //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout; //Set the attachement for the artifact. artifact.Attached = new PdfAttached(PdfEdge.Left, PdfEdge.Right, PdfEdge.Top, PdfEdge.Bottom); //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout 'Set the attachement for the artifact. artifact.Attached = New PdfAttached(PdfEdge.Left, PdfEdge.Right, PdfEdge.Top, PdfEdge.Bottom) 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Class Set edges for the page the page edges //Create new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new page to the document. PdfPage page = document.Pages.Add(); //Create new instance for PDF artifact. PdfArtifact artifact = new PdfArtifact(); //Set the artifact type. artifact.ArtifactType = PdfArtifactType.Layout; PdfEdge[] edges = { PdfEdge.Right, PdfEdge.Top }; //Create new instance for the PDF attached. PdfAttached attached = new PdfAttached(PdfEdge.Left); attached.SetEdge(edges); //Set the attachement for the artifact. artifact.Attached = attached; //Set bounding box for the artifact. artifact.BoundingBox = new RectangleF(0, 0, 100, 100); //Create new instance for the PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); //Set tag for the element. element.PdfTag = artifact; //Create new instance for the PDF font. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Create new instance for the PDF brush. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element on the PDF page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new page to the document. Dim page As PdfPage = document.Pages.Add() 'Create new instance for PDF artifact. Dim artifact As PdfArtifact = New PdfArtifact() 'Set artifact type. artifact.ArtifactType = PdfArtifactType.Layout Dim edges As PdfEdge() = {PdfEdge.Right, PdfEdge.Top} 'Create new instance for the PDF attached. Dim attached As PdfAttached = New PdfAttached(PdfEdge.Left) attached.SetEdge(edges) 'Set the attachement for the artifact. artifact.Attached = attached 'Set the bounding box for the artifact. artifact.BoundingBox = New RectangleF(0, 0, 100, 100) 'Create new instance for the PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") 'Set tag for the element. element.PdfTag = artifact 'Create new instance for the PDF font. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Create new instance for the PDF brush. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element on the PDF page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and close the document. document.Save("Output.pdf") document.Close(True) Gets a value indicating top page edge Gets a value indicating left page edge Gets a value indicating bottom page edge Gets a value indicating right page edge Represents the edges of the page. Indicates the top edge of the page Indicates the bottom edge of the page Indicates the left edge of the page Indicates the right edge of the page. Represents the structure element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element with tag type heading. PdfStructureElement header = new PdfStructureElement(PdfTagType.Heading); //Initialize new instance of structure element with tag type HeadingLevel1. PdfStructureElement header1 = new PdfStructureElement(PdfTagType.HeadingLevel1); header1.Parent = header; //Initialize new instance of structure element with tag type Paragraph. PdfStructureElement structElement = new PdfStructureElement(PdfTagType.Paragraph); structElement.Parent = header1; //Create PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element with tag type heading. Dim header As PdfStructureElement = New PdfStructureElement(PdfTagType.Heading) 'Initialize new instance of structure element with tag type HeadingLevel1. Dim header1 As PdfStructureElement = New PdfStructureElement(PdfTagType.HeadingLevel1) header1.Parent = header 'Initialize new instance of structure element with tag type Paragraph. Dim structElement As PdfStructureElement = New PdfStructureElement(PdfTagType.Paragraph) structElement.Parent = header1 'Create PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Class Initialize the structure element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Initialize the Structure element tag type //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element with tag type heading. PdfStructureElement header = new PdfStructureElement(PdfTagType.Heading); //Initialize new instance of structure element with tag type HeadingLevel1. PdfStructureElement header1 = new PdfStructureElement(PdfTagType.HeadingLevel1); header1.Parent = header; //Initialize new instance of structure element with tag type Paragraph. PdfStructureElement structElement = new PdfStructureElement(PdfTagType.Paragraph); structElement.Parent = header1; //Create PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element with tag type heading. Dim header As PdfStructureElement = New PdfStructureElement(PdfTagType.Heading) 'Initialize new instance of structure element with tag type HeadingLevel1. Dim header1 As PdfStructureElement = New PdfStructureElement(PdfTagType.HeadingLevel1) header1.Parent = header 'Initialize new instance of structure element with tag type Paragraph. Dim structElement As PdfStructureElement = New PdfStructureElement(PdfTagType.Paragraph) structElement.Parent = header1 'Create PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Gets or sets the abbrevation for the structure element. //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the actual text for the structure element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the alternate text for the structure element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the language for all text in the structure element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the language for the structure element structElement.Language = "en-Us"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the language for the structure element. structElement.Language = "en-Us"; 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the logical reading order for the structure element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the parent for the element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element with tag type heading. PdfStructureElement header = new PdfStructureElement(PdfTagType.Heading); //Initialize new instance of structure element with tag type HeadingLevel1. PdfStructureElement header1 = new PdfStructureElement(PdfTagType.HeadingLevel1); header1.Parent = header; //Initialize new instance of structure element with tag type Paragraph. PdfStructureElement structElement = new PdfStructureElement(PdfTagType.Paragraph); structElement.Parent = header1; //Create PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element with tag type heading. Dim header As PdfStructureElement = New PdfStructureElement(PdfTagType.Heading) 'Initialize new instance of structure element with tag type HeadingLevel1. Dim header1 As PdfStructureElement = New PdfStructureElement(PdfTagType.HeadingLevel1) header1.Parent = header 'Initialize new instance of structure element with tag type Paragraph. Dim structElement As PdfStructureElement = New PdfStructureElement(PdfTagType.Paragraph) //Set parent for structure element. structElement.Parent = header1 'Create PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Gets or sets the tag type for the element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //Set the tag type. structElement.TagType = PdfTagType.HeadingLevel1; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'Set the tag type. structElement.TagType = PdfTagType.HeadingLevel1; 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the title for the structure element //Create a new document. PdfDocument document = new PdfDocument(); //Set auto tag value. document.AutoTag = true; //Add new pdf page. PdfPage page = document.Pages.Add(); //Initialize new instance of structure element. PdfStructureElement structElement = new PdfStructureElement(); //set the order for the structure element. structElement.Order = 1; //set the title for the structure element. structElement.Title = "Example Text"; //set the abbrevation for the structure element. structElement.Abbrevation = "TTT"; //set the actual text for the structure element. structElement.ActualText = "Text"; //set the alternate text for the structure element. structElement.AlternateText = "ELement Text"; //set the parent for the structure element. structElement.Parent = new PdfStructureElement(PdfTagType.Heading); //Create new PDF text element. PdfTextElement element = new PdfTextElement(@"Syncfusion Essential studio tool"); element.PdfTag = structElement; //Set font for text element. element.Font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12); //Set brush for text element. element.Brush = new PdfSolidBrush(new PdfColor(89, 89, 93)); //Draw text element into pdf page. element.Draw(page, new RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)); //Save and close the document. document.Save("Output.pdf"); document.Close(true); 'Create a new document. Dim document As PdfDocument = New PdfDocument() 'Set auto tag value. document.AutoTag = True 'Add new pdf page. Dim page As PdfPage = document.Pages.Add() 'Initialize new instance of structure element. Dim structElement As PdfStructureElement = New PdfStructureElement() 'set the order for the structure element. structElement.Order = 1 'set the title for the structure element. structElement.Title = "Example Text" 'set the abbrevation for the structure element. structElement.Abbrevation = "TTT" 'set the actual text for the structure element. structElement.ActualText = "Text" 'set the alternate text for the structure element. structElement.AlternateText = "ELement Text" 'set the parent for the structure element. structElement.Parent = New PdfStructureElement(PdfTagType.Heading) 'Create new PDF text element. Dim element As PdfTextElement = New PdfTextElement("Syncfusion Essential studio tool") element.PdfTag = structElement 'Set font for text element. element.Font = New PdfStandardFont(PdfFontFamily.TimesRoman, 12) 'Set brush for text element. element.Brush = New PdfSolidBrush(New PdfColor(89, 89, 93)) 'Draw text element into pdf page. element.Draw(page, New RectangleF(0, 0, page.Graphics.ClientSize.Width / 2, 200)) 'Save and Close the document. document.Save("Output.pdf") document.Close(True) Class Class Class Gets or sets the scope value //Creates a new PDF document PdfDocument pdfDocument = new PdfDocument(); pdfDocument.DocumentInformation.Title = "Table"; //Adds new page PdfPage pdfPage = pdfDocument.Pages.Add(); //Initialize the new structure element with tag type table PdfStructureElement element = new PdfStructureElement(PdfTagType.Table); //Create a new PdfGrid PdfGrid pdfGrid = new PdfGrid(); //Adding tag to PDF grid pdfGrid.PdfTag = element; //Add three columns pdfGrid.Columns.Add(3); //Add header pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold); pdfGridHeader.Style.TextBrush = PdfBrushes.Brown; //Adding tag for each row with tag type TR pdfGridHeader.PdfTag = new PdfStructureElement(PdfTagType.TableRow); pdfGridHeader.Cells[0].Value = "Employee ID"; //Adding tag for header cell with tag type TH pdfGridHeader.Cells[0].PdfTag = new PdfStructureElement(PdfTagType.TableHeader) { Scope = ScopeType.Both }; pdfGridHeader.Cells[1].Value = "Employee Name"; //Adding tag for header cell with tag type TH pdfGridHeader.Cells[1].PdfTag = new PdfStructureElement(PdfTagType.TableHeader) { Scope = ScopeType.Row}; pdfGridHeader.Cells[2].Value = "Salary"; //Adding tag for header cell with tag type TH pdfGridHeader.Cells[2].PdfTag = new PdfStructureElement(PdfTagType.TableHeader) { Scope = ScopeType.Column }; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.PdfTag = new PdfStructureElement(PdfTagType.TableRow); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Adding tag for each cell with tag type TD pdfGridRow.Cells[0].PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); pdfGridRow.Cells[1].PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); pdfGridRow.Cells[2].PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Draw the PdfGrid pdfGrid.Draw(pdfPage, PointF.Empty); //save the document and dispose it pdfDocument.Save("Output.pdf"); //close the document pdfDocument.Close(true); 'Creates a new PDF document Dim pdfDocument As PdfDocument = New PdfDocument() pdfDocument.DocumentInformation.Title = "Table" 'Adds new page Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Initialize the new structure element with tag type table Dim element As PdfStructureElement = New PdfStructureElement(PdfTagType.Table) 'Create a new PdfGrid Dim pdfGrid As PdfGrid = New PdfGrid() 'Adding tag to PDF grid pdfGrid.PdfTag = element 'Add three columns pdfGrid.Columns.Add(3) 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold) pdfGridHeader.Style.TextBrush = PdfBrushes.Brown 'Adding tag for each row with tag type TR pdfGridHeader.PdfTag = New PdfStructureElement(PdfTagType.TableRow) pdfGridHeader.Cells(0).Value = "Employee ID" 'Adding tag for header cell with tag type TH pdfGridHeader.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableHeader) With {.Scope = ScopeType.Row} pdfGridHeader.Cells(1).Value = "Employee Name" 'Adding tag for header cell with tag type TH pdfGridHeader.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableHeader) With {.Scope = ScopeType.Column} pdfGridHeader.Cells(2).Value = "Salary" 'Adding tag for header cell with tag type TH pdfGridHeader.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableHeader) With {.Scope = ScopeType.Both} 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.PdfTag = New PdfStructureElement(PdfTagType.TableRow) pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Adding tag for each cell with tag type TD pdfGridRow.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) pdfGridRow.Cells(1).PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) pdfGridRow.Cells(2).PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Draw the PdfGrid pdfGrid.Draw(pdfPage, PointF.Empty) 'save the document and dispose it pdfDocument.Save("Output.pdf") pdfDocument.Close(True) Represents the subtype of the artifact Represents the subtype of the artifact as header Represents the subtype of the artifact as footer Represents the subtype of the artifact as watermark Represents the subtype of the artifact as none Represents the tag type Represents the tag type as Annotation Represents the tag type as Article Represents the tag type as BibliographyEntry Represents the tag type as BlockQuotation Represents the tag type as Caption Represents the tag type as Code Represents the tag type as Division Represents the tag type as Document Represents the tag type as Figure Represents the tag type as Form Represents the tag type as Formula Represents the tag type as Heading Represents the tag type as HeadingLevel1 Represents the tag type as HeadingLevel2 Represents the tag type as HeadingLevel3 Represents the tag type as HeadingLevel4 Represents the tag type as HeadingLevel5 Represents the tag type as HeadingLevel6 Represents the tag type as Index Represents the tag type as Label Represents the tag type as Link Represents the tag type as List Represents the tag type as ListBody Represents the tag type as ListItem Represents the tag type as Note Represents the tag type as Paragraph Represents the tag type as Part Represents the tag type as Private Represents the tag type as Quotation Represents the tag type as Reference Represents the tag type as Ruby Represents the tag type as Section Represents the tag type as Span Represents the tag type as Table Represents the tag type as TableBodyRowGroup Represents the tag type as TableDataCell Represents the tag type as TableFooterRowGroup Represents the tag type as TableHeader Represents the tag type as TableHeaderRowGroup Represents the tag type as TableOfContent Represents the tag type as TableOfContentItem Represents the tag type as TableRow Represents the tag type as Warichu Represents the tag type as None Represents the tag type //Creates a new PDF document PdfDocument pdfDocument = new PdfDocument(); pdfDocument.DocumentInformation.Title = "Table"; //Adds new page PdfPage pdfPage = pdfDocument.Pages.Add(); //Initialize the new structure element with tag type table PdfStructureElement element = new PdfStructureElement(PdfTagType.Table); //Create a new PdfGrid PdfGrid pdfGrid = new PdfGrid(); //Adding tag to PDF grid pdfGrid.PdfTag = element; //Add three columns pdfGrid.Columns.Add(3); //Add header pdfGrid.Headers.Add(1); PdfGridRow pdfGridHeader = pdfGrid.Headers[0]; pdfGridHeader.Style.Font = new PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold); pdfGridHeader.Style.TextBrush = PdfBrushes.Brown; //Adding tag for each row with tag type TR pdfGridHeader.PdfTag = new PdfStructureElement(PdfTagType.TableRow); pdfGridHeader.Cells[0].Value = "Employee ID"; //Adding tag for header cell with tag type TH pdfGridHeader.Cells[0].PdfTag = new PdfStructureElement(PdfTagType.TableHeader) { Scope = ScopeType.Both }; pdfGridHeader.Cells[1].Value = "Employee Name"; //Adding tag for header cell with tag type TH pdfGridHeader.Cells[1].PdfTag = new PdfStructureElement(PdfTagType.TableHeader) { Scope = ScopeType.Row}; pdfGridHeader.Cells[2].Value = "Salary"; //Adding tag for header cell with tag type TH pdfGridHeader.Cells[2].PdfTag = new PdfStructureElement(PdfTagType.TableHeader) { Scope = ScopeType.Column }; //Add rows. PdfGridRow pdfGridRow = pdfGrid.Rows.Add(); pdfGridRow.PdfTag = new PdfStructureElement(PdfTagType.TableRow); pdfGridRow.Cells[0].Value = "E01"; pdfGridRow.Cells[1].Value = "Clay"; pdfGridRow.Cells[2].Value = "$10,000"; //Adding tag for each cell with tag type TD pdfGridRow.Cells[0].PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); pdfGridRow.Cells[1].PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); pdfGridRow.Cells[2].PdfTag = new PdfStructureElement(PdfTagType.TableDataCell); //Draw the PdfGrid pdfGrid.Draw(pdfPage, PointF.Empty); //save the document and dispose it pdfDocument.Save("Output.pdf"); //close the document pdfDocument.Close(true); 'Creates a new PDF document Dim pdfDocument As PdfDocument = New PdfDocument() pdfDocument.DocumentInformation.Title = "Table" 'Adds new page Dim pdfPage As PdfPage = pdfDocument.Pages.Add() 'Initialize the new structure element with tag type table Dim element As PdfStructureElement = New PdfStructureElement(PdfTagType.Table) 'Create a new PdfGrid Dim pdfGrid As PdfGrid = New PdfGrid() 'Adding tag to PDF grid pdfGrid.PdfTag = element 'Add three columns pdfGrid.Columns.Add(3) 'Add header. pdfGrid.Headers.Add(1) Dim pdfGridHeader As PdfGridRow = pdfGrid.Headers(0) pdfGridHeader.Style.Font = New PdfStandardFont(PdfFontFamily.Helvetica, 12, PdfFontStyle.Bold) pdfGridHeader.Style.TextBrush = PdfBrushes.Brown 'Adding tag for each row with tag type TR pdfGridHeader.PdfTag = New PdfStructureElement(PdfTagType.TableRow) pdfGridHeader.Cells(0).Value = "Employee ID" 'Adding tag for header cell with tag type TH pdfGridHeader.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableHeader) With {.Scope = ScopeType.Row} pdfGridHeader.Cells(1).Value = "Employee Name" 'Adding tag for header cell with tag type TH pdfGridHeader.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableHeader) With {.Scope = ScopeType.Column} pdfGridHeader.Cells(2).Value = "Salary" 'Adding tag for header cell with tag type TH pdfGridHeader.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableHeader) With {.Scope = ScopeType.Both} 'Add rows. Dim pdfGridRow As PdfGridRow = pdfGrid.Rows.Add() pdfGridRow.PdfTag = New PdfStructureElement(PdfTagType.TableRow) pdfGridRow.Cells(0).Value = "E01" pdfGridRow.Cells(1).Value = "Clay" pdfGridRow.Cells(2).Value = "$10,000" 'Adding tag for each cell with tag type TD pdfGridRow.Cells(0).PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) pdfGridRow.Cells(1).PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) pdfGridRow.Cells(2).PdfTag = New PdfStructureElement(PdfTagType.TableDataCell) 'Draw the PdfGrid pdfGrid.Draw(pdfPage, PointF.Empty) 'save the document and dispose it pdfDocument.Save("Output.pdf") pdfDocument.Close(True) Represents the Scope type as Row Represents the Scope type as Column Represents the Scope type as Both Represents the Scope type as None Local variable to store the whitepoint value of CalGray colorspace. Local variable to store the blackpoint value of CalGray colorspace. Local variable to store the gamma value of CalGray colorspace. Gets the number of components for the CalGray Colorspace. Gets or sets the Whitepoint value for the CalGray Colorspace. Gets or sets the Blackpoint value for the CalGray Colorspace. Gets or sets the Gamma value for the CalGray Colorspace. Local variable to store the whitepoint value of CalRgb colorspace. Local variable to store the blackpoint value of CalRgb colorspace. Local variable to store the gamma value of CalRgb colorspace. Local variable to store the matrix value of CalRgb colorspace. Gets the number of components for the CalRgb Colorspace. Gets or sets the Whitepoint value for the CalRgb Colorspace. Gets or sets the Blackpoint value for the CalRgb Colorspace. Gets or sets the Gamma value for the CalRgb Colorspace. Gets or sets the Matrix value for the CalRgb Colorspace. Gets the number of components for the DeviceCMYK Colorspace. Gets the number of components for the DeviceGray Colorspace. Local variable to store the AlternateColorspace value of DeviceN colorspace. Local variable to store the function value of DeviceN colorspace. Set the Colorspace value to local variable from Pdfarray ColorspaceArray Get the Colorspace value from Pdfarray ColorspaceArray Colorspace Gets the number of components for the DeviceN Colorspace. Gets or set the AlternateColorspace value for DeviceN colorspace Gets or set the Function value for DeviceN colorspace Gets the number of components for the DeviceRgb Colorspace. Local variable to store the IccProfile value of ICCBased colorspace. Gets or sets the IccProfile value for the ICCBased Colorspace. Gets the Components for the IccBased Alternate Colorspace. Local variable to store the N value of IccProfile. Local variable to store the alternate colorspace. Local variable to store the IccProfile value of IccBased colorspace. Local variable to store the matrix value of CalRgb colorspace. Gets the Alternate colorspace of IccBased colorspace. Gets or sets the N value for the ICCBased Colorspace. Local variable to store the BaseColorspace value of Indexed colorspace. Local variable to store the Maximum valid index value of Indexed colorspace. Local variable to store the Lookup parameter value of Indexed colorspace. Get the color value of Indexed colorspace Index value for color Color Set the Indexed colorspace data to local variable Index value Array Get the Color Color component Color Get the Base colorspace of Indexed color space Index value Array Colorspace Get the Lookup data of Indexed colorspace Index value Array Get the colorspace of Base colorspace Colorspace Get the Decoded stream of Type0 data Type0 stream Decoded Byte Decode the FlateDecode stream Type0 encoded stream Memory stream Gets the number of components for the Indexed Colorspace. Gets the DefaultBrush value for the Indexed BaseColorspace. Gets or sets the BaseColorspace value for the Indexed Colorspace. Gets or sets the Maximum valid index value for the Indexed Colorspace. Gets or sets the Lookup parameter value for the Indexed Colorspace. Local variable to store the whitepoint value of Labcolorspace. Local variable to store the blackpoint value of Labcolorspace. Local variable to store the range value of Labcolorspace. Gets the number of components for the Labcolorspace. Gets or sets the Whitepoint value for the Labcolorspace. Gets or sets the Blackpoint value for the Labcolorspace. Gets or sets the Range value for the Labcolorspace. Local variable to store the Lookup Data of Indexed colorspace Load the Lookup stream data of Indexed color space Lookup stream data Load the Lookup byte string data of Indexed colorspace Byte string Load the Lookup data reference of Indexed color space Reference of Lookup data Gets the Lookup Data of Indexed colorspace Local variable to store the PatternType value of Pattern colorspace. Local variable to store the AlternateColorspace value of Pattern colorspace. Local variable to store the PatternMatrix value of Pattern colorspace. Local variable to store the Pattern value of Pattern colorspace. Gets or sets the AlternateColorspace value for the Pattern Colorspace. Gets or sets the PatternMatrix value for the Pattern Colorspace. Gets or sets the PatternType value for the Pattern Colorspace. Local variable to store the Alternate colorspace value of Seperation colorspace. Local variable to store the Function value of Seperation colorspace founction. Get the color value from string value string Array Color Convert the string array to double array string Array Double array Get the color value from bytes string Array Offset Value Color Set the Seperation colorspace data to local variable seperation value Array Get the Seperation colorspace Alternate colorspace from array value seperation value Array Alternate colorspace Gets the number of components for the Seperation Colorspace. Gets or sets the Alternate colorspace value for the Seperation Colorspace. Gets or sets the Function value for the Seperation Colorspace. Contains definition for sorting the enumerator in ascending order Type of return value Delegate Used to compare two object If it is set to true, enumerator is sorted in descending order other it is sorted in ascending order Gets or sets the embeded font family. Gets the updated font size from text matrix. Exports the specified page as Image The page pageIndex to be converted into image Returns the specified page as Image Exports the specified page as Metafile The page to be converted into image Metafile Exports the specified page as Image with respect to dpi specified. The PdfPageBase to be converted into image The horizontal DPI of the resultant image. The vertical DPI of the resultant image. Returns the specified page as Image with custom resolution Exports the specified page as Image The page pageIndex to be converted into image The custom size of the converted image Whether need to keep the aspect ratio of the page Returns the image with custom size Exports the specified pages as Image The PdfPageBase to be converted into image The custom size of the converted image The horizontal DPI of the resultant image. The vertical DPI of the resultant image. Whether need to maintain the pdf page size Returns the specified pages as images with custom size and resolution Returns the capured terms found in the given page index The Specified pageindex. List of items to be searched Search results Returns true if any matches found Returns the page number and capured terms found in the page List of terms to be searched Search results Returns true if any matches found Returns the page number and capured terms found in the page List of terms to be searched Search results Returns true if any matches found Executes each of the provided actions, possibly in parallel. An array of System.Action to execute. Searches the text at a page Index of the page Text to be searched Matching texts Returns the matching texts Returns the page number and rectangle postions of the text matchs found in the page The text to be searched Holds the page number and rectangle positions of the text matches Returns the rectangle positions of the text matches The text which is to be searched Returns the rectangle postions of the text matches The text which is to be searched Represents a text search item Initialises a new instance of TextSearchItem Defines the constants that specify the option for text search. searches words with no options. searches whole words only but not case sensitive. Searches words with case sensitive. Brush to stroke the text Bounds of the text Gets or sets a value of the StrokingColorspace Gets or sets a value of the NonStrokingColorspace Gets or sets a value of the StrokingBrush Gets or sets a value of the NonStrokingBrush Set the Stroking colorspace of current graphics state current colorspace value Set the Non Stroking colorspace of current graphics state current colorspace value Set the Non Stroking RGB color of current graphics state brush color value of RGB Set the Non Stroking CMYK color of current graphics state brush color value of CMYK Set the Non Stroking Gray color of current graphics state brush color value of Gray Set the Stroking RGB color of current graphics state brush color value of RGB Set the Stroking CMYK color of current graphics state brush color value of CMYK Set the Stroking Gray color of current graphics state brush color value of Gray Set the Stroking of current graphics state brush color value Set the Non Stroking of current graphics state brush color value Determining valid email address email address to validate true is valid, false if not valid Calculates the height of text. Cleared the collections Gets or sets the value that indicating the extracting of text data. TODO: Can we use PdfMargins class instead of this ? Renders the Text to the panel graphics element location in which the graphics is to be drawn Renders the Text to the panel graphics element location in which the graphics is to be drawn Removes the escape sequence characters in the given text text with the escape sequence Text without escape sequence Gets or sets the value that indicating the extracting of text data. The searched text. the color of the text page Number Rectangle bounds of the searched text. Parse the annotation properties within a page Annotation properties The specific page in which annotations needs to be added Zoom factor need to be considered while drawing the annotation rectangle Calculates the annotation rectangle according to the zoom values. The specific page in which annotations needs to be added Represents the annotation rectangle Include the URL annotation rectangles with the specific page properties The specific page in which annotations needs to be added Represents the annotation properties such as rectangle,location and URI Include the text rectangles with the specific page properties The specific page in which text search needs to be performed Represents the annotation properties such as rectangle,location and URI Calculates the annotation rectangle according to the zoom values. The specific page in which annotations needs to be added Represents the annotation rectangle Zoom factor need to be considered Drawing panel is true or false is need to be considered Searches the text at a page Index of the page Text to be searched Matching texts Returns the matching texts Represents the annotation with associated within a page. Represents the URLS within a page. Represents the URLS within a page. Represents the Rectangle position of the matching text. Local variable to store the Domain value of Function Local variable to store the Range value of Function Local variable to store the dictionary of Function Create the function type from dictionary Array Function Color transfer function Input color component value Double array Extract the Input Data Input data Double array Extract the Output Data Output data Double array Perform Interpolate function result Clip the Data result Gets or sets the Domain value of Function. Gets or sets the Range value of Function. Local variable to store the BitsPerSample of Type0 Local variable to store the Order of Type0 Local variable to store the Size of Type0 Local variable to store the Encode value of Type0 Local variable to store the Decode value of Type0 Local variable to store the sample value of Type0 Local variable to store the Output value count of Type0 Local variable to store the Filter of Type0 Data Load the Type0 function stream to local variable Type0 Data Execute the Type0 function Input Data Color values Encode the input data of Type0 EncodedData Decode the input data of Type0 DecodedData Get the index of data Data Index Get the Decoded stream of Type0 data Type0 stream Decoded Byte Decode the FlateDecode stream Type0 encoded stream Memory stream Gets or sets the BitsPerSample value of Type0 function. Gets or sets the Filter value of Type0 function. Gets or sets the Order value of Type0 function. Gets or sets the Decode value of Type0 function. Gets or sets the Encode value of Type0 function. Gets or sets the Size value of Type0 function. Local variable to store the C0 value of Type2 function Local variable to store the C1 value of Type2 function Local variable to store the N value of Type2 function Local variable to store the Functions resources value of Type2 function Perform the Type0 function Input Data Color values Perform the Type0 function of Single input data Single input data outputData Perform the ExponentialInterpolation function value value value result Gets or sets the Function resource value of Type2 function. Gets or sets the C0 value of Type2 function. Gets or sets the C1 value of Type2 function. Gets or sets the N value of Type2 function. Gets the output element length Local variable to store the Encode value of Type3 function Local variable to store the Bounds value of Type3 function Local variable to store the Functions value of Type3 function Perform the Type4 function Input Data Color values Gets or sets the Encode value of Type3 function. Gets or sets the Bounds value of Type3 function. Gets or sets the Function value of Type4 function. Local variable to store the Post Script Stream Local variable to store the Filter type of Post Script Stack pointer List of Post Script Operator Stack value of Post Script Data Operator type array of Post Script Operator Current operator type value Load the Type4 function stream to local variable Type4 Data Get the Decoded stream of Type4 function Type0 Data Perform the Type4 function Input Data Color values Decodes the ASCII85 encoded stream Encoded stream Decoded Stream Gets the output element value length Gets or sets the Filter value of Type4 function stream. Class which represents the collection of text search result. Represents Basic Job Ticket Schema. Represents Xmp Schema. Base class for the xmp entities. Parent node for this entity. Prefix of the entity namespace. Local name of the entity. Uri of the namespace. Initializes a new instance of the class. The parent. The prefix. Name of the local. The namespace URI. Initializes object. Checks whether entity already exists in the parent. True - if exists, False otherwise. Gets value indicating whether we have to suspend initialization. Value indicating whether we have to suspend initialization. Creates entity in the parent. Gets Xml data of the entity. XmlElement containing entity data. Changes parent of the entity. New Xml parent. Gets Xml data of the entity. Gets a value indicating whether this is exists. true if exists; otherwise, false. Gets parent xml node for the entity. Gets namespace prefix of the entity. Gets name of the entity's tag. Gets URI of the entity's namespace. Gets a value indicating whether [suspend initialization]. Name of the schema tag. Xpath to the Description element. Parent XmpMetadata. Hashtable of the properties. Creates new object. Parent XmpMetadata. Creates schema xml. Gets Xml data of the entity. XmlElement containing entity data. Creates simple property. Name of the property. Simple property instance. Gets property by its name. Name of the property. Xmp property instance. Remove simple propertity through key value. Creates xmp array. Name of the array. Type of the array. Created xmp array. Gets xmp array. Name of the array. Type of the array. Xmp array. Creates xmp lang array. Name of the array. Created xmp array. Gets xmp lang array. Name of the array. Xmp array. Gets the structure. The name. The type. Creates the structure. The name. The type. Structure object. Creates the structure. The type of the structure. Structure object. Gets type of the schema. Gets schema prefix. Gets name (URI) of the schema. Gets parent XmpMetadata. Prefix of the schema. Nasme of the schema. Name of the property. Creates schema object. Parent XmpMetadata. Gets type of the Schema. Gets name pf the schema. Gets prefix of the schema. Gets references an external job management file for a job process in which the document is being used. Use of job names is under user control. Typical use would be to identify all documents that are part of a particular job or contract. Represents Basic Schema. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Creates schema object. Parent XmpMetadata. Gets type of the Schema. Gets name pf the schema. Gets prefix of the schema. Gets an unordered array specifying properties that were edited outside the authoring application. Gets an unordered array of text strings that unambiguously identify the resource within a given context. An array item may be qualified with xmpidq:Scheme to denote the formal identification system to which that identifier conforms. Gets or sets a word or short phrase that identifies a document as a member of a user-defined collection. Used to organize documents in a file browser. Gets or sets a short informal name for the resource. Gets or sets The base URL for relative URLs in the document content. If this document contains Internet links, and those links are relative, they are relative to this base URL. Gets or sets The name of the first known tool used to create the resource. If history is present in the metadata, this value should be equivalent to that of xmpMM:History�s softwareAgent property. Gets or sets the date and time the resource was originally created. Gets or sets the date and time that any metadata for this resource was last changed. It should be the same as or more recent than xmp:ModifyDate. Gets sets the date and time the resource was last modified. Gets an alternative array of thumbnail images for a file, which can differ in characteristics such as size or image encoding. Gets a number that indicates a document�s status relative to other documents, used to organize documents in a file browser. Values are user-defined within an application defined range. Represents custom Schema. Gets the boolen result key value at present or not Initializes a new instance of the class. Parent XmpMetadata. The XML namespace. The namespace URI. Gets Xml data of the entity. XmlElement containing entity data. To remove custom object both XMP and customschema To get custom prefix xml node from loaded PDF XMP To set the loaded custom prefix XMP to current XMP Sets the xmp property. Gets CustomSchema dictionary Gets type of the schema. Gets schema prefix. Gets name (URI) of the schema. Represents Dublin Core Schema. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Mime-Type of the document. Creates schema object. Parent XmpMetadata. Initializes object. Gets type of the Schema. Gets name pf the schema. Gets prefix of the schema. Gets contributors to the resource (other than the authors). Gets or sets the extent or scope of the resource. Gets the authors of the resource (listed in order of precedence, if significant). Gets date(s) that something interesting happened to the resource. Gets or sets a textual description of the content of the resource. Multiple values may be present for different languages. Gets or sets the unique identifier of the resource. Gets publishers. Gets relationships to other documents. Gets informal rights statement, selected by language. Gets or sets the unique identifier of the work from which this resource was derived. Gets or sets an unordered array of descriptive phrases or keywords that specify the topic of the content of the resource. Gets the title of the document, or the name given to the resource. Typically, it will be a name by which the resource is formally known. Gets a document type; for example, novel, poem, or working paper. Represents Paged Text Schema. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Creates schema object. Parent XmpMetadata. Gets type of the Schema. Gets name pf the schema. Gets prefix of the schema. Gets the size of the largest page in the document (including any in contained documents). Gets or sets the number of pages in the document (including any in contained documents). Gets an unordered array of fonts that are used in the document (including any in contained documents). Gets an unordered array of fonts that are used in the document (including any in contained documents). Gets an ordered array of colorants (swatches) that are used in the document (including any in contained documents). This schema specifies properties used with Adobe PDF documents. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Creates schema object. Parent XmpMetadata. Gets type of the Schema. Gets name pf the schema. Gets prefix of the schema. Gets or sets keywords of the document. Gets or sets the PDF file version (for example: 1.0, 1.3, and so on). Gets or sets the name of the tool that created the PDF document. Represents Rights Management Schema. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Creates schema object. Parent XmpMetadata. Gets type of the Schema. Gets name pf the schema. Gets prefix of the schema. Gets or sets online rights management certificate. Gets or sets indicates that this is a rights-managed resource. Gets an unordered array specifying the legal owner(s)of a resource. Gets text instructions on how a resource can be legally used. Gets or sets the location of a web page describing the owner and/or rights statement for this resource. coloring Structure. Represents Xmp Structure. Base class for the Xmp types. Parent Xmpmetadata. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Gets Xml data of the entity. XmlElement containing entity data. Creates entity in the parent. Gets parent XmpMetadata. Hashtable of the properties. Indicates whether structure is inside of the array or not. Indicates whether we have to suspend initialization. Indicate swhether structure is initialized. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. if it is inside an array, set to true. Creates structure. Gets Xml data of the entity. XmlElement containing entity data. Gets value indicating whether we have to suspend initialization. Value indicating whether we have to suspend initialization. Checks whether entity already exists in the parent. True - if exists, False otherwise. Initializes internal entries. Creates simple property. Name of the property. Simple property instance. Gets property by its name. Name of the property. Xmp property instance. Creates simple property. Name of the property. Parent XmlNode. Simple property instance. Gets property by its name. Name of the property. Parent XmlNode. Xmp property instance. Creates xmp array. Name of the array. Type of the array. Created xmp array. Gets xmp array. Name of the array. Type of the array. Xmp array. Creates structure inner content. Gets Xml element of the description tag. Xml data. Gets parent of the structure content. Parent of the structure content. Gets inner xml data. Gets prefix of the structure. Gets name pf the structure. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Indicates whether structure is inside of the array. Initializes. Gets prefix of the structure. Gets name pf the structure. Gets or sets yellow value when the mode is CMYK. Range 0-100. Gets or sets B value when the mode is LAB. Range -128 to 127. Gets or sets A value when the mode is LAB. Range -128 to 127. Gets or sets L value when the mode is LAB. Range 0-100. Gets or sets blue value when the mode is RGB. Range 0-255. Gets or sets green value when the mode is RGB. Range 0-255. Gets or sets red value when the mode is RGB. Range 0-255. Gets or sets black value when the mode is CMYK. Range 0-100. Gets or sets magenta value when the mode is CMYK. Range 0-100. Gets or sets Cyan value when the mode is CMYK. Range 0-100. Gets or sets the type of color, one of PROCESS or SPOT. Gets or sets the color space in which the color is defined. One of: CMYK, RGB, LAB. Library colors are represented in the color space for which they are defined. Gets or sets name of the swatch. Dimensions structure. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Indicates whether structure is inside of the array. Initializes. Gets or sets Width. Gets or sets height. Gets or sets units. For example: inch, mm, pixel, pica, point. Gets prefix of the structure Gets name pf the structure. Font Structure. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Name of the property. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Indicates whether structure is inside of the array. Initializes structure. Gets prefix of the structure Gets name pf the structure. Gets or sets the name of the font. The name of the font. Gets or sets the font family. The font family. Gets or sets the font face name. The font face. Gets or sets the type of the font. The type of the font. Gets or sets the version string. The version string. Gets or sets a value indicating whether this is composite. true if composite; otherwise, false. Gets or sets the name of the font file. The name of the font file. Gets the list of file names for the fonts that make up a composite font. Declares Job structure. Prefix of the structure. Name of the structure. Name of the property. Name of the property. Name of the property. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Indicates whether structure is inside of the array. Initializes. Gets or sets informal name of job. This name is for user display and informal systems. Gets or sets unique ID for the job. This field is a reference into some external job management system.. Gets or sets a file URL referencing an external job management file. Gets prefix of the structure Gets name pf the structure. Xmp Thumbnail Structure. Prefix of the schema. Nasme of the schema. Name of the property. Name of the property. Name of the property. Name of the property. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Indicates whether structure is inside of the array. Initializes. Gets prefix of the structure. Gets name pf the structure. Gets or sets the height. The height. Gets or sets the width. The width. Gets or sets the format. The format. Gets or sets the thumbnail image (pixel data only) converted to base 64 notation. The image. The Syncfusion.Pdf.Xmp namespace contains classes to create, process metadata for documents. Represents Xmp array. Base class for the arrays. Name of the array item tag. Initializes a new instance of the class. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Creates entity in the parent. Gets list of the array items. List of the array items. Gets prefix of the array depending on the array type. prefix Gets count of the items in the collection. Count of the items in the collection. Gets count of the items in the collection. Gets type of the collection. Gets items container element. Default date format. Type of the array. Initializes a new instance of the class. The XMP. The parent. The prefix. Name of the local. The namespace URI. The type. Adds string value to the array. Value to be added to the array. Adds integer value to the array. Value to be added to the array. Adds float value to the array. Value to be added to the array. Adds Date to the array. Value to be added to the array. Adds Date to the array. Value to be added to the array. String format of the date. Adds an XMP structure. The structure. Creates array item element. XmlElement of the array item. Returns array of the array values. Array of the array values. Changes parent of the entity. New entity parent. Xmp entity. Gets array of the array values. Gets type of the array. Represents Xmp Alt Lang array. Default language name. Language attribute. Creates new object. Parent XmpMetadata. Parent XmlElement of the array. Prefix of the array. Name of the tag. Namespace URI. Adds item to the array. Language code. Text value. Creates entity in the parent. Creates array item element. Language code. XmlElement of the array item. Searches for a item with the specified language. Language name. Item with the specified language. Gets or sets the default text. The default text. Gets or sets the with the specified lang. value Gets type of the lang array. Represents XMP metadata of the document. Xpath for the RDF element. Namespace unique resource identifier for the xmlns attribute. Namespace uri for the xml namespace. Prefix of the PDF namespace. Uri of the Custom Schema namespace Extensible Markup Language Namespace prefix. Xml prefix. Uri of the Resource Description Framework namespace. Start packet. Namespace of the xmpmeta tag. End packet. Uri of the Resource Description Framework PDF/A namespace. Uri of the Extensible Authoring Publishing namespace. Uri of the Adobe PDF schema namespace. Uri of the Dublin Core schema namespace. XmlDocument containing xmp data. Namespace manager. Dublin Core Schema. Dublin Core Schema. Basic Job Ticket Schema. Basic Schema. Rights Management Schema. Indicates PDFSchema. Custom Schema PdfStream container. Initializes a new instance of the class. Initializes a new instance of the class. The XMP. Loads XMP from the XML. XMP data in XMLDocument. If there was any data in this XMP, it will be replaced by the data from the XML. Adds schema to the XMP in XML format. XMP schema in XML format. If XMP already contains such schema - there will be two equal schemas at the xmp. Initializes a packet of the XMP. Initializes stream. Creates packet element. Creates xmpmeta element. Creates Resource Description Framework element. Creates a Dublin core containers. Creates packet element. Resets current xmp metadata. Imports all namespaces to the namespace manager. Current element. Namespace Manager. Creates element. Name of the element. Created element. Creates attribute. Name of the attribute. Value of the attribute. Created XmlAttribute. Creates element. Prefix of the element. Local name of the element. Namespace URI. Created element. Creates attribute. Prefix of the attribute. Name of the attribute. Namespace Uri. Value of the attribute. Created XmlAttribute. Adds namespace. Namespace prefix. Namespace Uri. Uri of the namespace. Raises before stream saves. Sender of the event. Event data. Raises after stream saves. Sender of the event. Event data. Gets XMP data in XML format. Gets XMP stream. Gets namespace manager of the Xmp metadata. Gets Dublin Core Schema. Gets Dublin Core Schema. Gets Basic Job Ticket Schema. Gets Basic Schema. Gets Rights Management Schema. Gets a schema specifying properties used with Adobe PDF documents. Gets Custom Schmea Gets xmpmeta element of the packet. Gets RDF element of the packet. Gets the element. Represents simple Xmp type. Creates xmp simple type instance. Parent XmpMetadata. Parent xml node. Namespace prefix. Name of the tag. Namespace URI. Sets bool value to the object. Bool value. Gets boolean value. Boolean value. Sets real value to the object. Real value. Gets real value. Real value. Sets int value to the object. Int value. Gets int value. Int value. Sets unique resource identifier value to the object. Uri value. Gets unique resource identifier value. Uri value. Sets DateTime value to the object. DateTime value. Gets DateTime value. DateTime value. Creates entity in the parent. Gets or sets value of the instance. Utility class. False string. True string. Real pattern. Default date format. Private constructor. Sets text value to the element. Parent element. Value data. Sets text value to the element. Parent element. Value data. Retrieves boolean value from the string. String representation of the boolean value. Boolean value from the string. Sets text value to the element. Parent element. Value data. Retrieves float value from the string. String representation of the float value. Float value from the string. Sets text value to the element. Parent element. Value data. Retrieves float value from the string. String representation of the float value. Int value from the string. Sets unique resource identifier value to the element. Parent element. Value data. Retrieves float value from the string. String representation of the float value. Uri value from the string. Sets DateTime value to the element. Parent element. Value data. Retrieves float value from the string. String representation of the float value. Uri value from the string. Sets an XML value. The parent. The child. Removes all childrens from the Node element. Enumerates types of the xmp structure. A structure containing dimensions for a drawn object. A structure containing the characteristics of a font used in a document. A structure containing the characteristics of a Coloring (swatch) used in a document. A thumbnail image for a file. Job structure. Enumerates types of the xmp schema. Dublin Core Schema. Basic Schema. Rights Management Schema. Basic Job Ticket Schema. Paged Text Schema. Adobe PDF Schema. Custom schema. Types of the xmp arrays. Unknown array type. Unordered array. Ordered array. Alternative array. Reads the Name of the element XPS data Reader position Name Reads the boolean value from the Data XPS data Reader position True if the next value is boolean Reads the float from the data. XPS data Reader position float value Reads the point from the data XPS data Reader position point Reads the matrix from the data XPS data Reader position Matrix Represents the XPS Document reader Initializes the new instance of the XPS Document reader Path to the XPS document Initializes a new instance of the XPS document reader Stream containing the XPS document content Reads the FixedDocumentSequence Reads the FixedDocumentSequence Reads the fixed documents Reads the image Image element Image stream Reads the fixed pages. Reads the elements from the fixed page. pattern of the element XPSElement type XPS Element Reads the XPS element Element name Element type XPS element Reads the XPS element Element name XPS element Gets the safe name Element name Safe name Search for a XPS element Name of the element Index of the element Search for a XPS element. Name of the element Index to start search Index of the element Search for a XPS element. Regex of element Index to start search Index of the element Reads the font with the URI Font URI Font Name Gets the Font style Font URI Font style Extract the font Font Stream Created font Font Guid Reads the resources in the XPS document resource name Resource Dispose the document Gets the FixedDocumentSequence Gets the Fixed documents Gets the fixed pages Gets the font names Enumerator representing the available XPS elements. Represents the path data reader. Initializes a new instance of the PathDataReader class. Reads the symbols Symbol Gets the next symbol Symbol Updates the current position of the reader Length of the path data Reads the float value from the path data float value True if the next value is float Reads the pint form the path data Point value True if the next parameter is point Reads the position array from the path data position array True if the next parameter is position array Reads the points from the path data Points Checks if the current character is symbol True if the character is a symbol Gets a value indicating whether this is EOF. true if EOF; otherwise, false. Gets text length. Gets or sets the position. The position. Represents the path data reader. Initializes a new instance of the PathDataReader class. Reads the symbols Symbol Gets the next symbol Symbol Updates the current position of the reader Length of the path data Reads the float value from the path data float value True if the next value is float Reads the pint form the path data Point value True if the next parameter is point Reads the position array from the path data position array True if the next parameter is position array Reads the points from the path data Points Checks if the current character is symbol True if the character is a symbol Gets a value indicating whether this is EOF. true if EOF; otherwise, false. Gets text length. Gets or sets the position. The position. Reads the Name of the element XPS data Reader position Name Reads the boolean value from the Data XPS data Reader position True if the next value is boolean Reads the float from the data. XPS data Reader position float value Reads the point from the data XPS data Reader position point Reads the matrix from the data XPS data Reader position Matrix Represents the XPS Document reader Initializes the new instance of the XPS Document reader Path to the XPS document Initializes a new instance of the XPS document reader Stream containing the XPS document content Reads the FixedDocumentSequence Reads the FixedDocumentSequence Reads the fixed documents Reads the image Image element Image stream Reads the fixed pages. Reads the elements from the fixed page. pattern of the element XPSElement type XPS Element Reads the XPS element Element name Element type XPS element Reads the XPS element Element name XPS element Gets the safe name Element name Safe name Search for a XPS element Name of the element Index of the element Search for a XPS element. Name of the element Index to start search Index of the element Search for a XPS element. Regex of element Index to start search Index of the element Reads the font with the URI Font URI Font Name Gets the Font style Font URI Font style Extract the font Font Stream Created font Font Guid Reads the resources in the XPS document resource name Resource Dispose the document Gets the FixedDocumentSequence Gets the Fixed documents Gets the fixed pages Gets the font names Enumerator representing the available XPS elements. Represents XPS element type as Canvas Represents XPS element type as MatrixTransform Represents XPS element type as SolidColorBrush Represents XPS element type as ImageBrush Represents XPS element type as Transform Represents XPS element type as VisualBrush Represents XPS element type as Visual Represents XPS element type as Resources Represents XPS element type as ResourceDictionary Represents XPS element type as Glyphs Represents XPS element type as Geometry Represents XPS element type as PathGeometry Represents XPS element type as PathFigure Represents XPS element type as ArcSegment Represents XPS element type as PolyBezierSegment Represents XPS element type as PolyLineSegment Represents XPS element type as PolyQuadraticBezierSegment Represents XPS element type as Brush Represents XPS element type as LinearGradientBrush Represents XPS element type as GradientStop Represents XPS element type as RadialGradientBrush Represents XPS element type as Path Represents XPS element type as FixedPage Represents XPS element type as FixedDocument Represents XPS element type as PageContent Represents XPS element type as LinkTarget Represents XPS element type as FixedDocumentSequence Represents XPS element type as DocumentReference Represents XPS element type as LinkTargets Represents XPS element type as GradientStops Represents the XPS Parser Represents the currently parsed Fixed Page Represents the XPS renderer object Represents the XPS enumerator delegate Represents the PdfUnitconvertor Creates an instance of the XPS parser class. Fixed page of the XPS The XPS renderer Enumerates the XPS file Reads the XPS canvas XPS canvas Reads the XPS glyphs XLS Glyphs Reads the XPS path XPS path Enumerates the XPS fixed page objects Converts the pixel value to points pixel value value in point Gets the XPS renderer Represents the XPS enumerator Represnets the XPS to PDF renderer. Represents the PdfGraphics where the XPS graphics is to be transformed. Represents the current PdfPage where the XPS graphics is transformed. Represents the PdfUnitConverter for the internal pixels to point conversion. Represents the XPS reader object. Represents the comma separator Represents the current transformation matrix. Intializes a new instance of the XPSRenderer class. The current PDF Page The XPS document reader Draws/converts the text objects from XPS to PDF. Glyph object with the metrics Converts the path string to a PdfPath Represents the path string Returns the PdfPath object Draws/converts the XPS Path to PDF path. The XPS path object Read and draw contents of VisualBrush. Convert from XPS linear gradient brush to PDF. LinearGradientBrush PdfLinearGradientBrush Convert from XPS radial gradient brush to PDF. RadialGradientBrush PdfRadialGradientBrush Converts XPS pathgeometry to PdfPath. PathGeometry PdfPath Convert string values to PointF String data. Data in PointF Convert string values to RectangleF String data. Data in RectangleF. Processes Gradient stops. Gradient stops read from file. Offsets Colors Returns the lowest value based on 0.0f Returns the first value greater than 0.0f Returns the highest value based on 1.0f Returns the top most value based on 1.0f Reads static resource based on hierarchy of elements. Name of the resource. Object containing the resource. Reads resource dictionary from the document. Returns resource from the collection. Converts the canvas graphics to PDF graphics. XPS Canvas Intializes the XPS canvas XPS canvas Applies the XPS transformation. Transformation matrix Grahics where the transformation is to be done. Applies the Graphics transformation Transformation matrix Prepares a matrix to PDF. The matrix. A properly prepared PdfTransformationMatrix class instance. Converts the matrix string to a System.Drawing.Drawing2D.Matrix object matrix string System.Drawing.Drawing2D.Matrix object Converts the Glyph font to PdfFont XPS Glyph object PdfFont Gets the SolidColorBrush form the color string Color string PdfBrush Gets the font style of the glyph StyleSimulations FontStyle Gets the font style of the glyph StyleSimulations FontStyle Converts the pixel values to point pixel value Points Convert the pixel coordinates to points pixel coordinates Coordinates in Points Converts string to float. Number as string. Converted number in float. Converts string to double. Number as string. Converted number in double. Gets the graphics of the current PdfPage Represents the XPS Parser Represents the currently parsed Fixed Page Represents the XPS renderer object Represents the XPS enumerator delegate Represents the PdfUnitconvertor Creates an instance of the XPS parser class. Fixed page of the XPS The XPS renderer Enumerates the XPS file Reads the XPS canvas XPS canvas Reads the XPS glyphs XLS Glyphs Reads the XPS path XPS path Enumerates the XPS fixed page objects Converts the pixel value to points pixel value value in point Gets the XPS renderer Represents the XPS enumerator Represnets the XPS to PDF renderer. Arabic characters will not be displayed properly if given the actual size, so the size is decreased by this decrement factor. Represents the PdfGraphics where the XPS graphics is to be transformed. Represents the current PdfPage where the XPS graphics is transformed. Represents the PdfUnitConverter for the internal pixels to point conversion. Represents the XPS reader object. Represents the comma separator Represents the current transformation matrix. Represents visualbrush viewport value. Represents visualbrush graphic state. Intializes a new instance of the XPSRenderer class. The current PDF Page The XPS document reader Draws/converts the text objects from XPS to PDF. Glyph object with the metrics Checks if the text contains RTL character or number. Array of symbols. True if the text contans RTL character or number. Converts the path string to a PdfPath Represents the path string Returns the PdfPath object Draws/converts the XPS Path to PDF path. The XPS path object set pixel color of an image. Read and draw contents of VisualBrush. Convert from XPS linear gradient brush to PDF. LinearGradientBrush PdfLinearGradientBrush Convert from XPS radial gradient brush to PDF. RadialGradientBrush PdfRadialGradientBrush Converts XPS pathgeometry to PdfPath. PathGeometry PdfPath Convert string values to PointF String data. Data in PointF Convert string values to RectangleF String data. Data in RectangleF. Processes Gradient stops. Gradient stops read from file. Offsets Colors Returns the lowest value based on 0.0f Returns the first value greater than 0.0f Returns the highest value based on 1.0f Returns the top most value based on 1.0f Reads static resource based on hierarchy of elements. Name of the resource. Object containing the resource. Reads resource dictionary from the document. Returns resource from the collection. Converts the canvas graphics to PDF graphics. XPS Canvas Intializes the XPS canvas XPS canvas Applies the XPS transformation. Transformation matrix Grahics where the transformation is to be done. Applies the Graphics transformation Transformation matrix Prepares a matrix to PDF. The matrix. A properly prepared PdfTransformationMatrix class instance. Converts the matrix string to a System.Drawing.Drawing2D.Matrix object matrix string System.Drawing.Drawing2D.Matrix object Converts the Glyph font to PdfFont XPS Glyph object PdfFont Gets the SolidColorBrush form the color string Color string PdfBrush Gets the font style of the glyph StyleSimulations FontStyle Gets the font style of the glyph StyleSimulations FontStyle Converts the pixel values to point pixel value Points Convert the pixel coordinates to points pixel coordinates Coordinates in Points Converts string to float. Number as string. Converted number in float. Converts string to double. Number as string. Converted number in double. Draw XPS string using text element Gets the graphics of the current PdfPage Initialise the new instance of the Outline Entry. Initialise the new instance of the TableCell. Initialise the new instance of the Solid Color Brush. Initialise the new instance of the Image Brush. Initialise the new instance of the Visual brush. Initialise the new instance of the Canvas. Initialise the new instance of the Glyphs. Initialise the new instance of the Path geometry. Initialise the new instance of the Path figure. Initialise the new instance of the Arc segment. Initialise the new instance of the Poly bezier segment. Initialise the new instance of the Poly line segment. Initialise the new instance of the Poly quadratic bezier segment. Initialise the new instance of the Linear gradient brush. Initialise the new instance of the Radial gradient brush. Initialise the new instance of the Path. The Syncfusion.XPS namespace contains classes for converting the XML Paper Specification (XPS) to PDF Represents the XPS to PDF converter. This API is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create new instance for XPSToPdfConverter XPSToPdfConverter converter = new XPSToPdfConverter(); //Converts XPS to PDF PdfDocument pdfDocument = converter.Convert("XPSToPDF.xps"); //Save the PDF document pdfDocument.Save("Output.pdf"); //Closing the PDF document pdfDocument.Close(true); 'Create new instance for XPSToPdfConverter Dim converter As New XPSToPdfConverter() 'Converts XPS to PDF Dim pdfDocument As PdfDocument = converter.Convert("XPSToPDF.xps") 'Save the PDF document pdfDocument.Save("Output.pdf") 'Closing the PDF document pdfDocument.Close(True) Represents the PdfUnitConverter identifying the oxps files Initializes a new instance of the class. This constructor is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. //Create new instance for XPSToPdfConverter XPSToPdfConverter converter = new XPSToPdfConverter(); //Converts XPS to PDF PdfDocument pdfDocument = converter.Convert("XPSToPDF.xps"); //Save the PDF document pdfDocument.Save("Output.pdf"); //Closing the PDF document pdfDocument.Close(true); 'Create new instance for XPSToPdfConverter Dim converter As New XPSToPdfConverter() 'Converts XPS to PDF Dim pdfDocument As PdfDocument = converter.Convert("XPSToPDF.xps") 'Save the PDF document pdfDocument.Save("Output.pdf") 'Closing the PDF document pdfDocument.Close(True) Initialize a new instance of the class. The XPS to PDF converter settings. //Create new XPS to PDF converter settings instance. XPSToPdfConverterSettings settings = new XPSToPdfConverterSettings(); //Enable enbed complete font. settings.EmbedCompleteFont = true; //Create a new XPS to PDF converter. XPSToPdfConverter converter = new XPSToPdfConverter(settings); //Convert the XPS file to PDF. PdfDocument document = converter.Convert("input.xps"); //Save the PDF document. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create new XPS to PDF converter settings instance. Dim settings As New XPSToPdfConverterSettings() 'Enable enbed complete font. settings.EmbedCompleteFont = True 'Create a new XPS to PDF converter. Dim converter As New XPSToPdfConverter(settings) 'Convert the XPS file to PDF. Dim document As PdfDocument = converter.Convert("input.xps") 'Save the PDF document. document.Save("output.pdf") 'Close the PDF document. document.Close(True) //Create new instance for XPSToPdfConverter XPSToPdfConverter converter = new XPSToPdfConverter(); //Converts XPS to PDF PdfDocument pdfDocument = converter.Convert("XPSToPDF.xps"); //Save the PDF document pdfDocument.Save("Output.pdf"); //Closing the PDF document pdfDocument.Close(true); 'Create new instance for XPSToPdfConverter Dim converter As New XPSToPdfConverter() 'Converts XPS to PDF Dim pdfDocument As PdfDocument = converter.Convert("XPSToPDF.xps") 'Save the PDF document pdfDocument.Save("Output.pdf") 'Closing the PDF document pdfDocument.Close(True) Converts the XPS document in stream to PDF. This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. XPS document PdfDocument //Create new instance for XPSToPdfConverter XPSToPdfConverter converter = new XPSToPdfConverter(); //Converts XPS to PDF PdfDocument pdfDocument = converter.Convert(XpsStream); //Save the PDF document pdfDocument.Save("Output.pdf"); //Closing the PDF document pdfDocument.Close(true); 'Create new instance for XPSToPdfConverter Dim converter As New XPSToPdfConverter() 'Converts XPS to PDF Dim pdfDocument As PdfDocument = converter.Convert(XpsStream) 'Save the PDF document pdfDocument.Save("Output.pdf") 'Closing the PDF document pdfDocument.Close(True) Converts the byte array with XPS file content to PDF This method is not supported in WinRT, Windows Phone, Xamarin, Universal Windows Platform and Silverlight. XPS document PdfDocument //Create new instance for XPSToPdfConverter XPSToPdfConverter converter = new XPSToPdfConverter(); //Converts XPS to PDF PdfDocument pdfDocument = converter.Convert(XpsByte); //Save the PDF document pdfDocument.Save("Output.pdf"); //Closing the PDF document pdfDocument.Close(true); 'Create new instance for XPSToPdfConverter Dim converter As New XPSToPdfConverter() 'Converts XPS to PDF Dim pdfDocument As PdfDocument = converter.Convert(XpsByte) 'Save the PDF document pdfDocument.Save("Output.pdf") 'Closing the PDF document pdfDocument.Close(True) Converts the Pixel to Point value. value in pixel value in points Enable or disable embedding complete font By enabling this propety the size of the output PDF will be larger. //Create a new XPS to PDF converter. XPSToPdfConverter converter = new XPSToPdfConverter(); //Create new XPS to PDF converter settings instance. XPSToPdfConverterSettings settings = new XPSToPdfConverterSettings(); //Enable enbed complete font. settings.EmbedCompleteFont = true; //Assign settings to XPS converter. converter.Settings = settings; //Convert the XPS file to PDF. PdfDocument document = converter.Convert("input.xps"); //Save the PDF document. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new XPS to PDF converter. Dim converter As New XPSToPdfConverter() 'Create new XPS to PDF converter settings instance. Dim settings As New XPSToPdfConverterSettings() 'Enable enbed complete font. settings.EmbedCompleteFont = True 'Assign settings to XPS converter. converter.Settings = settings 'Convert the XPS file to PDF. Dim document As PdfDocument = converter.Convert("input.xps") 'Save the PDF document. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Initializes a new instance of the class //Create a new XPS to PDF converter. XPSToPdfConverter converter = new XPSToPdfConverter(); //Create new XPS to PDF converter settings instance. XPSToPdfConverterSettings settings = new XPSToPdfConverterSettings(); //Enable enbed complete font. settings.EmbedCompleteFont = true; //Assign settings to XPS converter. converter.Settings = settings; //Convert the XPS file to PDF. PdfDocument document = converter.Convert("input.xps"); //Save the PDF document. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new XPS to PDF converter. Dim converter As New XPSToPdfConverter() 'Create new XPS to PDF converter settings instance. Dim settings As New XPSToPdfConverterSettings() 'Enable enbed complete font. settings.EmbedCompleteFont = True 'Assign settings to XPS converter. converter.Settings = settings 'Convert the XPS file to PDF. Dim document As PdfDocument = converter.Convert("input.xps") 'Save the PDF document. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Enable or disable embedding complete font By enabling this propety the size of the output PDF will be larger. //Create a new XPS to PDF converter. XPSToPdfConverter converter = new XPSToPdfConverter(); //Create new XPS to PDF converter settings instance. XPSToPdfConverterSettings settings = new XPSToPdfConverterSettings(); //Enable enbed complete font. settings.EmbedCompleteFont = true; //Assign settings to XPS converter. converter.Settings = settings; //Convert the XPS file to PDF. PdfDocument document = converter.Convert("input.xps"); //Save the PDF document. document.Save("output.pdf"); //Close the PDF document. document.Close(true); 'Create a new XPS to PDF converter. Dim converter As New XPSToPdfConverter() 'Create new XPS to PDF converter settings instance. Dim settings As New XPSToPdfConverterSettings() 'Enable enbed complete font. settings.EmbedCompleteFont = True 'Assign settings to XPS converter. converter.Settings = settings 'Convert the XPS file to PDF. Dim document As PdfDocument = converter.Convert("input.xps") 'Save the PDF document. document.Save("output.pdf") 'Close the PDF document. document.Close(True) Algorithm object identifier DSA signer Public key parameter and Private key parameter A strongly-typed resource class, for looking up localized strings, etc. Returns the cached ResourceManager instance used by this class. Overrides the current thread's CurrentUICulture property for all resource lookups using this strongly typed resource class. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.IO.StreamReader. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[]. Looks up a localized resource of type System.Byte[].