Batch Conversion of PDF Files into Microsoft Word Format
- Introduction
- The tutorial shows how to convert a set of PDF files into the Microsoft Word format using the Action Wizard tool provided by the Adobe® Acrobat® Pro. The tutorial shows how to launch conversion from outside of the Adobe® Acrobat® using AutoBatch plug-in.
- The tutorial provides the step-by-step instructions for:
-
- Creating Action Wizard "action" for converting all files from a folder into MS Word format (*.docx).
- Creating a batch file (*.bat) for starting the conversion from outside of the Adobe® Acrobat®.
- Executing the file conversion job.
- Prerequisites
- You need a copy of the Adobe® Acrobat® Pro along with the AutoBatch™ plug-in installed on your computer in order to use this tutorial. You can download trial versions of both the Adobe® Acrobat® and the AutoBatch™ plug-in.
- Step 1 - Start Action Wizard Tool
- Start the Adobe® Acrobat® Pro application. Select the "Tools" panel located on the main Adobe® Acrobat® toolbar. Double click on the "Action Wizard" tool icon to open the tool controls.
- Step 2 - Create New "Action"
- Click on the "New Action" icon on the "Action Wizard" toolbar to create a new batch processing "action".
- Step 3 - Expand the "Save & Export" Category
- Expand the "Save & Export" category to see available commands.
- Step 4 - Add the "Save" Command to the Action Steps
- Double click a command "Save" or select it and press "+->" button to add it to the list of action steps.
- Step 5 - Specify an Output Folder
- Click the "OK" icon next to the "Save" command.
- Select "Save to Local Folder" from the pull-down list.
- Specify an output folder where to place the resulting files. The "Output Folder" is selected in the tutorial. Click "OK" once done.
- Step 6 - Specify the Conversion Settings
- Click "Specify Settings" below the "Save to Local Folder" action step.
- Select "Export File(s) to Alternate Format" in the "Output Options" dialog. Select "Word Document" from the "Export to:" pull-down list. This command will convert PDF files to the Microsoft Word *.DOCX format as part of the file saving procedure. Click "OK" to finish.
- Step 7 - Specify a Folder to Process
- Click the "Add Folder" icon in the "Files to be Processed" section.
- Select a folder that contains the PDF files to be converted. Click "OK" once done.
- Step 8 - Save the Action
- The action is now configured. We have specified both input and output folders and the file format conversion settings. Click "Save" button to save the action.
- Type a desired "Action Name" and, optionally, enter a description into the "Action Description" box. We have named the action as "Convert PDF into Word" in the tutorial. Click "Save" to save the action.
- The action can be used now in the Action Wizard tool by manually starting it from the actions list. No further steps are necessary, unless the action needs to be executed from outside of the Adobe® Acrobat®.
- Step 9 - Create a Batch File (*.bat)
- The new action is now listed in the "Actions List" of the Action Wizard tool and can be started by double-clicking on it.
- Now we are going to create a command-line batch file (*.bat) that can be used to execute the action from outside of the Adobe® Acrobat®. This functionality requires the AutoBatch plug-in. The batch file is auto-generated based on the user-selected parameters. Select "Plug-Ins > Create Batch File..." from the Adobe® Acrobat® main menu to open the "Create Command-Line Batch File" dialog.
- Select the created action from the "Select Acrobat Action" list. We have selected the "Convert PDF into Word" action in the tutorial.
Select "Do nothing" from the "Select Final Action:" list unless input files need to be moved or copied after the processing. - Check the "Create a Task-Scheduler Compatible batch file" to create a file that will execute silently without displaying any windows.
- Click the "Create Batch File..." button to auto-generate a batch file.
- Specify a folder and a file name for the batch file. We have named the file as "AutoBatch_Convert_PDF_into_Word.BAT" in the tutorial. Click "Save" to save the action.
- Click "Close" to close the "Create Command-Line Batch File" dialog.
- Step 10 - Close the Adobe® Acrobat®
- Use "File > Exit" menu to exit Adobe® Acrobat®.
- Step 11 - Run the Batch File
- Now open the folder where "AutoBatch_Convert_PDF_into_Word.BAT" file is located and double-click on it to execute.
- The batch file will be executed converting PDF files into the Microsoft Word format.
- For each PDF file in the input folder, there is going to be one *.docx file in the output folder.
- Advanced: Using Different Input and Output Folders
- It's possible to override an input/output file or folder selection in "action" and pass a different file or a folder path. It allows using the same "action" with different input/output files and folders without editing the "action" itself. You can pass a custom input/output file or folder path as a batch file parameter (see example below). The alternative path is going to be used instead of input/output file or folder specified in the original "action". The alternative paths(s) can be passed either in the Windows Command-Prompt or as part of the another BAT file.
- Using another BAT file
- Use "CALL" statement to pass different parameters as part of another BAT file. Multiple jobs can be started from a single BAT file while passing different input/output folders. Use any plain text editor to create a BAT file with different input/output folders passed as the parameters:
-
CALL AutoBatch_Convert_PDF_into_Word.BAT "c:\pdf\June\" "c:\data\MsWord\June\"
CALL AutoBatch_Convert_PDF_into_Word.BAT "c:\pdf\July\" "c:\data\MsWord\July\"
CALL AutoBatch_Convert_PDF_into_Word.BAT "c:\pdf\August\" "c:\data\MsWord\August\"
- The BAT file can be executed by double-clicking on it in the Windows Explorer window.
- Using the Command-Prompt
- The following examples show how to pass alternative folder paths using the Command Prompt. Press Win+R on the keyboard to open the Run window. Type cmd or cmd.exe and press Enter. This will launch the Command window. Navigate to the folder where the BAT file is located and type the following commands.
-
[c:\] AutoBatch_Convert_PDF_into_Word.BAT "c:\data\pdfs\"
- The above command-line will process all files in "c:\data\pdfs" folder instead of "c:\Input Folder" folder that is specified in the original sequence description.
-
[c:\] AutoBatch_Convert_PDF_into_Word.BAT "c:\data\pdfs\" "c:\data\MsWord"
- The above command-line will process all files in "c:\data\pdfs" folder instead of "c:\Input Folder" folder that is specified in the original sequence description and output processed files into "c:\data\MsWord" folder.
- Click here for a list of all step-by-step tutorials available.