|
I'd have to disagree with the other poster James. Writing a programs to
read and write stream files is really not very difficult, and it can
provide significant benefits over CPY*IMPF and iSeries Access File
transfer.
Jeff Young wrote:
I am comfortable using the System API's to create files on the IFS, buthave not had to read them.
You can use the read() API to read a stream file. See
http://www.scottklement.com/rpg/ifs_ebook/basics.html#OPENCLOSE.
Start with that, and come back if you have more questions. Generally
speaking, I'd say:
1. Figure out how to read data from a string file in chunks of n bytes
(reading one byte at a time is inefficient).
2. Now forget that the data came from a file and process it byte by byte
the same as you would process multi-field data from any other source.
Scott's ebook should give you all you need, but feel free to ask more
questions here. Many questions will already be answered in the archives
of this list.
HTH,
Adam
--
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.