4.2.8 Function Control Table Concepts

The function control table is a table that controls how and when the various functions within a process are used and the ordering sequence that the functions should be in when displayed on the process menu.

Every function defined in a process has an entry in the function control table. It is automatically created with default values when the function is created and cannot be removed. However it can be changed from its default values to suit the specific requirements of a user application of LANSA.

Every entry in the function control table contains the following elements:

The function control table associated with a process called EXAMPLE which has 3 functions called FUNC1, FUNC2 and FUNC3 would look like this before any user changes were made to it:

Function Name

Description

Display on Menu

Default Next Function

Allowable next functions

FUNC1

Function 1

YES

MENU

*ANY

FUNC2

Function 2

YES

MENU

*ANY

FUNC3

Function 3

YES

MENU

*ANY

 

In the section that dealt with "Creating a new function" a list of "reserved" function names was mentioned. This was a list of function names that were "reserved" for internal LANSA use and could not be used as valid user created function names:

Name

Reserved meaning / description

MENU

Display process main menu

EXIT

Exit from LANSA

HELP

Display process HELP text

SELECT

Select next function from list of allowable function

EOJ

End all batch processing

RETRN

Return control to calling process or function

ERROR

Abort process with an error

*ANY

Any function name

 

Taking the function control table for process EXAMPLE and the list of reserved function names together it can be seen that what the table is actually specifying to LANSA is:

When using FUNC1 the most common (or default) next function is to display the process's main menu.

After using FUNC1 you can go to any other function in the process.

However, if the function control table for process EXAMPLE was changed as follows:

Function Name

Description

Display on Menu

Default Next Function

Allowable next functions

FUNC1

Function 1

YES

FUNC2

FUNC2

FUNC2

Function 2

NO

FUNC3

FUNC3 FUNC1 SELECT

FUNC3

Function 3

NO

MENU

MENU

 

The following conditions now apply:

Hopefully this example illustrates the main purpose of the function control table which is to provide a "path" through the functions.

The path may be "enforced" (e.g.: From FUNC1 you must go to FUNC2) or it may be "suggested" (e.g.: from FUNC2 you would normally go to FUNC3, but can go to FUNC1 if desired).

If the partition is a multilingual partition, you can specify language-specific descriptions by selecting the appropriate language in the  Language list in this dialog box.

Also See

Function Control Table in the Technical Reference Guide

Functions Tab in the Visual LANSA User Guide.