AS/400 Links Partner with Rochester Institute Contact Us
Training Catalog Free Downloads Privacy / Usage


FREE AS/400, iSeries, and System i / iSeries Downloads
HOME >> FREE AS/400, iSeries, and System i / iSeries Downloads >> RPG - Code Procedure Prototypes with the Procedure



RPG - Code Procedure Prototypes with the Procedure
Author: Craig Pelkie


RPG

 
File
 
Type
 
Description
Minimum
Rel Level
Reading
time
 
Pages
Code Procedure Prototypes with the Procedure

Article

One of the problems with coding procedures is that you need to create both a procedure prototype and a procedure interface. Although the prototype and the interface are almost the same, you have two separate pieces of code to maintain.

This article describes a technique to code the prototype and the interface in the same source member. By using the compiler /DEFINE and /UNDEFINE directives, you can use the right code at the right time in the compile step.

The benefit to you is that you end up with all of your code for the procedure and its usage in one place. Using this technique makes it easier to maintain your procedures when you change the procedure interface.

V4R3+

20 minutes

8