|
Good Morning all, I have just started using more ILE type of programming and really have liked what I have seen here on the list lately. My question is this. I have 5 modules compiled into an ILE program. 4 of them are work modules that do a little formatting and validation. The 5th module is the driving program that will be doing a conversion. ( A One time only run ). The 4 validation modules generally are modules that I will be able to use in other conversion programs down the road. The 4 work modules each open a file or two in the course of the processing. Currently I have each of these modules set up as Prototyped Calls (Function calls?) the last parm passed into these modules is an action parm. when this action code is OPEN all the work modules just open the files. When CLOSE, they close the files. Anything else means do the work. I am just not sure if this is how I HAVE to do this but I certainly dont want to Open and Close these files every single time that they are used by the driving program. An example of the simplest module is below. ANy comments ? One thing to remember is that the programming manager does NOT want any service programs created at this time. ( for now anyway :) ) Thanks C Select C When Action = @Open C OPEN OPLDUZ8 *----------------------------------------------------------------------- C When Action = *Blank C Sloc Chain OPLDUZ8 50 C '01':'YN' XLATE *IN50 FOUND C Dow FOUND = YES C Sloc ReadE OPLDUZ8 50 C '01':'YN' XLATE *IN50 FOUND C EndDo C Eval retfield = DzSlin + 1 *----------------------------------------------------------------------- C When Action = @Close C Close OPLDUZ8 C EndSL C RETURN retField P CVMSLOCSEQ E >
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.