|
No. You do not need to write C code. You just call the C api's.
Actually, I am not so sure that you should even care if they are written
in C or what. Well, maybe some obscure thing about parameter passing...
Never used the C file api's but let me summarize how they work.
So, instead of an F spec and an OPEN operation code you call a program
that opens the file. Once opened you call other programs that do your
reads and stuff. Now, I am not sure how this all relates to externally
defined files and all but I am sure that a little research may find some
documentation.
Rob Berendt
--
Group Dekko Services, LLC
Dept 01.073
Dock 108
6928N 400E
Kendallville, IN 46755
http://www.dekko.com
Bryce Martin
Sent by: rpg400-l-bounces@xxxxxxxxxxxx
07/28/2008 08:32 AM
Please respond to
RPG programming on the AS400 / iSeries
To
RPG programming on the AS400 / iSeries
cc
Subject
Re: Subfile as a procedure
Well I'm not really at liberty to be writing C code (as much as I would
love to) in my shop. That is not a language we support, so I guess I'll
just have to tough it out.
Panels...I think I'd rather not...
Thanks
Bryce Martin
Programmer/Analyst I
Ext. 4777
vhamberg@xxxxxxxxxxx
Sent by: rpg400-l-bounces@xxxxxxxxxxxx
07/26/2008 06:32 PM
Please respond to
RPG programming on the AS400 / iSeries
To
RPG programming on the AS400 / iSeries
cc
Subject
Re: Subfile as a procedure
Right - have used some of those functions in a previous life - thing is,
you can specify - in fact, you HAVE to specify - the format you want to
use, in a separate call, not in an F-spec, so its name can be passed as a
parameter to a generalized procedure. In RPG we are insulated from all
these gory details, but we do lose some power thereby.
Oh - one could also go with UIM panel group lists, too!
Just expanding on your info, Jon - heh!
HTH
Vern
-------------- Original message --------------
From: Jon Paris
--
On 25-Jul-08, at 11:24 PM, rpg400-l-request@xxxxxxxxxxxx wrote:
Just the other day I was thinking along these same lines. My
thought was
that if I could soft code the record format in a variable I could
move my
subfile setup to a sub procedure and just pass the record format in a
variable as the parameter that way I wouldn't have to write the same
subfile prep code over and over again for each one. Well as I found
out, ...
This can be done in RPG, but only by prototyping and wrappering the C
record I/O procedures. This is not that hard, but does require a
certain amount of knowledge of C. I thought that there were some
examples of doing this out on the web but I don't have time to search
for them right now.
An alternative option is the use the Dynamic Screen Manager (DSM) APIs
to handle the screens. This will not strictly speaking give you a
subfile but can be used for scrolling lists in windows etc. Again
there are examples out there.
Jon Paris
www.Partner400.com
www.SystemiDeveloper.com
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.
--- This message (including any attachments) is intended only for the use
of the individual or entity to which it is addressed and may contain
information that is non-public, proprietary, privileged, confidential, and
exempt from disclosure under applicable law. If you are not the intended
recipient, you are hereby notified that any use, dissemination,
distribution, or copying of this communication is strictly prohibited. If
you have received this communication in error, please notify us and
destroy this message immediately. ---
--
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.
--
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.