|
Thank Barbara, As always...an excellent reply. Charles Wilt iSeries Systems Administrator / Developer Mitsubishi Electric Automotive America ph: 513-573-4343 fax: 513-398-1121 > -----Original Message----- > From: rpg400-l-bounces@xxxxxxxxxxxx > [mailto:rpg400-l-bounces@xxxxxxxxxxxx]On Behalf Of Barbara Morris > Sent: Wednesday, March 23, 2005 8:53 PM > To: rpg400-l@xxxxxxxxxxxx > Subject: Re: Question of the use of HI,LO,EQ indicators > > > "Wilt, Charles" wrote: > > > > Doesn't seem to me like it is a good idea to use the same > indicator in both places. Is this a generally accepted > practice? Does it really work? Is the indicator set on if > there's an error OR if you hit EOF? > > > > Yes, the indicator is set on for either case. The way result > indicators > work is this: they are set to '0' when the operation begins, and then > they're set to '1' during the operation if something happens. So for > the READC, 97 would be set to '0' before the READC started, > and then be > set to '1' if either an error or EOF happened. > > Aside from the fact that using indicators is considered outmoded, I > think it's better to use two indicators right from the start > in case you > later decide you want to use two indicators. Changing code > to use a new > indicator involves a fair amount of checking to see if using it will > affect anything else in the program. (Which is one of the reasons I > prefer using %EOF and %ERROR to indicators.) > > -- > 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-2025 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.