How to Convert PDF to TXT with UiPath

Sep 2, 2024·5 Minutes Read

In this section, we will see how to convert PDF to a text document, and how to use this feature.

Configure PDF.co Scope

Before you start using PDF.co services, please configure PDF.co Scope providing the best way to use your PDF.co API key. Check out the figure below for more information.

Scope

PDF Merge, PDF Split, PDF Filler, PDF to XML are other PDF.co activities that can be done within PDF.co Scope. PDF.co scope includes PDF.co API key to be used within PDF.co Scope. The API key is necessary for every function.

PDF.co API key is used for authentication of the PDF.co request. Please get it as soon as you sign up.

PDF to TEXT with UiPath

I have already created the PDF.co scope here. Now drag and drop the PDF to text file converter. If we review, this activity mainly contains the parameters for the PDF file. We can either provide the direct keyword of the PDF file or we can provide the absolute path of that PDF. Parameters and expected destination file path.

After PDF to text conversion is completed, if you want to save the output text file to some physical file, we can provide the path here. If we want to restrict extraction from a particular region, then we can provide the coordinates here in the string format. If you want to extract only from a certain number of pages, we can provide the pages in the pages field. If the input PDF is password-protected, we can provide the password in the password field.

Here are the other properties. For example, if we want to utilize output text, then we can create a variable for this output text. The result file URL provides the URL of the resulting file.

Let’s see this in practice. I already have one PDF file containing an invoice and take the full path of this PDF and provide the path here. Specify the output of the destination file, so in the output, the folder makes it like result.txt.

We want to convert PDF to text to be stored in this location and create one variable for these output text. I am right-clicking and creating the variable as extracted text and we are creating the connecting activity on the message box.

UiPath PDF to TXT

In the message box, we are providing that variable. Now run this and once the execution is completed, we shall see the alert containing the extracted text and all the contents are different in the message box.

UiPath Convert PDF to Text

Review the contents of this text file. So it contains invoice data. I hope this is clear to you on how to utilize this PDF to text activity.

PDF.co and UiPath Integration

To start, please use the button below:

Visit the UiPath Marketplace

or

Download the Latest UiPath Plugin for PDF.co

Need help or support? Please contact us.

Video Guide

Related Tutorials

See Related Tutorials