How to use OCR feature within Test Complete to find strings within screen image?
I have an IBM mainframe based application under CICS and I want to be able to select numeric data from within the 24 row by 80 column application area of a standard 3270 Emulation screen. I am using Rocket's software emulation software to connect to the IBM Mainframe. The process name for that emulation software is BZMD.EXE.
In the Test Complete Help document, there is a discussion of using Test Complete's OCR feature to find text within an image. Due to the nature of the 3270 emulation screen, Test Complete cannot identify individual numeric data from within the 24 row by 80 column application area. All Test Complete can do is get an IMAGE of that application area.
Consequently, I want to use the OCR feature to find recognizable text within that 24 row by 80 column application area.
In the Test Complete Help documentation, there is a one-line command to capture the Active Window image and then let the OCR feature find all recognizable text in that image. Since the 3270 emulation screen just contains alphanumeric characters in the 24 row by 80 column application area, this should be EASY to do. Here is that command:
Log.Message(OCR.CreateObject(Sys.Desktop.ActiveWindow()).GetText());
Since the name of the 3270 emulation process is BZMD.EXE, I have modified the above command as follows (Note that I got the window name by using the Object Explorer feature of Test Complete):
Log.Message(OCR.CreateObject(Aliases.bzmd.wndBlueZoneMainframeDisplayS1.SessionDisplay).GetText());
I have included the modified line within a Run Code Snippet in my Test Complete testcase. Unfortunately, when I run this testcase, the OCR feature does not recognize ANY text.in that window. All I get is a message in my testcase's log that looks like binary or image data of some type.
Am I NOT specifying the Log.Message.... command correctly within the Run Code Snippet?
Any help would be appreciated.