|
A service program is a collection of modules which are in turn collections of procedures. A service program is a packaging technique. Rather than having a program with a bunch of subroutines, we take the subroutines that are used in more than one program (by copying code or using /COPY) and make them procedures. Then we put like procedures in modules. Then we take like modules and put them into service programs. That way when I write my mainline code, I can access all those procedures in the service program just by specifying the procedure name and passing the parameters. When we create a program by binding mainline code with a service program (or two or three or...) it's called bind by reference. And yes, the procedures in a service program can read and write to files. In fact, that's often a good use of service programs. That way you don't have the I/O code in your program - you just call a procedure in a service program to do the I/O and pass back the results. On 1/27/06 05:46 PM, "thomas" <rpgguru2@xxxxxxxxxx> wrote: > does anyone have a simple service program I could look at to start to > understand them. A list of rules of what has to happen would help. Have > figured out that you cannot read and write files in a SERVICE program. Or at > least I think that is right. Thomas Burrows > > _______________________________________________ > Join Excite! - http://www.excite.com > The most personalized portal on the Web!
As an Amazon Associate we earn from qualifying purchases.
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.