Commands

To pass a command into PDF2XL OCR, prefix it with a minus sign ('-'), otherwise it will be treated as a filename (i.e., PDF2XL OCR will try to open a file in that name).
Each command will appear after a space, and if it has a value, it will be separated from it using an equal sign. If the value contains spaces, it MUST start and end with quotes, which will be removed from the value itself. If a quoted value has a quote inside, it needs to be doubled. See the CLI Examples for samples on the usage of the commands and quotes.

PDF2XL OCR will return an error code if there was a problem with the command line.

CommandValueDescriptionNotes
-input <filename> Loads the file. Can appear more than once. If a filename appears in the command line without any flag, it will be used as input.
-template same | different | repeat Set the structure type for the document. Overrides the saved setting.
-pagerepeat <number> Set the number of pages per repetition, for a repeating template. This option must appear if, and only if, the -template repeat option was used.
-firstpagediff   Set the First Page Different option, identical to the one in the Document Template dialog. This means that the first page does not repeat the layout in the same way as the rest of the document. Overrides the saved setting.
-lastpagediff   Set the Last Page Different option, identical to the one in the Document Template dialog. This means that the last page does not repeat the layout in the same way as the rest of the document. Overrides the saved setting.