Earlier versions of TestComplete (prior to version 12.60) used the built-in optical character recognition library. In version 12.60, it was removed from TestComplete and has been replaced with a new optical character recognition engine featuring Google Vision API.
If you have tests that use the deprecated optical character recognition library, you can do one of the following:
-
Modify your tests to use the new OCR feature (recommended).
– or –
-
Continue using the deprecated OCR library (not recommended).
If you have TestComplete 12.60 and want to use the deprecated OCR library with that TestComplete version, please contact our Customer Care team. If you have TestComplete 14.0 (and later), you need to install the deprecated OCR modules manually.
Modify your tests to use new OCR (recommended)
-
If you do not use source control, we recommend that you make a backup copy of your project.
If you use source control, we recommend that you create a new branch in your repository for your project.
-
Open your test project in TestComplete.
-
Update your tests to use the new optical character recognition engine using the recommendations below:
Task Legacy OCR New OCR Recognizing text in an on-screen object OCR.CreateObject
OCR.Recognize
Getting all the text within the specified onscreen object OCR.CreateObject.GetText
OCR.Recognize.FullText
Getting a region that contains the specified text OCR.CreateObject.GetText
OCR.Recognize.Block
orOCR.Recognize.BlockByText
Getting the coordinates of the rectangle that contains the specified text OCR.CreateObject.FindRectByText.Found…
propertiesProperties of the OCR.Recognize.Block.Bounds
orOCR.Recognize.BlockByText.Bounds
objectsSimulating user actions on an area containing the specified text Calculating coordinates of the rectangle that contains the needed text and simulating coordinate-based actions in that rectangle Methods of the OCR.Recognize.Block
orOCR.Recognize.BlockByText
objectsSpecifying recognition options OCR.CreateObject.CreateOptions
The recognition service will detect your text language automatically. -
Save the changes to your project.