LEADTOOLS OCR (Leadtools.Forms.Ocr assembly)
LEAD Technologies, Inc

EnableLanguages Method






An array of System.String objects containing the name of the languages to be enabled inside the language environment of the character sets used by the IOcrEngine.
Enable the language environment of the character sets used by the IOcrEngine. .NET support WinRT support
Syntax
void EnableLanguages( 
   string[] names
)
'Declaration
 
Sub EnableLanguages( _
   ByVal names() As String _
) 
'Usage
 
Dim instance As IOcrLanguageManager
Dim names() As String
 
instance.EnableLanguages(names)
void EnableLanguages( 
   string[] names
)
function Leadtools.Forms.Ocr.IOcrLanguageManager.EnableLanguages( 
   names 
)
void EnableLanguages( 
   array<String^>^ names
) 

Parameters

names
An array of System.String objects containing the name of the languages to be enabled inside the language environment of the character sets used by the IOcrEngine.
Remarks

The EnableLanguages method is used to define the main part of the language environment of the character sets used by the IOcrEngine.

The default value of the enabled languages is "en" (for English).

Use the GetEnabledLanguages to obtain a list of the languages currently enabled in the language environment.

The language values used throughout the LEADTOOLS OCR toolkit is a string value based on RFC 4646 (Windows Vista and later). The name could be an ISO 639 two-letter lowercase culture code associated with a language or a combination of ISO 630 and ISO 3166 two-letter uppercase subculture code associated with a country or region.

The language environment defines the character set(s) recognized by the OCR engine. For example, if you enable the English and German languages, the German characters (ä, Ä, é, ö, Ö, ü, Ü, ß) will be combined with the English characters to define the set recognized by the engine. The language environment does not perform spell checking however, for that, refer to IOcrSpellCheckManager.

Note: If you call this method when using the LEADTOOLS OCR Advantage Engine, then the user specified settings will be reset because this method will re-initialize the OCR engine using the specified language.

Some of the OCR engines supported by LEADTOOLS do not allow enabling more than one engine at a time. To check if the OCR engine supports more than one language, you must first check the value of the SupportsEnablingMultipleLanguages property. If the value of this property is false, then only the first item in the array passed to EnableLanguages will be used. For example, the LEADTOOLS Advantage OCR engine does not support more than one language at a time.

Note that you can only enable one Asian language at a time if the engine supports Asian languages. For example, the OCR Professional engine supports the following Asian character sets: Japanese (ja), Chinese Simplified (zh-Hans), Chinese Traditional (zh-Hant) and Korean (ko). All these character sets are disabled by default and you can only enable one of them only at any time.

Example
For an example, refer to IOcrLanguageManager.
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

IOcrLanguageManager Interface
IOcrLanguageManager Members
IOcrLanguageManager Interface
GetSupportedLanguages Method
IsLanguageSupported Method
GetEnabledLanguages Method
SupportsEnablingMultipleLanguages Property
IOcrEngine.Startup
IOcrEngine.IsStarted
IOcrEngine.Shutdown
OcrEngineManager Class
OcrEngineType Enumeration
Programming with the LEADTOOLS .NET OCR
Working with OCR Languages
OCR Languages and Spell Checking

 

 


Products | Support | Contact Us | Copyright Notices

© 2006-2012 All Rights Reserved. LEAD Technologies, Inc.

EnableLanguages requires an OCR module license and unlock key. For more information, refer to: Imaging Pro/Document/Medical Features