GetRecognizedWord Method of the Text Object

This method provides access to the specified recognition variant of the selected word in the text. Using this method you can view the main recognition variant of the word (which is used in the resulting text) and all other variants.

Important! This method is part of recognition variants API. It is available only if you enable recognition variants saving by a call to the EnableRecognitionVariants method of the Engine object before recognition.

Note: The API working with recognition variants is not available for recognizing handprinted texts.

Syntax

Visual Basic .NET

Sub GetRecognizedWord( _
  wordIndex As Integer, _
  variantIndex As Integer, _
  result As RecognizedWordInfo _
)
    

C++

HRESULT GetRecognizedWord(
   int                  wordIndex,
   int                  variantIndex,
   IRecognizedWordInfo* result
);
    

Parameters

wordIndex
[in] Specifies the index of the word in the text. It must be in range from 0 to the value of IText::RecognizedWordsCount minus 1.
variantIndex
[in] Specifies the index of the recognition variant of the word in the internal collection of word recognition variants. The number of elements in the collection you can obtain using the IRecognizedWordInfo::RecognitionVariantsCount property of any variant of the word recognition. Recognition variants are ranked from the best to the worst. The value of the parameter can be -1, which means that the main recognition variant should be returned.
result
[in] Refers to the RecognizedWordInfo object. This object properties are initialized with values corresponding to parameters of the word variant. A valid object should be passed as this parameter.

Return values

This function has no specific return values. It returns the standard return values of ABBYY FlexiCapture SDK functions.

See also

Text

15.08.2023 13:19:30

Usage of Cookies. In order to optimize the website functionality and improve your online experience ABBYY uses cookies. You agree to the usage of cookies when you continue using this site. Further details can be found in our Privacy Notice.