Hmm....  Unless it is a service program, how can you exec a
subprocedures without going thru main procedure.
When you take two or more modules and bind them together to make a 
program, each module has it's own main procedure, and subprocedures.  You 
can then call the subprocedures without going through the main procedure.
Whether it's a service program or not has no impact on this.

My understanding is that module is not execable.  You use it to create a
callable program or service program.

Yes, but programs and service programs (which are executable) are built 
from modules.  The RPG cycle (the part that *INLR affects) is a per-module 
thing, not a per-program thing.  You can make a program out of 500 
different modules if you want to, and therefore your program would have 
500 different *INLR indicators, and 500 different main procedures.
The point is that the LR indicator operates at the per-module level. 
Whether you take these modules and make programs from them or whatever you 
use them to make service programs doesn't matter.
If it is a callable program, it will have to go thru the main procedure
to fire up the program.  When the program is done, set on LR and return
should close the file.  Shouldn't it?
If the file is opened in the same module, yes.


Note:  The company I work for do not allow create program using module.
==> Not familiar enough to be certain.
You can't create a ILE program without creating it from modules. It's not 
possible.





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact copyright@midrange.com.

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.