× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I should have been clearer, but you got the gist of it. I haven't yet tackled the modules-service programs-programs division, yet. But, when I do get to that step I'll remember that P specs are for the sub procedures. That is the way I have been coding them. It was the "main" procedure coding that left me scratching my head.

Again, thanks for the patient and complete responses.

Pete

Scott Klement wrote:
Pete Helgren wrote:
So, if I understand you correctly, I will always have a "main" procedure that will be coded with D specs that has both a procedure prototype

Shrug.. I can't answer THAT. I write TONS of code that doesn't have a main procedure. You can eliminate the main procedure from an RPG module by putting the NOMAIN keyword on the H-spec.

However, a *PGM object has to have at least one main procedure to be called by the CALL command. But, I build a program out of 10 modules, only one of the ten has to have a main procedure. Furthermore, service programs do not have to have a main procedure at all -- and in fact, most service programs (in my experience) do not have main procedures.

I guess the important part is that you understand the difference between a main procedure and a subprocedure, and you understand that P-specs are for subprocedures, not main ones.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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

This mailing list archive is Copyright 1997-2024 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 [javascript protected email address].

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