←Select platform

OcrEngine Property

Summary

Optional OCR engine instance to use when extracting text.

Syntax
C#
VB
C++
Java
public IOcrEngine OcrEngine { get; set; } 
Public Property OcrEngine() As IOcrEngine 
   Get 
   Set 
public:  
   property IOcrEngine^ OcrEngine 
   { 
      IOcrEngine^ get() 
      void set(IOcrEngine^ value) 
   } 
public OcrEngine getOcrEngine() 
public void setOcrEngine(OcrEngine value) 

Property Value

The optional OCR engine instance to use when extracting text. Default value is null.

Remarks

This property is not used if the value of TextExtractionMode is DocumentTextExtractionMode.SvgOnly.

The text of the document can be extracted using OCR technologies, in this mode, a valid IOcrEngine instance must be initialized (created and started) and set in the OcrEngine property before DocumentPage.GetText is called.

OcrEngine can be setup with any extra options from outside (such as enable languages, spell checker, accuracy tradeoffs, etc.). The Document class will use the engine as is.

The Document object will not delete the value of OcrEngine when it is disposed. IOcrEngine is thread-safe by nature and the same instance can be set into multiple Document instances and used at the same time.

For more information, refer to Parsing Text with the Document Library.

Note that setting this property to a value will update the same value in each child document.

Example

For an example, refer to DocumentText.

Requirements
Target Platforms
Help Version 21.0.2021.7.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Document Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.