Hi there,
I've wrote a script that enables me to extract a table from multiple pdf files. Each table opens and the table name is matched to the file name.
I've realised the format of the pdfs isn't always consistent and so the header for column 3 can be different. Therefore, I would like to incorporate a function into my script that renames column 3 as "Property" for all the tables. I've tried the Set Name() function but it's not working. Perhaps it's in the wrong place?
// Prepare a directory
tempdir = "C:\folder path";
// Read PDF's
file_lst = Files In Directory( tempdir );
table_lst = {};
For( i = 1, i <= N Items( file_lst ), i++,
Insert Into( table_lst, Open( tempdir || "/" || file_lst[i],
PDF Tables(
Table(
table name(file_lst[i]),
add rows( page( 1 ), Rect( 0.4143, 5.3995, 7.5889, 6.6781 ) ),
column(table_lst[i],3) << set name("Property")
)
)
)
)
)Any help on this would be hugely appreciated!