× 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.



Prototypes can be global or local, I think - I know I have put prototypes to IBM APIs within the D-specs of my own procedures.

I've not tested whether a prototype declared within a procedure is usable outside of that procedure, I suspect not.

But these local prototypes are also at the "top" of something - the procedure in which they are declared. And global - if that's the right word - have to be declared in the D-specs at the top of the main source member.

HTH
Vern

GKern@xxxxxxxxxxxxxxxx wrote:
I've seen a few instances of where the actual code for a prototype (or more than one prototype) is found at the bottom of an RPG source member.

I've often read and learned to code almost all of my prototypes to be accessed via /copy members where the actual code is either a separate module or part of a service program.

The only reason I see for doing this would be to be able to use them like subroutines that could accept parameters where the process is performed only within a single program. But then wouldn't that still lend itself to a /copy book? Or is this just a matter of personal preference that is arbitrary to the application?
Or are there other reasons for coding prototypes at the bottom of an RPG program that I'm unaware of?
Any links to good articles explaining this approach would be appreciated.

Thanks!

Regards, Jerry

Gerald Kern - MIS Project Leader
Lotus Notes/Domino Administrator
IBM Certified RPG IV Developer
The Toledo Clinic, Inc.
4235 Secor Road
Toledo, OH 43623-4299
Phone 419-479-5535
gkern@xxxxxxxxxxxxxxxx


This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized use, disclosure or distribution is prohibited. If you are not the intended recipient, please inform the sender by reply e-mail and destroy this and all copies of this message.

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.