ARTS PDF Split Pro™ Version 2.
ARTS PDF Split Pro™ Guide Contents Contents 1. INTRODUCTION .............................................................................................. 5 1.1. New to version 2.0 .................................................................................... 5 1.2. Demo Limitations ...................................................................................... 5 2. SETUP .......................................................................................................... 6 2.1.
ARTS PDF Split Pro™ Guide Contents 6.3. Options...................................................................................................28 6.3.1. 6.3.2. 6.3.3. 6.3.4. 6.3.5. Logging enabled........................................................................................... Silent Mode ................................................................................................. Overwrite output file.....................................................................................
ARTS PDF Split Pro™ Guide Contents 8.5.2. ASP............................................................................................................ 44 9. APPENDIX A – RECTANGLE COMMANDS ............................................................. 46 10. APPENDIX B – COMMAND LINE SWITCHES ........................................................ 51 11. TROUBLESHOOTING ....................................................................................... 55 11.1. Frequently Asked Questions......
ARTS PDF Split Pro™ Guide Introduction 1. Introduction ARTS PDF Split Pro™ is an industrial grade, stand-alone PDF splitter that allows you to split large PDF files into smaller PDF files, in many different ways.
ARTS PDF Split Pro™ Guide Setup 2. Setup 2.1. System Requirements Windows • • • • • Intel® Pentium® processor or equivalent Microsoft® Windows NT® Workstation 4.0 with Service Pack 6, Windows® 2000 with Service Pack 2, Windows XP Professional or Home Edition, or Windows XP Tablet PC Edition 64MB of RAM (128MB recommended) 50MB of available hard-disk space 1,024x768 screen resolution Note: ARTS PDF Split Pro™ Assistant requires Adobe® Acrobat® 5.0 or later.
ARTS PDF Split Pro™ Guide Setup 2.3. Activation If you have the demo version of ARTS PDF Split Pro™ installed, you can activate the full version using the following steps: 1. Open ARTS PDF Split Pro by going to ‘Start > Programs > ARTS PDF > ARTS PDF Split Pro > ARTS PDF Split Pro 2.0’. 2. Click the ‘About’ button. 3. Ensure you have a valid serial. A valid serial can only be obtained by purchasing the product. To purchase ARTS PDF Split Pro™: a.
ARTS PDF Split Pro™ Guide Setup 2.4. Registration ARTS PDF provide the option of registering your copy of ARTS PDF Split Pro™ online. Online registration allows you to protect your serial number. In the event you lose or misplace your serial, we can locate and provide your serial to you on request. Registered customers will also receive important upgrade information and notification of product updates. 1. After activating your copy of ARTS PDF Split Pro™ you will be prompted to register online.
ARTS PDF Split Pro™ Guide Splitting Methods 3. Splitting Methods ARTS PDF Split Pro™ can split PDFs into smaller PDF files (or fragments) using a number of different methods. ARTS PDF Split Pro™ can split PDFs by bookmarks, by control file2 , by file size, into single pages and by coordinate file. These splitting methods are explained in detail below. 3.1. Split by Bookmarks This method will split a PDF file by its bookmarks.
ARTS PDF Split Pro™ Guide Splitting Methods You can Split By Control File (not full path) using either of the following ARTS PDF Split Pro™ components: • GUI • CLI • COM 3.3. Split by Control File - Full Path This method of splitting will split a PDF file as specified in a control file, with each output file (or fragment) being stored in the directory indicated by the full path in the control file.
ARTS PDF Split Pro™ Guide Splitting Methods If the fragment size is equal to or greater than the file size specified then at that point the PDF will be split. Otherwise ARTS PDF Split Pro™ will move onto the next page and perform the same check again. You can Split By File Size using either of the following ARTS PDF Split Pro™ components: • GUI • COM 3.5.
ARTS PDF Split Pro™ Guide Watched Folders 4. Watched Folders The watched folders function in ARTS PDF Split Pro™ GUI and CLI allows an automated splitting solution to be set-up and accessible from the desktop or across a network.
ARTS PDF Split Pro™ Guide Assistant 5. ARTS PDF Split Pro™ Assistant The ARTS PDF Split Pro™ Assistant is a plug-in for Adobe Acrobat that assists the user to create coordinate files of which are utilized when splitting with ARTS PDF Split Pro™. It has been designed to allow the user to create coordinate files quickly and easily without the need to directly create or edit coordinate (text) files. The ARTS PDF Split Pro™ Assistant can be accessed via the toolbar, or Plug-ins menu. | CONTENTS | Figure 1.
ARTS PDF Split Pro™ Guide Assistant 5.1. What is a Coordinate File? A coordinate file must be used when performing a ‘Split By Coordinate File’ split method. Coordinate files use a .crd file extension but they are plain text files that can be viewed or edited with any text editor. The contents of a coordinate file may contain a single line or multiple lines of commands. An example of a coordinate file is shown below: splitontextchange 507.406555 56.816055 535.184265 24.408707 addtofilename 507.406555 56.
ARTS PDF Split Pro™ Guide Assistant Rectangle coordinates Rectangle coordinates (left, top, bottom and right) are used to view the rectangle using ARTS PDF Split Pro™ Assistant. The rectangle is used to look at text on a PDF page for the splitting of PDFs. Text within a rectangle area can be compared against the specified string parameter passed. Example: splitiftextcontainedinbox 70.093918 736.859451 141.122421 703.214371 "arts" The coordinates, 70.093918 736.859451 141.122421 703.
ARTS PDF Split Pro™ Guide Assistant 5.2. Managing Coordinate Files 5.2.1. Creating a New Coordinate File To create a coordinate file: 1. Open a PDF document in Adobe Acrobat. 2. Click the 'Create a new CRD file' button on the ARTS PDF Split Pro™ Assistant toolbar. You can alternatively go to 'Plug-ins > ARTS PDF Split Pro Assistant > New' in the Adobe Acrobat plug-ins menu. The ‘Rectangle Tool’ button is now automatically activated enabling you to draw a rectangle on your PDF page. 3.
ARTS PDF Split Pro™ Guide Assistant The rectangle tool will open the Rectangle Tool Properties window allowing you to: • Create a new command • Edit an existing command Figure 5. • ‘Rectangle Tool Properties’ dialog Rectangle Command The default command is ‘noop’ which means there is no active command selected for this rectangle. Select the command you wish to use for the rectangle you just created on your page.
ARTS PDF Split Pro™ Guide Assistant 5.2.3. Editing a Coordinate File To edit a rectangle command or string parameter: 1. Open a PDF document in Adobe Acrobat. 2. Open a coordinate file to edit if one is not yet open. 3. Open the ‘Rectangle Tool Properties’ dialog by doing one of the following: • Activate the Rectangle Tool and then double click on the rectangle you wish to edit. • Open the View Commands dialog, select the command you wish to modify and click ‘Edit’. 4.
ARTS PDF Split Pro™ Guide Assistant 5.2.5. Saving a Coordinate File To save the active coordinate file: 1. Select ‘Save’ from the ARTS PDF Split Pro™ Assistant menu or click on the save button located on the ARTS PDF Split Pro™ Assistant toolbar. 2. Enter a filename for your coordinate file and select the directory you wish to save to, ensuring that the file extension is of .crd type (it will be .crd by default). 3. Click ‘Save’. Figure 7. 5.2.6.
ARTS PDF Split Pro™ Guide Assistant Figure 10. How the human eye sees the text Figure 11. How ARTS PDF Split Pro™ sees the text (zoomed to 200%) Figure 10 and 11 show the difference between how the human eyes sees text on the page, and how ARTS PDF Split Pro™ sees it. In figure 11, the red text is what ARTS PDF Split Pro™ sees, and the text behind in and in figure 10 is how it appears to the user on the page. 5.2.8.
ARTS PDF Split Pro™ Guide Assistant inside it, and as mentioned earlier the red crosses denote these runs of text. The text that ARTS PDF Split Pro™ Assistant would recognize from this triangle and the two runs of text inside it are: • r in the list o • down menu Note: if a line of text begins inside a rectangle, the entire run of text is considered "inside" that rectangle.
ARTS PDF Split Pro™ Guide Assistant Figure 15. ‘Display and reorder command’ toolbar button View Commands dialog lists all commands within a coordinate file. It is possible to change the order of commands within the coordinate file simply by clicking on the ‘Move Up’ or ‘Move Down’ button. With the dialog open, scroll through the PDF document to see what text on the page is recognized by the rectangle coordinates.
ARTS PDF Split Pro™ Guide Graphical User Interface 6. ARTS PDF Split Pro™ GUI ARTS PDF Split Pro™ is referred to as the component that performs the actual PDF splitting. This is accessed through the ARTS PDF Split Pro™ Graphical User Interface (GUI). You can open ARTS PDF Split Pro™ from the Windows Start menu by going to ‘Start > Programs > ARTS PDF > ARTS PDF Split Pro > ARTS PDF Split Pro 2.
ARTS PDF Split Pro™ Guide Graphical User Interface 6.1.2. Split by Control File To split by a control file: 1. Select ‘Split PDF by Control File’ as the method of splitting. 2. Select the source pdf file to be split. 3. Select the control file that will determine the split files. This control file should not contain full pathnames. 4. Select the destination folder where the pdf files will be stored following splitting. This can be set to the same as the source folder, or in the folder of the users choice.
ARTS PDF Split Pro™ Guide Graphical User Interface 6.1.5. Split by File Size To split by file size: 1. Select ‘Split PDF by File Size’. 2. Select the source PDF file to be split. 3. Select the destination folder where the PDF files will be stored following splitting. This can be set to the same as the source folder, or in the folder of the users choice. 4. Enter the base name for each split fragments.
ARTS PDF Split Pro™ Guide Graphical User Interface 6.2. Watched Folders 6.2.1. Setting up a Watched Folder Figure 17. Setting up watched folders To set-up watched folders: 1. Click the ‘Watch Folder’ button on the ARTS PDF Split Pro™ GUI. 2. Select whether to ‘Split into Single Pages’, ‘Split by Control File’ or ‘Split by Coordinate File’. More information on this can be seen in the following sections. 3.
ARTS PDF Split Pro™ Guide Graphical User Interface 4. It is optional to select the ‘overwrite the original file’ checkbox that will overwrite existing output files. 5. It is optional to add a suffix after the filename (but before number) for each split PDF. 6. Select to have the split PDFs placed directly into the output folder or within a subdirectory that would be created within the output directory. The subdirectory will be named by the name of the PDF file dropped into the input folder. 6.2.2.
ARTS PDF Split Pro™ Guide Graphical User Interface 6.2.2.3. Split by control file – full path If splitting by ‘control file - full path’ using watched folders, select the control file option and leave the output directory blank. 6.2.2.4. Split by coordinate file By selecting this option, the watched folder will split each pdf into fragments based on a coordinate file the user must select.
ARTS PDF Split Pro™ Guide Graphical User Interface In addition to the options found within the Options dialog, you can find options applicable to watched folders in the Watched Folder dialog. See Figure 20. Figure 20. Watched Folder options in red 6.3.1. Logging enabled The option to enable logging can be found in the Options dialog. With ‘Logging enabled’ selected, ARTS PDF Split Pro™ will log successful and unsuccessful split events.
ARTS PDF Split Pro™ Guide Graphical User Interface 6.3.2. Silent Mode The option to run ARTS PDF Split Pro™ in silent mode can be found in the Options dialog. This will run ARTS PDF Split Pro™ with no visual output or required user interaction. It is recommended that the ‘Logging enabled’ checkbox is selected if silent mode is checked. Logging enabled will notify you of any errors or status messages by writing entries to a log file.
ARTS PDF Split Pro™ Guide Graphical User Interface GoTo 5 links are adjusted to stay connected to the proper page, even if the pages end up in a different order in the final document. GoTo links are changed into a GoToR 6 links to ensure that links are not broken should a linked page end up in different output file.
ARTS PDF Split Pro™ Guide Command Line Interface 7. ARTS PDF Split Pro™ CL ARTS PDF Split Pro™ can be launched from the command line using command line switches to specify what type of splitting to process. ARTS PDF Split Pro™ Command Line Interface (CLI or CL) application can be found in the ARTS PDF Split Pro folder e.g. C:\Program Files\ARTS PDF Split Pro\ARTS PDF Split Pro CL.exe. It is important that spaces are placed between each switch specified.
ARTS PDF Split Pro™ Guide Command Line Interface 7.1.4. Split into Single Pages To split by single pages, you will need to use the fragment size (-k), input (-i) and output (-o) switches. For example: “c:\ARTS PDF Split Pro CL.exe" -k 1 -i "c:\inputfile.pdf “ -o "c:\outputfolder\basefilename" In addition, you can use the serial number (-n) switch to add padded zeros to the suffix and use the fragment numbering (-f) switch to specify the starting number.
ARTS PDF Split Pro™ Guide Command Line Interface 7.3. Watched Folders 7.3.1. Watched Folder Splitting Methods 7.3.1.1. Split into single pages Use the watch folder (–w) switch, along with the done (-d), input (-i), output (-o), busy (-b), error (-e), and fragment size (-k) switches, to split a file into single pages using a watched folder. For example: “c:\ARTS PDF Split Pro CL.exe" -w -d "c:\donefolder\" -i "c:\inputfolder” -o "c:\outputfolder“ -b "c:\busyfolder“ -e "c:\errorfolder“-k 1 7.3.1.2.
ARTS PDF Split Pro™ Guide Command Line Interface Use the overwrite (–ow) switch for watched folders to overwrite existing output files when running a watched folder. For example: “c:\path\ARTS PDF Split Pro CL.exe" -wc "c:\path\coordinatefile.crd" “c:\path\inputfolder\” “c:\path\outputfolder\” “c:\path\busyfolder\” “c:\path\donefolder\” “c:\path\errorfolder\”] -ow 7.4.2. Update navigational elements Use the update navigational elements switch (–ne) to update bookmarks and links within output files.
ARTS PDF Split Pro™ Guide COM Object 8. ARTS PDF Split Pro™ COM ARTS PDF Split Pro™ COM allows developers to integrate the ARTS PDF Split Pro™ methods of splitting in custom applications. The COM component comes as a DLL file containing methods that can be called to split PDF files and can be utilized in environments such as Visual Basic, Delphi, ASP, ASP.NET and PHP. Examples of Visual Basic and ASP code can be found in section 8.2 of this document, COM Examples. 8.1.
ARTS PDF Split Pro™ Guide COM Object 8.2. Class Strings/Namespaces Use the following class strings to instantiate the ARTS PDF Split Pro COM object. Please note that we do not provide a native .NET assembly class. To use ARTS PDF Split Pro in a .NET application you will need to utilize an Interop Assembly and include this within the bin folder of the application, i.e. bin\Interop.ARTSSPLITPROCOMLib.dll. 8.2.1. Visual Basic ARTSSPLITPROCOMLib.
ARTS PDF Split Pro™ Guide COM Object Using ARTSSPLITPROCOMLib ARTSSplitProClass objAPSplit; 8.2.5. Delphi ARTSSplitPro.ARTSSplitPro APSP: Variant; APSP := CreateOleObject('ARTSSplitPro.ARTSSplitPro'); 8.2.6. PHP ARTSSplitPro.ARTSSplitPro $APSplitPro = new COM("ARTSSplitPro.ARTSSplitPro") 8.3.
ARTS PDF Split Pro™ Guide COM Object 8.4. Object ARTSSplitPro The ARTSSplitPro object carries informational properties as well as methods for the functionality to split a PDF file. ARTSSplitPro offers you the following methods: 8.4.1.
ARTS PDF Split Pro™ Guide COM Object accepted. Parameters Return Value 8.4.4. sSN – Valid serial number or use ‘DEMO’ to run in demo mode. SOldSN – Optional parameter. Valid serial number of the previous version. Only required if an upgrade serial is used for sSN. 0 if serial number is accepted, COM will run in full. 1 if serial is invalid, COM will run in demo mode. SetOverwriteMode SetOverwriteMode SetOverwriteMode (BOOL bOverwriteMode) Description Sets the overwrite mode.
ARTS PDF Split Pro™ Guide COM Object 8.4.7. SplitByControlFile SplitByControlFile Long SplitByControlFile (String sInputFile, String sOutputFolder, String sControlFile, BOOL bFullPath) Description This method splits a PDF using the split by control file method. Parameters Return Value Related methods 8.4.8. sInputFile – Pathname of the source PDF. sOutputFolder – Path of the destination folder where output files are placed. SControlFile – Pathname of the control file.
ARTS PDF Split Pro™ Guide COM Object Return Value Related methods 0 if PDF split is successful otherwise returns an error value. GetErrorMessage 8.4.10. SplitIntoSinglePages SplitIntoSinglePages Long SplitIntoSinglePages (String sInputFile, String sOutputFolder, String sBaseName) Description This method splits a PDF using the split into single pages method. Parameters sInputFile – Pathname of the source PDF. sOutputFolder – Path of the destination folder where output files are placed.
ARTS PDF Split Pro™ Guide COM Object 8.5. COM Examples 8.5.1. Visual Basic Private Sub cmdSplit_Click() Dim Dim Dim Dim Dim sMode As String ' version mode (demo or full) lMode As Long ' value of the version mode iCounter As Integer lOptionSelected As Long ' value of the split method selected lSplitResult As Long ' value of the split result Dim SplitPro As New ARTSSPLITPROCOMLib.ARTSSplitPro 'Display version number txtVersionNumber = SplitPro.
ARTS PDF Split Pro™ Guide COM Object txtOutput, txtCoordinateFile) Case 3 lSplitResult = SplitPro.SplitByFileSize(txtInput, txtOutput, txtFileSize) Case 4 lSplitResult = SplitPro.SplitIntoSinglePages(txtInput, txtOutput, txtBaseName) End Select 'Check if an error occurred If lSplitResult <> 0 Then 'If an error has occurred display the error message MsgBox (SplitPro.GetErrorMessage(lSplitResult)) End If Set SplitPro = Nothing End Sub 8.5.2. ASP <% Dim ARTSSplitPro Set ARTSSplitPro =server.
ARTS PDF Split Pro™ Guide COM Object set fso = createobject("scripting.filesystemobject") ' create the text file Set act = fso.CreateTextFile("C:\test\test.txt", true) set filename = fso.GetFile("c:\test\test.txt") ' write all of the user input to the text file act.WriteLine pagerange & vbTab & outputfilename Response.Write "
" ' close the document act.Close %>
Text file created using ARTS PDF Split Pro COM v.<%=ARTSSplitPro.
ARTS PDF Split Pro™ Guide Appendix A - Rectangle Commands 9. Appendix A – Rectangle Commands Rectangle commands are used in coordinate files. Contained in this appendix is a list of all the commands that can be used in conjunction with the rectangle tool found in the ARTS PDF Split Pro™ Assistant. SplitIfTextIsPresent If the specified parameter is contained in any run of text on the page, the PDF will be split and the page will be the start of a new file. The comparison is case sensitive.
ARTS PDF Split Pro™ Guide Appendix A - Rectangle Commands ProvideBaseFilename Takes the specified string parameter entered and uses it as the base filename of any split output files. ProvideFilename Whatever text falls inside the rectangle (see runs of text) is used as the file name for the fragment. If this command appears more than once in the coordinate file, the last provideFilename command will overwrite any other provideFilename commands.
ARTS PDF Split Pro™ Guide Appendix A - Rectangle Commands addToFileNameAfterStringInBox This searches inside the rectangle for the string parameter. This command adds the text that comes after the string parameter to the output filename. DeleteCharactersFromFilename If the specified character is found in the run of text for any of the providefilename or addtofilename commands, the character will be deleted as the text is added to the filename.
ARTS PDF Split Pro™ Guide Appendix A - Rectangle Commands IncludeIfTextChangeAfterString Looks at the text inside the rectangle for the string, if the string exists it will check if the text after the string changes. If the text after the string changes from the previous page that contained the string then the page will be included into the fragment. Since by default all pages go into one fragment or another, this command is only effective if a false parameter is passed to the includeall command.
ARTS PDF Split Pro™ Guide Appendix A - Rectangle Commands ExtractTextSkipThisWord This command works similarly to the extracttext command, but it skips over any initial Whitespace and skips over the first occurance of text in the run of text. If text is not present, the entire run of text inside the rectangle is extracted. If text is present, then the text that comes after text in the run of text inside the rectangle is extracted.
ARTS PDF Split Pro™ Guide Appendix B - Command Line Switches 10.Appendix B – Command Line Switches The following switches can be used with ARTS PDF Split Pro™ Command Line (CL). Input switch -i [c:\input.pdf] The input switch specifies the pdf file to be split. Output switch -o [c:\input.pdf] -o [c:\outputfolder] The output switch specifies the name of the fragment created or the folder that will contain the fragments, depending upon which other switches are used. Control switch -c [c:\control.
ARTS PDF Split Pro™ Guide Appendix B - Command Line Switches Watched folder switch -w [c:\done] The watched folder switch starts a watched folder using the method of splitting specified by other switches. This requires the -i, -o, -b, -d, and -e switches. For specifying what method of splitting to use, only the -k 1 switch is currently supported for watched folders from the command line with the -w flag.
ARTS PDF Split Pro™ Guide Appendix B - Command Line Switches Split by bookmark switch -m [1-1] The split by bookmark switch uses two numbers separated by a dash to specify the level of bookmarks that are used for splitting. See split by bookmarks for more information. Coordinate file switch -x [c:\coordinate.crd] The -x switch specifies a coordinate file to be used in splitting a pdf file. The -i and –o switches are required. See the coordinate files section for more information.
ARTS PDF Split Pro™ Guide Appendix B - Command Line Switches Headless switch -h [c:\statuslog.txt] The headless switch causes the software to run without any visual output or user interaction. Any error or status messages are written into the status log. The software also returns an error value, with zero indicating success. If the specified status log already exists, it will be deleted and replaced with a new log. Shared read switch -sh [c:\coordinate.
ARTS PDF Split Pro™ Guide Troubleshooting 11.Troubleshooting 11.1.
ARTS PDF Split Pro™ Guide Troubleshooting General “I am having a problem with ARTS PDF Split Pro™ and it is not covered in this FAQ. What can I do?” • Visit our ARTS PDF Forum (http://forum.artspdf.com) to talk with ARTS PDF technical support and other ARTS PDF product users. Search the existing discussions and/or post your own questions. Each ARTS PDF product has it own dedicated discussion area. • Visit our website at http://www.artspdf.com/support.asp for more information on ARTS PDF support. 11.2.
ARTS PDF Split Pro™ Guide Troubleshooting 11.4. Maintenance At times ARTS PDF will release updates that may include significant enhancements to the product. It is recommended that you take up annual maintenance to be entitled to free upgrades (whether it be minor or major release versions) over a period of 12 months from the initial purchase. Annual Maintenance also entitles you to priority phone and email support.
ARTS PDF Split Pro™ Guide Troubleshooting 11.5. Technical Support Before contacting ARTS PDF please read the complete Troubleshooting section as the answer to your problem may be found in the FAQs or on the ARTS PDF Forum. To contact ARTS PDF Technical Support, submit your query using the support contact form found on our website: http://www.artspdf.com/support_contact.asp. The information below will help us assist you with the problem you are experiencing. a.