It's very common to have to include dozens of PDF exhibits in an e-filing. You don't necessarily want to leave your MCO with the task of uploading lots of PDFs one by one to a court's site, but most courts limit the size of the files that you can upload - in the New York state courts there's a 20MB limit. In such a situation make use of the technique described below that is aimed at creating a script for Cool Utils' PDF Combine software:
1. Begin by saving all of your PDFs in one folder.
2. Use the batch script [dir /s >list.txt ] to a generate a list of the file names and their sizes.
3. Copy and paste the text that is generated into Excel.
4. Separate the data with Excel's Text to Columns tool, using the fixed width option.
5. With the file sizes in column B and the file names in column C, in cell D2 enter the formula: =IF((D1+B2)>20000000,B2,D1+B2), and pull it down by selecting the rest of the adjacent cells in column D, and pressing CTRL + D. This will add up file size but not go over 20 MB. Obviously this approach assumes that you want to only merge together consecutively numbered exhibits.
6. In cell E2, enter the formula: =IF(D2=B2,"begin","") and pull it down.
7. In cell F2, enter the formula: =IF(E3="begin","end","") and pull it down.
8. Insert two new columns between those containing the file size and the file name. In the column on the right enter the folder path, including the forward slash / . Filter the entries in the new column G to just get those marked "begin", and enter "C:\Program Files (x86)\PDF Combine\PDFCombine.exe" "
9. Enter a new column after the column with the file name and then filter the new column I for "end", and insert in column F a path to a new created folder which will hold the merged PDFs.
10. Enter two new columns after the one with the combined folder path, putting the numbers of the exhibits in the first and then putting the formula =IF(J2="begin",G2,H1) in cell H2 and pull down.
11. Filter by the column with the "end" marks again, and enter the formula ="Exhibits "&H6&" - "&G6&".pdf" in a new column after that in which the beginning of the exhibit ranges were marked in the above step. You should change the cell number references as appropriate. Then with the filter still in place enter " -kfs -c "Combine to PDF" -bookmark -npr 0,0 -bpdf in the column on the far right.
12. After copying and pasting to change all of your formulas to values, take out the columns that you don't need for the PDF Combine script -those will the file size, the list of exhibit numbers, and the begin and ending markers.
13. After the file name column enter a new column which has " " for all of the rows.
14. Copy and past all of the columns into a Word document using the text only option. Then find and replace all of the tabs [put ^t in find and replace with nothing], and then all of the paragrapher markers - ^p.
15. Now run a Find and Replace for: bookmark -npr 0,0 -bpdf with: bookmark -npr 0,0 -bpdf^p
16. Also Find and Replace any double quotation marks entered back to back with just one double quoations mark.
17. Examine your script and confirm that it follows the format shown in figure # 17 below. If it does, go ahead and paste it into a text file at the root of the folder you created for the combined exhibts. Change the extension from '.txt' to '.bat' and double-click on it. PDF Combine will now generate the PDFs you wanted for your e-filing!