tryin to have javascript grab info from excel and fill out pdf.
Copy link to clipboard
Copied
Hi, I am at a loss. I am trying to have javascript use the info from a text box to search an excel file with muitiple tabs at the bottom. Then return the dat of last inspection into a a text box on pdf and the last grade in anothor text box. So below is a few snipits of what i am trying to do. I want to use the rig line to search the excel file and grab the last (inspection date) BOPE date and grade. I am generally pretty good with adobe and javascript and excel but at a loss on this one. PLEASE HELP if you can.
 
 
 
  
Copy link to clipboard
Copied
Acrobat cannot read an Excel file directly. In fact there aren't any built in tools, or even 3rd party tools that fit the requirements you've described.
However, it is possible to create such a tool with an Acrobat Automation Script.
First though you'll need to save the Excel sheets to a text format such as CSV. Ideally, the entire workbook should be saved to a single file format, such as XER, that can handle multiple sheets. But if you'll need to save the sheets that are needed separtely.
Writing such a script is non-trivial. You can read about Acrobat Automation Scripts here:
https://www.pdfscripting.com/public/Automating-Acrobat.cfm
Alternatively you can use the Acrobat IAC to write a VBA script in Excel that opens the PDF form and fills it with the appropiate information.
Here's the IAC Reference:
https://opensource.adobe.com/dc-acrobat-sdk-docs/library/interapp/index.html
Use the Acrobat JavaScript Reference early and often

