ByteScout PDF Extractor SDK - C# - SearchablePDFMaker Progress Indication - ByteScout

ByteScout PDF Extractor SDK – C# – SearchablePDFMaker Progress Indication

  • Home
  • /
  • Articles
  • /
  • ByteScout PDF Extractor SDK – C# – SearchablePDFMaker Progress Indication

searchablepdfmaker progress indication in C# with ByteScout PDF Extractor SDK

How To: tutorial on searchablepdfmaker progress indication in C#

The coding tutorials are designed to help you test the features without need to write your own code. ByteScout PDF Extractor SDK helps with searchablepdfmaker progress indication in C#. ByteScout PDF Extractor SDK is the SDK is designed to help developers with pdf tables and pdf data extraction from unstructured documents like pdf, tiff, scans, images, scanned and electronic forms. The library is powered by OCR, computer vision and AI to provide unique functionality like table detection, automatic table structure extraction, data restoration, data restructuring and reconstruction. Supports PDF, TIFF, PNG, JPG images as input and can output CSV, XML, JSON formatted data. Includes full set of utilities like pdf splitter, pdf merger, searchable pdf maker and other utilities.

The SDK samples like this one below explain how to quickly make your application do searchablepdfmaker progress indication in C# with the help of ByteScout PDF Extractor SDK. This C# sample code should be copied and pasted into your application’s code editor. Then just compile and run it to see how it works. Enjoy writing a code with ready-to-use sample C# codes to add searchablepdfmaker progress indication functions using ByteScout PDF Extractor SDK in C#.

Our website provides free trial version of ByteScout PDF Extractor SDK. It comes along with all these source code samples with the goal to help you with your C# application implementation.

Try ByteScout PDF Extractor SDK today:  60 Day Free Trial (on-premise) or  Web API (on-demand version)

using System; using System.Diagnostics; using Bytescout.PDFExtractor; namespace SearchablePDFMakerProgressChangedEvent { class Program { static void Main(string[] args) { try { using (var searchablePDFMaker = new SearchablePDFMaker("demo", "demo")) { // Load sample PDF document searchablePDFMaker.LoadDocumentFromFile("sample_ocr.pdf"); // Extractor Progress event Console.WriteLine("Searchable PDF making in progress: \n"); searchablePDFMaker.ProgressChanged += SearchablePDF_ProgressChanged; // Set the location of OCR language data files searchablePDFMaker.OCRLanguageDataFolder = @"c:\Program Files\Bytescout PDF Extractor SDK\ocrdata\"; // Set OCR language searchablePDFMaker.OCRLanguage = "eng"; // "eng" for english, "deu" for German, "fra" for French, "spa" for Spanish etc - according to files in "ocrdata" folder // Find more language files at // Set PDF document rendering resolution searchablePDFMaker.OCRResolution = 300; // Save extracted text to file searchablePDFMaker.MakePDFSearchable("output.pdf"); // Open result document in default associated application (for demo purpose) ProcessStartInfo processStartInfo = new ProcessStartInfo("output.pdf"); processStartInfo.UseShellExecute = true; Process.Start(processStartInfo); } } catch (Exception ex) { Console.WriteLine(ex.Message); } Console.WriteLine("\n\n Press enter key to exit..."); Console.ReadLine(); } /// <summary> /// Handle progress change event /// </summary> private static void SearchablePDF_ProgressChanged(object sender, OngoingOperation ongoingOperation, double progress, ref bool cancel) { drawTextProgressBar(Convert.ToInt32(progress), 100); } /// <summary> /// Display progress bar /// </summary> private static void drawTextProgressBar(int progress, int total) { //draw empty progress bar Console.CursorLeft = 0; Console.Write("["); //start Console.CursorLeft = 32; Console.Write("]"); //end Console.CursorLeft = 1; float onechunk = 30.0f / total; //draw filled part int position = 1; for (int i = 0; i < onechunk * progress; i++) { Console.BackgroundColor = ConsoleColor.Green; Console.CursorLeft = position++; Console.Write(" "); } //draw unfilled part for (int i = position; i <= 31; i++) { Console.BackgroundColor = ConsoleColor.Gray; Console.CursorLeft = position++; Console.Write(" "); } //draw totals Console.CursorLeft = 35; Console.BackgroundColor = ConsoleColor.Black; Console.Write(progress.ToString() + " of " + total.ToString() + " "); //blanks at the end remove any excess } } }

Try ByteScout PDF Extractor SDK today:  60 Day Free Trial (on-premise) or  Web API (on-demand version)



Get 60 Day Free Trial or Visit ByteScout PDF Extractor SDK Home Page

Explore ByteScout PDF Extractor SDK Documentation

Get ByteScout PDF Extractor SDK Free Training


Get Your Free API Key

Explore Web API Documentation