× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: Re: RPG Enhancement: Use of other indicator fields on OFLIND
  • From: "Simon Coulter" <shc@xxxxxxxxxxxxxxxxx>
  • Date: Sat, 15 Apr 00 12:45:46 +1000

H
Hello Darlene,

Specifying an indicator on the WRITE for the DetailRecord is only needed if no 
overflow 
indicator has been specified.  If an overflow indicator is specified on the 
F-spec it is 
always turned on automatically.  As far as I know it has always worked this 
way.  An 
excerpt from the FM follows:

>   Positions 56 and 57 can contain an indicator to be set on if the WRITE
>   operation is not completed successfully.  The indicator in positions 56
>   and 57 will be set on if overflow is reached to an externally described
>   print file and no overflow indicator has been specified on the File
>   description specification.

The programmer is still responsible for turning the overflow indicator off.  

Your technique of using the ERROR indicator to turn off overflow only works if 
the WRITE 
to the HeaderRecord did not result in an error.  If an error does occur on the 
WRITE 
overflow won't be turned off because indicator 99 will now actually indicate a 
problem -- 
which you aren't dealing with.  While it would be difficult to think of a 
situation where 
a WRITE to a printer file will fail (especially if the file is being spooled) 
misusing the 
ERROR indicator is IMNSHO sloppy.

Now where did I put that asbestos suit .... Oh, that's right, the Government 
claimed it 
due to asbestos being carcinogenic .... maybe if I curl up in a tiny wee ball 
the flames 
will miss me.

Regards,
Simon Coulter.

«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»
«» FlyByNight Software         AS/400 Technical Specialists       «»
«» Eclipse the competition - run your business on an IBM AS/400.  «»
«»                                                                «»
«» Phone: +61 3 9419 0175      Mobile: +61 0411 091 400           «»
«» Fax:   +61 3 9419 0175      mailto: shc@flybynight.com.au      «»
«»                                                                «»
«» Windoze should not be open at Warp speed.                      «»
«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»
//--- forwarded letter -------------------------------------------------------
> Date: Fri, 14 Apr 2000 10:02:06 -0400
> From: dbryant@banpharm.com
> To: RPG400-L@midrange.com
> Reply-To: RPG400-L@midrange.com
> Subject: RPG Enhancement: Use of other indicator fields on OFLIND

> 
> 
> 
> Here is the easy way to indicate whether overflow should happen in the RPG
> (using Externally Described Printer Files),
> 
> f PrinterFileName   E                      Printer  OFLIND(*IN99)
> 
> c
> c                              Write        DetailRecord
> 99               <-------- in column 56-57 (Err or < column)
> c                               If               *IN99
> c         Write        HeaderRecord           99               <-------- *in99
> will automatically setoff.
> c         Endif
> c
> c
> 
> 
> Of course make sure you defined your HeaderRecord to Skip Before to a
> particullar line, like line 1 (whatever).
> 
> My 2 cents worth..........
> 

+---
| This is the RPG/400 Mailing List!
| To submit a new message, send your mail to RPG400-L@midrange.com.
| To subscribe to this list send email to RPG400-L-SUB@midrange.com.
| To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.