Choosing Your Options
Use the following instructions to specify your function option choices.
1. Zoom into the file . At the Edit Database Relations panel, type F next to the selected file and press Enter. The Edit Functions panel displays.
2. Zoom into the function . Type Z next to the selected function and press Enter. The Edit Function Details panel displays. Note that you can also display this panel by entering option 2 for the selected function on the Edit Model Object List panel.
3. Press F7 to select options. The Edit Function Options panel displays. You can press F10 to toggle between a display of options available for the selected function and all available options.
The current value of each function option is shown highlighted. Press F5 to view a list of the available standard header/footer functions. You use this display to explicitly assign a standard header/footer function to your function.
4. Select your options. Make your function option selections and press Enter.
The Edit Function Details panel displays like below:
When F5 is taken, it takes us to a screen where we can select a different header and footer
Create
This option specifies whether the function allows you to add new records to the database files on which the function is built.
If Y is specified, the user can add database records with the function. If N is specified, the user cannot add database records with the function.
Change
This option specifies whether the function allows you to change existing records on the database files on which the function is built.
If Y is specified, you can change database records. If N is specified, you cannot change database records.
Delete
This option specifies whether the function allow you to delete existing records from the database files on which the function is built.
If Y is specified, you can delete database records with the function.
Confirm
This option specifies whether the function prompts for confirmation before updating the database files. A confirmation prompt appears at the bottom of the panel on which you can specify yes or no.
If Y is specified, the function prompts the user for confirmation before updating the database files. If N is specified, the function updates the database files without prompting for user confirmation.
Initial Confirm Value This option specifies the initial value that the confirmation prompt is to show.
This may be Y or N. The end user only needs to press Enter to accept the default value for newly created functions as specified by the YCNFVAL model value.
This option only applies if the Confirm option is set to YES. If Y is specified, the initial confirmation prompt value will be Y. If N is specified, the initial confirmation prompt value will be N. If M is specified, the YCNFVAL model value is used.
Bypass Key Screen
This option specifies whether the key screen is to be bypassed (not displayed) before the detail panel if all key fields are supplied as restrictor parameters.
The Bypass Key Screen function option is available only on Edit Record (EDTRCD, EDTRCD2, and EDTRCD3) functions.
If Y is specified and all key fields are non-blank at function execution time, the key screen is bypassed.
If N is specified, the key screen is not bypassed
Reclaim Resources
This option specifies whether the OS/400 Reclaim Resources (RCLRSC) command is to be invoked when the program completes execution.
The command closes down any other programs and/or files that have been called and/or opened by the program, and reallocates their storage.
Reclaim Resources is valid only on external functions (functions implemented as programs in their own right). It is ignored for functions implemented in COBOL since this command is not valid for COBOL programs.
If Y is specified, reclaim resources will be invoked. If N is specified, reclaim resources will not be invoked.
Closedown Program
This option specifies whether the RPG Last Record Indicator is to be set on when the program finishes execution.
If Y is specified, all files are closed and the program is shut down.
If N is specified, all files remain open and a subsequent call will be faster and perform a full program initialization.
Copy Back Messages
This option specifies whether any messages outstanding on the program’s message queue are to be copied to the previous program’s message queue when the program terminates.
The default value for new functions is specified by the YCPYMSG model value.
If Y is specified, messages are copied back to the calling program’s message queue.
If N is specified, messages do not copy back to the calling program’s message queue.
If M is specified, the model default is used. Valid model values for YCPYMSG are *YES and *NO