PdfFormData.GetFieldNames() Method
Returns the name of all fields contained in this PDF form.
Namespace: DevExpress.Pdf
Assembly: DevExpress.Pdf.v19.1.Core.dll
Declaration
Example
The following example demonstrates how to obtain a list of current fields in a PDF Form via the PdfFormData.GetFieldNames
method.
Note
A complete sample project is available at https://github.com/DevExpress-Examples/how-to-programmatically-fill-an-interactive-form-with-values-t210253
' Load a document with an interactive form.
Using documentProcessor As New PdfDocumentProcessor()
documentProcessor.LoadDocument(filePath & fileName & ".pdf")
' Get names of interactive form fields.
Dim formData As PdfFormData = documentProcessor.GetFormData()
Dim names As IList(Of String) = formData.GetFieldNames()
' Show the field names in the rich text box.
Dim strings(names.Count - 1) As String
names.CopyTo(strings, 0)
richTextBox1.Lines = strings
End Using
Related GitHub Examples
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the GetFieldNames() method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.