Class PdfLoadedXfaArea
Represents the area type of the XFA form.
Namespace: Syncfusion.Pdf.Xfa
Assembly: Syncfusion.Pdf.Portable.dll
Syntax
public class PdfLoadedXfaArea : PdfLoadedXfaField
Examples
//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()
Properties
Fields
Represents loaded form fields collection.
Declaration
public PdfLoadedXfaFieldCollection Fields { get; }
Property Value
Type |
---|
PdfLoadedXfaFieldCollection |
Examples
//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()