About this tutorial

Objectives

In this tutorial, you will learn about screen signatures, how to identify and name screens, and define names for fields.

Prerequisites

Getting Started tutorial

Before attempting this tutorial please complete all steps in the Extension Tutorial 00 - Getting Started - v4.2.0

Outline

Screen identification – screens created without DDS

Screen identification – screens created using DDS

About screen signatures

Screen identification – screens created without DDS

Use your desktop shortcut to open the aXes Home Page.

Click on the Developer tool link in the top bar.

When requested, enter the aXes developer username and password.

image002

The shipped defaults are,

User Name: dev

Password: dev

You should change these default values.

On the Projects List Page, find your project in the projects list and click the matching developer button on the right.

A 5250 Terminal Session sign on prompt should appear next:

Image

Sign on with an IBM i user profile and password that displays the Main Menu.

When identifying 5250 screens for subsequent use in an aXes-Cloud environment ensure you are executing them in the same way that your end users will.

Refer to the "If You Use aXes-eXtensions with aXes-Cloud" section in the Best Practices tutorial for an explanation of the reasons this is important.Extension Tutorial 08 - Best Practices

The next screen should look like this:

Image

Click on the menu icon on the top left corner of the page, and select screens.

Image

On the left side is a tab titled Screens - this is used to identify 5250 screens and the fields on them.

On the right side is a 5250 session you can use just like any normal 5250 session.

Image

Warning: You should only ever use aXes developer 5250 sessions for aXes development work. For other development work, like writing RPG programs, use normal user aXes 5250 sessions. You should never assess the performance of your application using an aXes developer session.

You are now going to identify the Main Menu screen and assign a name to the field on the screen where commands are typed in.

First, click the Suggest button (the one with a question mark) on the Screens tab - aXes will examine the screen and suggest a name and a description.If you are happy with the name suggested click on the save icon at the top of the page.

Next, lock the screen for design by using the Edit Screen button. Always lock the screen for design before customising it.

Change the screen Name to MAINMENU.

Naming Conventions

Choose names for screens and screen elements like you would name a variable in a programming language.

Use only letters of the English alphabet, the numbers 0 to 9 and _ (underscore).

Do not use imbedded blanks in names.

Names are case sensitive.

Then, click on the screen title on the 5250 screen to select it (e.g. IBM i Main Menu, System i Main Menu or i5/OS Main Menu). This should highlight the field in the Screens tab on the left.

Check the box beside the field.

Change the screen Description to IBM i Main Menu.

Click the Save button to save the definition of the screen you have called MAIN.

To check that aXes now identifies the MAINMENU screen correctly, display a different 5250 screen by entering the IBM i command WRKJOB.

You should see the Possible Matches list on the Screens tab change to say <new definition> indicating that the Work Job screen currently has no name.

Return to the main menu and you should see the Possible Matches list change to indicate that this screen name is MAIN.

With the MAIN screen displayed, select the field where commands are entered by clicking on it. This should automatically select the field on the Screens tab and scroll down to it.

Type in the name CommandLine for the field.

Your Screens tab should now look like this:

Image

Click the Save button again to (re)save the definition of the screen called MAINMENU.

Click on the button Exit Screen Edit to preview your screen.

Hint: Before starting a real project you should create a naming standard for screens and fields.

You have now completed these tasks:

1. Identified the Main Menu screen and assigned it the name MAIN.

2. Named the command input field as CommandLine.

The Output Field Dilemma

When a field is not really a field - it's just a bit of output text

Usually, output fields are correctly recognized as starting at the beginning of the field. This means that when named, they continue to be recognized, no matter what value they contain.

But in one special case, when the record format does not define the fields, (as in for example the "fields" on the WRKSYSSTS screen), aXes works out the field start position based on the field contents. For right-adjusted numeric fields, this means that when the screen is redisplayed with a value with more digits, the start position of the "field" changes, and since aXes identifies fields by their start position, it does not recognize the text as belonging to the same field.

You should be aware of this special case when naming fields:

Image

Screen identification - Screens created using DDS

Next you are going to identify two application screens created by normal DDS.

To do this start the shipped aXes demo system from a command line by entering the commands:

ADDLIBLE AXESDEMO

CALL XHRRPGTRN

The resulting 5250 screen should look something like this:

Image

On the Screens tab, click the Suggest Button.

Change the suggested screen name to XHRRPGTRN_Select

Remember to choose names for screens and screen elements like you would name a variable in a programming language.

Use only letters of the English alphabet, numbers 0 to 9 and _ (underscore).

Do not use imbedded blanks in names.

Names are case sensitive.

Click the Save button.

You have now assigned the name XHRRPGTRN_Select to this particular 5250 screen.

Next, enter an X beside an employee and press the Enter key to display the employee information.

The resulting 5250 screen should look something like this:

Image

Check that your Screens tab says this is a new (unnamed) 5250 screen.

On the Screens tab, click the Suggest button.

Change the suggested screen name to XHRRPGTRN_Maint

Click the Save button.

You have now assigned the name XHRRPGTRN_Maint to this particular 5250 screen.

Now, double check that aXes correctly identifies the named screens.

To do this, return to the IBM i main menu, then call program XHRRPGTRN again. Make sure the selection screen and the details screen are correctly identified on the aXes Screens tab as you navigate between the screens.

You have completed this tutorial and are ready to start the next tutorial.

See also

To know more about screen signature, see Screen signatures and the concept of a 5250 Screen