Normally EDTRCD or DSPRCD functions are called with fully restricted keys and the Bypass key screen function option set to Y. In some situations this is not possible but you do not want the key screen to be displayed with incomplete keys. This document describes a neat technique to totally bypass the key screen no matter how many keys are supplied.
The technique involves adding a new condition T for Totally bypass key screen to the model's system field *Bypass key screen. The field*Bypass key screen is added to the file *Program data. In the user points EDTRCD USER: Initialize key screen or DSPRCD USER: Load key screen add a *MOVE to set PGM context *Bypass key screen to CND Totally bypass key screen.
Add a new CND Totally bypass key screen value T to 2E system field *Bypass key screen
Add a new Has relation for *Bypass key screen at sequence 999 to file *Program data
This means that the field can be directly used in PGM context within an Action Diagram without the need for EXCUSRSRC
Simple test file
My example EDTRCD on the test file has this parameter…
…and these functions options
In its Action Diagram
Call the program with blank input key parameter
Detail screen with key supplied by function