Looking for C# PDF to Text example FineReader 12

  • 821 Views
  • Last Post 27 July 2018
JimM posted this 26 July 2018

Hi there,

I'm trying to find a code sample for a C# PDF to text file extraction.  Anyone know where to find this?  I've looked through the sample projects, but none of them appear to do this.  

Antonina Nikolaeva posted this 27 July 2018

The “Hello” sample project could be used for text extraction from PDF. You should just pass the path to your input PDF file into the AddImageFile method of the FRDocument object. Please note the program exports the results in RTF and searchable PDF formats. If you need another format, you should change the value of the Format parameter in the Export method call. For example, export to TXT Unicode would look like this:

document.Export(@“path\to\target\file”, FREngine.FileExportFormatEnum.FEF_TextUnicodeDefaults, null);

Please see the Developer’s Help article Help→ API Reference→ Document-Related Objects→ Document Organization→ FRDocument→ Export Method of the FRDocument Object  for details. All C# code samples can be found in the Visual CS subfolder of the Samples folder in the FineReader Engine data folder: %ProgramData%\ABBYY\SDK\12\FineReader Engine

Close