|
You are missing something. Detail SR will execute every cycle but Total will only exeucte when LR is on. Michael Schutte Work 614-492-7419 email michael_schutte@xxxxxxxxxxxx "Bill" <brobins3d@gmail. com> To Sent by: "RPG programming on the AS400 / rpg400-l-bounces@ iSeries" midrange.com <public-rpg400-l-Zwy7GipZuJhWk0Htik 3J/w@xxxxxxxxxxxxxx> cc 04/12/2006 10:47 AM Subject Re: Free Format Equivalent of LR Processing Please respond to RPG programming on the AS400 / iSeries <rpg400-l@midrang e.com> Barbara Morris wrote: > Bill wrote: >> >> Is there a free format equivalent to the following? >> >> /End-Free >> CLR Exsr srLRRtn >> /Free >> > > If you're using the RPG cycle, then you can code like this. Simply > coding IF *INLR in your detail calcs won't work if your total calcs > are being run by reaching LR-on in your primary file. > > C EXSR DETAIL > CLR EXSR TOTAL > /free Unless I'm missing something isn't this the same as my example except the different subroutine name? And you have picked up the distinction I was asking about: LR is turned on due to EOF on the primary file. Sort of an opposite of *Inzsr. I believe I can use Jon's and Michael's simple suggestion if I put the "If *InLR = *On ;" at the end of the detail specifications since the only requirement is to write a record to a file at the end of the program processing. Bill -- This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list To post a message email: RPG400-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/rpg400-l or email: RPG400-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/rpg400-l.
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.