Skip to main content

Read PDF Table

AutomatR.DefaultActivities.PDF.ReadPDFTable

The "Read PDF Table" activity in AutomatR is part of the PDF activities package, allowing you to extract tables from PDF documents. This activity simplifies the process of reading and processing tabular data from PDF files in automation workflows.

Properties

NameDescription
Input
Each Page Has HeadersWhen selected, each page containing the table has headers. Boolean variables to indicate whether each page has headers.
File PathThe path of the PDF from which you want to extract the table. String variables containing the file path.
Has HeadersWhen selected, the first row of the table is treated as a header and will not be copied. When not selected, the first row is copied. This option is selected by default. Boolean variables to determine whether the table has headers.
Header FilterHeader of the table you want to read. Use commas to separate multiple headers. String variables containing the header(s).
Header OrientationSelect the direction of headers in the table. Choose 'Horizontal' if columns are present in a row, and 'Vertical' if present in a column.
IndexSpecify the index of the table you want to read. Integer variables containing the table index.
Table in Multiple PagesWhen selected, the table is spread across multiple pages in the PDF. Boolean variables to indicate whether the table spans multiple pages.
Misc
Display NameProvides a customizable name for the activity displayed in the workflow. The display name enhances clarity and organization within the automation project. String variable or argument containing the desired display name.
Optional
DelaySpecifies the wait time (in seconds) before starting the activity. This is useful for handling synchronization issues. Integer variables containing the delay duration (e.g., 5 for 5 seconds).
Output
ResultReturns the DataTable with specified Header Filter/Orientation, Index, Has Headers criteria in the given File Path. DataTable variables to store the extracted table.

How to use:

  1. Drag and drop the "Read PDF Table" activity onto the workflow.
  2. Configure the properties by specifying the file path, table index, header filter, and other relevant details.
  3. Optionally, customize the delay duration.
  4. Execute the workflow to extract the specified table from the PDF.

Example:

Consider an example where the "Read PDF Table" activity is used to extract a table from a PDF file:

Read PDF Table:
Delay: 2
File Path: "C:\Documents\Sample.pdf"
Index: 1
Header Filter: "Name, Age, Address"
Has Headers: true
Header Orientation: Horizontal
Table in Multiple Pages: false
Each Page Has Headers: false
Result: extractedTable

In this example, the activity reads the table with the specified headers ("Name, Age, Address") from the PDF file located at "C:\Documents\Sample.pdf". The extracted table is stored in the DataTable variable "extractedTable" for further processing in the workflow.