ByteScout PDF Suite - C# - Extract Table Structure from PDF with PDF Extractor SDK - ByteScout

ByteScout PDF Suite – C# – Extract Table Structure from PDF with PDF Extractor SDK

  • Home
  • /
  • Articles
  • /
  • ByteScout PDF Suite – C# – Extract Table Structure from PDF with PDF Extractor SDK

How to extract table structure from PDF with PDF extractor SDK in C# with ByteScout PDF Suite

Continuous learning is a crucial part of computer science and this tutorial shows how to extract table structure from PDF with PDF extractor SDK in C#

This sample source code below will display you how to extract table structure from PDF with PDF extractor SDK in C#. ByteScout PDF Suite is the bundle that provides six different SDK libraries to work with PDF from generating rich PDF reports to extracting data from PDF documents and converting them to HTML. This bundle includes PDF (Generator) SDK, PDF Renderer SDK, PDF Extractor SDK, PDF to HTML SDK, PDF Viewer SDK and PDF Generator SDK for Javascript and you can use it to extract table structure from PDF with PDF extractor SDK with C#.

Want to quickly learn? This fast application programming interfaces of ByteScout PDF Suite for C# plus the guidelines and the code below will help you quickly learn how to extract table structure from PDF with PDF extractor SDK. Just copy and paste the code into your C# application’s code and follow the instructions. Enjoy writing a code with ready-to-use sample codes in C#.

The trial version of ByteScout PDF Suite can be downloaded for free from our website. It also includes source code samples for C# and other programming languages.

On-demand (REST Web API) version:
 Web API (on-demand version)

On-premise offline SDK for Windows:
 60 Day Free Trial (on-premise)

Program.cs
      
using Bytescout.PDFExtractor; using System.Diagnostics; using System; namespace TableStructure { class Program { static void Main(string[] args) { // Create Bytescout.PDFExtractor.StructuredExtractor instance StructuredExtractor extractor = new StructuredExtractor(); extractor.RegistrationName = "demo"; extractor.RegistrationKey = "demo"; // Load sample PDF document extractor.LoadDocumentFromFile(@".\sample3.pdf"); for (int pageIndex = 0; pageIndex < extractor.GetPageCount(); pageIndex++) { Console.WriteLine("Starting extraction from page #" + pageIndex); Console.WriteLine(); extractor.PrepareStructure(pageIndex); int rowCount = extractor.GetRowCount(pageIndex); for (int row = 0; row < rowCount; row++) { int columnCount = extractor.GetColumnCount(pageIndex, row); for (int col = 0; col < columnCount; col++) { Console.WriteLine(extractor.GetCellValue(pageIndex, row, col)); } } } // Cleanup extractor.Dispose(); Console.WriteLine(); Console.WriteLine("Press any key.."); Console.ReadKey(); } } }

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

VIDEO

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Tutorials:

prev
next