Welcome Guest! To enable all features, please Login or Register.

Notification

Icon
Error

Options
View
Last Go to last post Unread Go to first unread post
#1 Posted : Friday, September 1, 2017 11:15:08 AM(UTC)

Nick  
Nick

Groups: Registered, Tech Support, Administrators
Posts: 163

Was thanked: 9 time(s) in 9 post(s)

The LEADTOOLS Document Converter can convert document formats to other document formats, such as MS Word .doc files to Adobe .pdf files. However, it can also be used to convert raster formats such as .PNG and multi-page TIFF files to document formats as well. This does require Optical Character Recognition to be applied to the input images.

A DocumentConverter can have an OCR engine assigned to it by using the DocumentConverter.SetOcrEngineInstance() call. The call accepts two parameters:

IOcrEngine instance -- a started OCR engine. A value of null can also be passed to unassign a previously set OCR engine.
bool dispose -- a boolean value that determines whether the DocumentConverter should dispose of the OCR engine along with the converter. If this value is false, it will be necessary for the engine to be disposed normally in code.

https://www.leadtools.com/help/leadtools/v19m/dh/doxc/documentconverter-setocrengineinstance.html

Code:

         DocumentConverter converter = new DocumentConverter();
         IOcrEngine engine = OcrEngineManager.CreateEngine(OcrEngineType.Advantage, false);

         engine.Startup(null, null, null, null);

         converter.SetOcrEngineInstance(engine, false);


Once this call has been made, the assigned instance can be accessed via the DocumentConverter.OcrEngineInstance property to have its settings adjusted. Note that attempting to convert raster formats without an OCR engine assigned will cause an exception. From here, the DocumentConverter can be used to process jobs.
Nick Crook
Developer Support Engineer
LEAD Technologies, Inc.
LEAD Logo
 

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2024, Yet Another Forum.NET
This page was generated in 0.040 seconds.