Fills the PDF form document.
public void FillFormFields(
IList<PDFFormField> fields,
string destinationFileName
)
public:
void FillFormFields(
IList<PDFFormField^>^ fields,
String^ destinationFileName
)
def FillFormFields(self,fields,destinationFileName):
fields
A List of PDFFormField to fill. This must not be null and a list of 1 or more items. An empty list (count is zero) will throw an exception.
destinationFileName
Name of the destination PDF document to be created. If the value of this parameter is null, then the filename set in FileName will be updated.
You can use FillFormFields to fill PDF form documents.
LEADTOOLS supports loading all form fields from a PDF file. Due to the nature and complexity of PDF form fields, especially the prevalent use of PDF files that contain many custom and user-defined fields, LEADTOOLS reads the data as is and sets it in PDFFormField without any modification. Refer to the PDF Form Fields Demo for an example of parsing data to generate a live, editable PDF file.
using Leadtools.WinForms;
using Leadtools;
using Leadtools.Codecs;
using Leadtools.Controls;
using Leadtools.Drawing;
using Leadtools.ImageProcessing;
using Leadtools.Pdf;
using Leadtools.Svg;
public void PDFFillFormFieldsExample(string fileName, string name, string value, int type)
{
PDFFile file = new PDFFile(fileName);
IList<PDFFormField> fields = new List<PDFFormField>();
PDFFormField field = new PDFFormField();
field.Name = name;
field.Contents = new List<String>();
field.Contents.Add(value);
field.ContentType = type;
fields.Add(field);
file.FillFormFields(fields, null);
}
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document