cancel
Showing results for 
Search instead for 
Did you mean: 

Extracting Text from iseries (mainframe-green screen) applications

SOLVED
Highlighted
Occasional Contributor

Extracting Text from iseries (mainframe-green screen) applications

Hello 

 

Has anyone have experience in extracting specific text from Mainframe applications. I have already enabled Text Recognition through which am able to automate entering values. But am struggling to extract the values for specific fields displayed in the screen. The whole screen is taken up as an object.

 

Any thoughts on this will really help. 

 

Thanks 

S.Geethanjali

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Occasional Contributor

Re: Extracting Text from iseries (mainframe-green screen) applications

hi  

 

I have resolved this issue. 

 

I tried OCR, but that didnot help me much because it provided me a chunk of data from the screen and I felt it really difficult to extract the specific data. Not sure if it had more effective ways 

 

The solution which worked out for me was 

Used text recognition in order to recognise the AS400 window. 

Used key strokes for keying in the data

used the feature ( Edit - Send to scratch pad) option in AS400 after which I recogonised that scratch pad window to get the details displayed. Since the positions and length are fixed I used relative positioning and length to extract the data. 

Tried for couple of screens, it has worked.Have to see how it progresses. 

 

View solution in original post

7 REPLIES 7
Highlighted
Community Leader

Re: Extracting Text from iseries (mainframe-green screen) applications

You must do OCR on specific region and specify to the ocr routine the font used.

Size of as400 screen is fixed and fields position too.

Use it to make template of each screen to manipulate.

Un sourire et ça repart

Highlighted
Occasional Contributor

Re: Extracting Text from iseries (mainframe-green screen) applications

Hello, Thanks very much for your reply.. are there methods to extract text with the give rowid and columnid from the mainframe screen ?

 

I don't have Intelligent Quality add in installed. 

Is there any other way to do it or do we only require OCR to be enabled ?

Thanks very much

 

Thanks 

S.Geethanjali

Highlighted
Community Leader

Re: Extracting Text from iseries (mainframe-green screen) applications

Without Intelligent Quality you can still have OCR

Read more on this article (the deprecated one)

https://support.smartbear.com/testcomplete/docs/testing-with/deprecated/ocr/required-plug-ins.html

But since the new ocr appeared it seems that the old OCR was lowered in quailty (this is my personal feeling) so it doesn't works as well as in the past.

 

But you can also use regions checkpoint (so using image fragment).

Here as the interface is very stable and pixels colors are well defined it could be a good alternative.

So build a library of Regions corresponding to your main fields ...

Or even more touchy but sexier, built on the fly the image fragment from the desired text.. -> Create a bitmap object with background color the same as your terminal background color, use Win32Api to write on this bitmap with the same font/color as the terminal .. and you'll have way to avoid building a large library of Regions ...

 

@sonya_m  This could be a very intersting technical challenge

function CreateRegionFromString(MyString, FontObject, Background (color or other bitmap)) {

  return a bitmap that can be directly used with Region.Check

}

Un sourire et ça repart

Highlighted
Occasional Contributor

Re: Extracting Text from iseries (mainframe-green screen) applications

This is interesting .. I might have to experiment a bit . 

 

While I try to enable the old OCR - it mentions that it is conflicting with some other addins.. So not sure if installing this will create some issues to any other addins. - Any thoughts here ?

 

I was trying to use region check point . but since it compares pixel by pixel, would I be able to compare the text displayed ? - I have not tried it but since I was skeptical i didnot proceed.

 

Other option of yours is very interesting and challenging too.. Let me see if I can try that out

 

Thanks very much for your thoughts on this issue. 

 

Thanks 

S.Geethanjali

Highlighted
Community Manager

Re: Extracting Text from iseries (mainframe-green screen) applications

@BenoitB , thank you for the challenge idea! We'll consider adding it🙂

 

@Geethanjali please keep sharing your progress with us on this one!


Sonya Mihaljova
Community and Education Specialist

Learn SmartBear products in a fun and easy way and prove your knowledge!
>>Participate in the TechCorner Challenge today
Highlighted
Occasional Contributor

Re: Extracting Text from iseries (mainframe-green screen) applications

hi  

 

I have resolved this issue. 

 

I tried OCR, but that didnot help me much because it provided me a chunk of data from the screen and I felt it really difficult to extract the specific data. Not sure if it had more effective ways 

 

The solution which worked out for me was 

Used text recognition in order to recognise the AS400 window. 

Used key strokes for keying in the data

used the feature ( Edit - Send to scratch pad) option in AS400 after which I recogonised that scratch pad window to get the details displayed. Since the positions and length are fixed I used relative positioning and length to extract the data. 

Tried for couple of screens, it has worked.Have to see how it progresses. 

 

View solution in original post

Highlighted
Community Manager

Re: Extracting Text from iseries (mainframe-green screen) applications

@Geethanjali Thank you for sharing your approach!


Sonya Mihaljova
Community and Education Specialist

Learn SmartBear products in a fun and easy way and prove your knowledge!
>>Participate in the TechCorner Challenge today
New Here?
Join us and watch the welcome video:
Announcements
Join TechCorner Challenge!
Want a fun and easy way to learn TestComplete? Try solving weekly TechCorner challenges and get into the Leaderboard!

Challenge Status

Changing options from outside of TestComplete

Participate!

How to execute remote test and obtain results via Test Runner REST API

Participate!

Comparing content of HTML table with Excel file data

Participate!

Compare HTML table with Excel file and correct data in the file

Participate!