FindFormFieldByTitle finds extra form field that doesn’t exist
When calling the FindFormFieldByTitle it can sometimes find two fields with the same name. For example, in a PDF form there might be a form field with the title “Name_Of_Campaign“. The PDF SDK will find that form field fine but it might also find another field called with a very similar name such as “Name_Of_Campaign.“. Note the extra period (.) at the end of the form field title.
In this case the “.” character in a form field indicates a child field. If you created a field called “Parent.Child” you will get two form fields created in the PDF.
- Parent
- Parent.Child
In this example (Name_Of_Campaign.Name_Of_Campaign) because the parent and child form field title is the same, both are being found by the FindFormFieldByTitle function.
Every PDF is unique and we can enhance the library so that it does not confuse parent and child form fields when the title is the same if you create a support case and send us the PDF file that you’re working with.
This article refers to a deprecated product. If you are looking for support for Foxit PDF SDK, please click here.
Updated on May 16, 2022