I can extract all the information I need through a combination of the formFields and pages fields, almost hardcoding where to find the pieces of information I need (picture of what was used), and this works for the current document that I am working on, but if I need to upload multiple documents, it would be very tedious to look through every single one and hardcode the lines simply to extract what I am looking for, as different documents will be in different formats, or have slightly different spacing guidelines.
So I was wondering if I would be able to simply search for what I was looking for, for example let's say I wanted the Total Disbursements this period (which was the example used in the code). Would there be a way to simply search in the code using the keywords "Total Disbursements this period" to find the value in the formField?
The main reason I require this ease of accessibility is that I'm trying to take the numbers I get from the document and put it into an excel file. This excel file will have empty boxes with fields to fill up, and I will want to automate the reading of the document and the inputting of the correct information.