Jerry,
Thanks for the input on best practices. It's very good information to
have.
Regarding Activation Groups, do they have to be predefined in the system
via command? If so, what are the criteria? We're going to be
relocating our system to a new physical location. In the interim, we'll
be "leasing' space on a mirror system.
Tom Armbruster
Senior Software Developer
Travelocity On Location
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Jerry Adams
Sent: Friday, September 05, 2008 2:16 PM
To: RPG programming on the AS400 / iSeries
Subject: RE: Environment Corruption?
Tom,
First, never compile ILE programs to the default activation group, even
if they are stand-alone programs. The only way to reclaim the default
activation group is to end the job (sign off in an interactive program).
Ninety percent of the time I compile all of my ILE programs to the same
activation group name - except when I don't, which means there's a
reason. The compile error you got indicates that the parameters you say
you've used for several months are not the ones used to compile this
program. Personally I put the activation group name and "stuff" in the
Header-spec compiler directives, such as:
H DEBUG(*Yes)
H DFTACTGRP(*NO)
H ACTGRP('QILE')
H DATFMT(*ISO)
H DATEDIT(*YMD)
H OPTION(*NODEBUGIO)
Actually I keep those in a copybook and use that except for those rare
instances when I want to name the activation group something else, or
such. You can see what activation group was used to compile the program
by using the DSPPGM command (and other neat stuff, too).
Now, regarding the error, I daresay that the operating system knows what
it's talking about. The DSPSIZ parameter is, of course, on the display
file's DDS, In my case, all of my display files have DSPSIZ(24 80
*DS3). You might check yours and see if it has something like DSPSIZ(27
132 *DS3). Then compare the iSeries Access (or whatever you use for
emulation) to see if the settings match. A 24x80 display file will fit
in a 27x132 screen, but probably not visa versa (i.e., I never tried it,
but seems logical). This is why I always use the DSPSIZ(24 80 *DS3)
definition. Some people want to get more on a screen, though.
Jerry C. Adams
IBM System i Programmer/Analyst
B&W Wholesale
office: 615-995-7024
email: jerry@xxxxxxxxxxxxxxx
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Armbruster, Tom
Sent: Friday, September 05, 2008 3:50 PM
To: rpg400-l@xxxxxxxxxxxx
Subject: Environment Corruption?
First, let me start with the statement that the ILE environment confuses
the heck out of me sometimes. :-) I learned RPG III and RPG IV on the
fly to help fill the gaps in my shop. When I recognized the syntax
available in ILE RPG as something more familiar to my OOP and web based
programming background, I embraced it and started incorporating more of
the methodology.
Now I'm faced with an environment issue, I think, for which I need some
advice.
Today, programs that used to work in the interactive environment are
suddenly failing. The programs in question are prototyped, and the
calling program is bound to a service program (I've read it's the best
way to cascade common modules to programs). The prototypes in question
are not part of the service program, they're just includes that call an
external program. Here's what I mean:
dds_hotelrec e ds extname(hotels01:f_hotels:*INPUT)
d*
d GetHotel_# pr extpgm('SEL04011')
d vghotel_ds likeds(ds_hotelrec)
I can call this program from a command line without issue. Today,
however, in the interactive program the call returns a CPF4169 error.
My research indicates that this is a display size error. Well, that's
not the case. DSPSIZ is set, and the call used to work. Just to verify
that the object was up to date, I tried to recompile using the same
command line options that I've used for several months (
CRTSQLRPGI OBJ(ETSSHARE/SEL04011) OBJTYPE(*PGM) DBGVIEW(*SOURCE)
DYNUSRPRF(*OWNER) COMMIT(*NONE) SRCFILE(ETSSHARE/QRPGLESRC) and CRTPGM
PGM(ETSSHARE/SEL04011) MODULE(*PGM) BNDSRVPGM(ETSSHARE/ETSSRVPGM)
USRPRF(*OWNER)). This time, however, the compiler returns "Parameter
BNDDIR not allowed with DFTACTGRP(*YES)."
Is it possible that an interactive "crash" within a user session could
return these types of errors? Should I be compiling the objects in a
different way? Any advice and/or insight is welcome.
Thanks,
Tom Armbruster
Senior Software Developer
Travelocity On Location
--
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.