|
The Indicatory Data Structure, INDDS, does this for you now. It also isolates the indicators so that you can reuse them (not that you need to). FCUSTINQ CF E WORKSTN INDDS(MyDspIndy) D MyDspIndy DS D SubfileDSP 1N Overlay(MyDspIndy:21) Etc. -Bob Cozzi www.RPGxTools.com If everything is under control, you are going too slow. - Mario Andretti -----Original Message----- From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Alan Campin Sent: Thursday, June 23, 2005 11:50 AM To: RPG programming on the AS400 / iSeries Subject: RE: RPG Free Format question Boy, isn't that the true. I have said all along, it is the people working on the machine that will kill the AS/400. People continuing to live in the past. As far as using indicators, the only time left is on display files. I do the following to eliminate as much as I can. *- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - * Map indicators to field. d ptrIndicators s * Inz(%Addr(*In)) d dsIndicators ds Based(ptrIndicators) d GenericIN01 Like(StdLgl) d GenericIN02 Like(StdLgl) d GenericIN03 Like(StdLgl) d GenericIN04 Like(StdLgl) etc.. Though 99. This is copy block so actual code. /copy *libl/qsrcf,CB_MAP_IND d DisplaySubfileControl... d Like(StdLgl) d Overlay(GenericIN26) d DisplaySubfile... d Like(StdLgl) d Overlay(GenericIN27) d ClearSubfile... d Like(StdLgl) d Overlay(GenericIN28) d DisplaySubfileEnd... d Like(StdLgl) d Overlay(GenericIN29) d SubfileNextChanged... d Like(StdLgl) d Overlay(GenericIN86) d PositionToChanged... d Like(StdLgl) d Overlay(GenericIN89) d DisplaySubfileEndOnSubfileMessageQueue... d Like(StdLgl) d Overlay(GenericIn95) Do you end up with: INT_LoadSubfile(); DoU 0 = 1; DisplaySubfileMessages(); If RecordsLoadedInSubFile > 0; DisplaySubFile = cTrue; Else; DisplaySubfile = cFalse; Write SF_BLANK; EndIf; DisplaySubFileControl = cTrue; etc... Unfortunetely, you still need to turn off multiple indicators for error indicators. Just occurred to me that I could put a overlay structure into the copy block and then be able to just do a Clear ErrorIndicators; Cool. -----Original Message----- From: Bob Cozzi [mailto:cozzi@xxxxxxxxx] Sent: Wednesday, June 22, 2005 1:09 PM To: 'RPG programming on the AS400 / iSeries' Subject: RE: RPG Free Format question No wonder our programming jobs are vanishing. Oh well. -Bob Cozzi www.RPGxTools.com If everything is under control, you are going too slow. - Mario Andretti -----Original Message----- From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Joel Fritz Sent: Wednesday, June 22, 2005 3:03 PM To: RPG programming on the AS400 / iSeries Subject: RE: RPG Free Format question Since the file operation bifs and %error it's pretty much down to the few places in display files. In the past two years we had a lot of people in and out on short term contracts. It was interesting to see the variety of coding styles. A few hadn't made it much past RPGII and a few had a very modern approach. I think the average was RPGIII compiled with CRTBNDRPG. Mostly no left hand indicators, but indicators for file ops and lookup. Very little use of bifs and date stuff. We had a guy on staff(left last year) who persisted in using six character variable names. To make it more fun he used his own version of Hungarian notation where the last two or three characters showed how the variable was used. He also refused to use prefixes. > -----Original Message----- > From: rpg400-l-bounces@xxxxxxxxxxxx > [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Bob Cozzi > Sent: Wednesday, June 22, 2005 11:59 AM > To: 'RPG programming on the AS400 / iSeries' > Subject: RE: RPG Free Format question > > Why would he still be using indicators in your code in the > first place? > I mean, this sort of bugs me... "How do I set off indicators > in free format?" Talk about perplexing programming. > > > -Bob Cozzi > www.RPGxTools.com > If everything is under control, you are going too slow. > - Mario Andretti > > -----Original Message----- > From: rpg400-l-bounces@xxxxxxxxxxxx > [mailto:rpg400-l-bounces@xxxxxxxxxxxx] > On Behalf Of Joel Fritz > Sent: Wednesday, June 22, 2005 12:17 PM > To: RPG programming on the AS400 / iSeries > Subject: RE: RPG Free Format question > > > It's just my opinion, based on personal taste (and my > superior intelligence and moral character <g>,) but I never > liked setting a bunch of indicators using movea. My > criterion is "How easy is it to read this code at 2AM?" For > setting a bunch of indicators if it's a task that needs to be > done more than once, I'll write a procedure with a name that > tries to describe what's going on. E. g. I have a standard > procedure for subfiles that sets the indicators that prepare > it for loading. > ***************************** NOTICE: All e-mail sent to or from this e-mail address will be received or otherwise recorded by The Sharper Image corporate e-mail system and is subject to archival, monitoring, and review by and/or disclosure to Sharper Image security and other management. This message is intended only for the use of the addressee and may contain information that is privileged and confidential. The contents of this message may contain personal views which are not the views of The Sharper Image. If you are not the intended recipient, dissemination of this communication is prohibited. ***************************** -- 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.