Our spec sheets are made with InDesign, and there is a certain set of data points in one of the tables that we'd like to extract and put into a spreadsheet. We have thousands of these files though, so I'd like to see if there's a way to script an automated process.
I've used scripts for other tasks before, and even hacked at a few to create little solutions; but this one is well beyond me, and I just want to see if it's even possible.
The spec sheets are two pages. On page 2, there's a table with specs on it. It's a 2-column table, with section titles merged across both columns, and data cells have the data title on the left, and the data itself on the right. The data we need is the last 4 rows of the table. The header cell is "SHIPPING DATA", and then the four rows are weight, height, width, and depth. This data is always the last four rows of the table in every spec sheet.
So, I'm wondering if it's possible that a script could:
- either process a batch of files in a folder, or any open files,;;
- where per file, it could grab the name of the file and put that into a spreadsheet, row 1 column A;;
- then Find "SHIPPING DATA", select the 4 cells of data beneath that, and paste them into the spreadsheet row 1 columns B-E / might have to grab the data from those four cells one by one;;
- and then move to the next file, putting that same info into row 2
As I said, I don't even know if this would be possible, so I've not tried anything yet. If anyone has any ideas or thoughts on this, I'm all ears. Thanks!
Edit 01: Adding a screenshot that shows the file name and the portion of the table I refer to in my question.