× 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.



Correct.

You can't define primary / secondary files in a procedures f-specs.

They must be "full procedural" ie:

0170.00 PCalcCII b Export
0171.00 D PI 2 0
0171.01 dwItem 7 0
0172.00 dwType 1a
0173.00
0173.01 FIoritemm iF e k disk
0173.02 DGetCustRec DS LikeRec(Ioritem1)
0174.00 DzCnt s 2 0


HTH,
Charles

On Mon, Sep 28, 2009 at 3:18 PM, <john_maassel@xxxxxxxxxxxx> wrote:
Do subprocedures support primary files? I thought they didn't have any
Cycle code like the main procedure has.

John Maassel
IBM i Programmer/Analyst
Bob Evans Farms, Inc
john_maassel@xxxxxxxxxxxx
614-492-7413
Fax: 614-497-4315



"Doug Palme" <DPalme@xxxxxxxxxxx>
Sent by: rpg400-l-bounces@xxxxxxxxxxxx
09/28/2009 02:43 PM
Please respond to
RPG programming on the IBM i / System i <rpg400-l@xxxxxxxxxxxx>


To
RPG programming on the IBM i/System i <rpg400-l@xxxxxxxxxxxx>
cc

Subject
declaring a file local to a sub-procedure






I have been attempting to declare a file local to a sub-procedure just to
see how it operates, etc.

However, I am having a problem getting this to compile.  The compiler
keeps throwing errors from:


*RNF2580 30      1 The File Designation entry is not valid for a file
defined
in a subprocedure; the specification is ignored.

to

*RNF0258 30      1 Form-Type entry is not valid for subprocedures, or is
out of
                  sequence.


Here is the two ways I have coded the declaration so if I am doing
something wrong, please feel free to point it out:


METHOD A
0170.00 PCalcCII          b                   Export
0171.00 D                 PI             2  0
0171.01 dwItem                           7  0
0172.00 dwType                           1a
0173.00
0173.01 FIoritemm  ip   e           k disk
0173.02 DGetCustRec       DS                  LikeRec(Ioritem1)
0174.00 DzCnt             s              2  0

METHOD B - which I got from
http://www.mcpressonline.com/programming/rpg/v6r1-rpg-enhancements.html

0170.00 PCalcCII          b                   Export
0170.01 FIoritemm  ip   e           k disk
0171.00 D                 PI             2  0
0171.01 dwItem                           7  0
0172.00 dwType                           1a
0173.00
0173.02 DGetCustRec       DS                  LikeRec(Ioritem1)
0174.00 DzCnt             s              2  0

It does not like the F spec or so it seems......

Suggestions?


--
This is the RPG programming on the IBM i / System i (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 IBM i / System i (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 thread ...

Replies:

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.