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



Glen,

The 20 minute setting is a system value. I will have to check if the shop
will allow it to be done with a program.

Dan,

I'll have to check with the secofr on that. I want to say DSCJOB was tested
and did not work as intended, but I did not see this for myself. Maybe we
should have another go at it.



On Wed, Dec 28, 2016 at 10:23 AM, <rpg400-l-request@xxxxxxxxxxxx> wrote:

Send RPG400-L mailing list submissions to
rpg400-l@xxxxxxxxxxxx

To subscribe or unsubscribe via the World Wide Web, visit
http://lists.midrange.com/mailman/listinfo/rpg400-l
or, via email, send a message with subject or body 'help' to
rpg400-l-request@xxxxxxxxxxxx

You can reach the person managing the list at
rpg400-l-owner@xxxxxxxxxxxx

When replying, please edit your Subject line so it is more specific
than "Re: Contents of RPG400-L digest..."


*** NOTE: When replying to this digest message, PLEASE remove all text
unrelated to your reply and change the subject line so it is meaningful.

Today's Topics:

1. Call *SRVPGM in *PGM library (Justin Taylor)
2. Re: Call *SRVPGM in *PGM library (Alan Campin)
3. Re: Call *SRVPGM in *PGM library (JRusling@xxxxxxxxxxx)
4. Re: Call *SRVPGM in *PGM library (dlclark@xxxxxxxxxxxxxxxx)
5. Re. Call *SRVPGM in *PGM library (D*B)
6. Retain input buffer from fields when QINACTITV kicks user
from session. CPI1127&PSSR (Scott Williams)
7. Re: Retain input buffer from fields when QINACTITV kicks user
from session. CPI1127&PSSR (Dan)
8. Re: Retain input buffer from fields when QINACTITV kicks user
from session. CPI1127&PSSR (Glenn Gundermann)


----------------------------------------------------------------------

message: 1
date: Tue, 27 Dec 2016 18:52:09 +0000
from: Justin Taylor <JUSTIN@xxxxxxxxxxxxx>
subject: Call *SRVPGM in *PGM library

I have a program that calls a service program. They exist in the same
production library and the same test library. I need the test program to
call the service program in the test library. When that program is
deployed to the production library, I need it to call the service program
in the production library. There any good way to do this?




------------------------------

message: 2
date: Tue, 27 Dec 2016 10:55:35 -0800
from: Alan Campin <alan0307d@xxxxxxxxx>
subject: Re: Call *SRVPGM in *PGM library

Library list? Unless you hard code the library, it will find the service
program using the library list.

On Tue, Dec 27, 2016 at 10:52 AM, Justin Taylor <JUSTIN@xxxxxxxxxxxxx>
wrote:

I have a program that calls a service program. They exist in the same
production library and the same test library. I need the test program to
call the service program in the test library. When that program is
deployed to the production library, I need it to call the service program
in the production library. There any good way to do this?


--
This is the RPG programming on the IBM i (AS/400 and 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.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD



------------------------------

message: 3
date: Tue, 27 Dec 2016 13:00:41 -0600
from: JRusling@xxxxxxxxxxx
subject: Re: Call *SRVPGM in *PGM library

If the binding directory entry for the srvpgm has *libl the program should
should use the library list when determining that.

If your library lists are setup different for production and test, it
should work fine. afaik.

John

<snip>
I have a program that calls a service program. They exist in the same
production library and the same test library. I need the test program to
call the service program in the test library. When that program is
deployed to the production library, I need it to call the service program
in the production library. There any good way to do this?
</snip>
<br />
The information in this email is confidential and may be legally
privileged.
It is intended solely for the addressee. Access to this email by anyone
else is
unauthorized. If you are not the intended recipient, any disclosure,
copying,
distribution or any action taken or omitted to be taken in reliance on it,
is
prohibited and may be unlawful.


------------------------------

message: 4
date: Tue, 27 Dec 2016 14:26:43 -0500
from: dlclark@xxxxxxxxxxxxxxxx
subject: Re: Call *SRVPGM in *PGM library

"RPG400-L" <rpg400-l-bounces@xxxxxxxxxxxx> wrote on 12/27/2016 02:00:41
PM:
If the binding directory entry for the srvpgm has *libl the program
should
should use the library list when determining that.

Note that binding directory entries are only used at bind time --
not execution time. Thus, unless you are rebinding your programs when
moving them to production, then you do not need a binding directory in
your production environment. But I agree that using *LIBL in your binding
directory entries is best for bind-time and to let the current library
list dictate the library search order for your programs at execution-time.

Sincerely,

Dave Clark
--
int.ext: 91078
direct: (937) 531-6378
home: (937) 751-3300

Winsupply Group Services
3110 Kettering Boulevard
Dayton, Ohio 45439 USA
(937) 294-5331




************************************************************
*********************************
This email message and any attachments is for use only by the named
addressee(s) and may contain confidential, privileged and/or proprietary
information. If you have received this message in error, please
immediately notify the sender and delete and destroy the message and all
copies. All unauthorized direct or indirect use or disclosure of this
message is strictly prohibited. No right to confidentiality or privilege
is waived or lost by any error in transmission.
************************************************************
*********************************

------------------------------

message: 5
date: Wed, 28 Dec 2016 14:37:20 +0100
from: "D*B" <dieter.bender@xxxxxxxxxxxx>
subject: Re. Call *SRVPGM in *PGM library

... depends on your deployment process, your needs and your environment.
- if you have controll over the runtime environment (libl), you could bind
the SRVPGM via libl as posted by others
- if you have controll over the deployment process, you could bind qalified
- if you don't have controll to both and you want to call the SRVPGM from
the same lib as the PGM, regardless how the lib is actually named, you
could
bind dynamically at runtime via API. (ArdGate does it this way, you could
have a look to the sources, it's Open Source)

D*B



------------------------------

message: 6
date: Wed, 28 Dec 2016 08:53:02 -0500
from: Scott Williams <scottwill0707@xxxxxxxxx>
subject: Retain input buffer from fields when QINACTITV kicks user
from session. CPI1127&PSSR

I'm still kinda new to the RPG space, and I guess it's time I actually post
a question as my research has not led me to a working result yet.

My shop has a strict 20 minute timeout setting for the workstations. This
cannot be changed. Workstations (which have static, unique names) are being
kicked (the job is ended, not disconnected) and users are losing input
data. The system kicks out a CPI1127 when this happens. They are typing
lengthy entries and/or get distracted by phone calls, co-workers, etc.
Since they do not press any function keys, rollup/down, or Enter during the
time limit, their entries are lost when the system kicks them. (Note: they
are being given ten 70 length fields to enter data in the program affected
by this timeout setting.)

I was hoping the PSSR can trap the error was have the input field written
out to a work file. A CL program will be needed to check in there is any
data out in the workfile when the resume the program. This workfile could
be cleared each night after hours to avoid left over data. The problem I'm
running into is that even after coding a PSSR routine in the program, it
isn't executed when the system ends the job. The CPI1127 message can be
found in the QSYSOPR queue, but the PSSR doesn't seem to catch this.

Here is a sample program I wrote to test that theory. The program should
write to the XT90 file unless an error occured, then it will write to XT91
instead.

H OPTION(*NODEBUGIO: *SRCSTMT)
H DFTACTGRP(*NO)
H*=========================================================
=============*
H* DATA LOSS INACTIVITY TEST PROGRAM
*
H*=========================================================
=============*
F* FILE SPECS
F*=========================================================
=============*
FXT90 UF A E DISK INFSR(*PSSR)
FXT91 UF A E DISK
FXT90DF CF E WORKSTN INFSR(*PSSR)
D*=========================================================
=============*
D* DEFINITION SPECS
D*=========================================================
=============*
** Program Status Data Structure
D SDS
D PGMMSGID 40 46a
D pgmruntime 6s 0
D PSSRDone S N
C*=========================================================
=============*
C* CALC SPECS
C*=========================================================
=============*
C*
/FREE
//FREE FORMAT CODE BELOW
DOU *IN03;
INPUT = *BLANKS;
IF *IN03;
LEAVE;
ENDIF;
MONITOR;
WRITE RECORD1;
//DO STUFF WITH RECORD
READ RECORD1;
INTXT = INPUT;
WRITE XT90R;
ON-ERROR;
//IF PGMMSGID = 'CPI1127';
INTX2 = INPUT;
WRITE XT91R;
//ENDIF;
ENDMON;
ENDDO;
*INLR = *ON;

BEGSR *PSSR;
IF PSSRDONE;
*INH1 = *ON;
RETURN;
ELSE;
//IF PGMMSGID = 'CPI1127';
INTX2 = INPUT;
WRITE XT91R;
//ENDIF;
ENDIF;
ENDSR;

/END-FREE


C*
O*=========================================================
=============*
O* OUTPUT SPECS
O*=========================================================
=============*
**
***END OF PROGRAM***


Display Source:

A R RECORD1 CF03(03)
A 1 2SYSNAME
A 2 71TIME
A 1 71DATE
A 2 2'XT90DF'
A 1 35'TEST DISPLAY'
A DSPATR(RI)
A COLOR(TRQ)
A INPUT 50 B 6 16

Am I barking up the wrong tree with PSSR and MONITOR? Thanks in advance.
--
Scott Williams


------------------------------

message: 7
date: Wed, 28 Dec 2016 10:08:07 -0500
from: Dan <dan27649@xxxxxxxxx>
subject: Re: Retain input buffer from fields when QINACTITV kicks user
from session. CPI1127&PSSR

Hi Scott,

Not sure you can trap this via PSSR and MONITOR. However, check out the
SHTDN opcode. I believe this requires that the job be ended with
OPTION(*CNTRLD) DELAY(nn), where 'nn' is the number of seconds sufficient
enough for the program to do whatever it is you need it to do. I've never
used this in an interactive program, so I'm uncertain whether SHTDN will
work in a scenario where the program is waiting for input from the
workstation file. I'm thinking that, instead of EXFMT, you might need to
do WRITE, SHTDN, READ opcodes. The more I think about it though, I think
the program would stop at the READ opcode, so if the job is ended while the
program is sitting on the READ opcode waiting for the user, the SHTDN might
never trap the job ending.

My memory is foggy on this, but I think there is (was?) a way to write to
a workstation file, wait 'x' seconds, read the record, and loop through
this until the user presses Enter or some command key. It might have
required an API, maybe even a call to an IBM-supplied SUBRxx program (S/36
only???).

I think the better option is to disconnect the job (DSCJOB) instead of
ending it. If the job is disconnected, the user sees a signon screen with
a CPI1131 message at the bottom, however, the program and the data input on
the screen is retained in memory until the job is ended. If the user signs
back on before the job is ended, all of the data entered is retained. You
would need to talk to the security officer about changing the inactive
timeout to use DSCJOB instead of ENDJOB. There is a way to do this so the
job disconnects, say, at 20 minutes of inactivity, but the job doesn't
actually get ended until 'n' hours later. If your security officer doesn't
know how to do this, you might want to pose the question on the midrange-l
list.

- Dan

On Wed, Dec 28, 2016 at 8:53 AM, Scott Williams <scottwill0707@xxxxxxxxx>
wrote:

I'm still kinda new to the RPG space, and I guess it's time I actually
post
a question as my research has not led me to a working result yet.

My shop has a strict 20 minute timeout setting for the workstations. This
cannot be changed. Workstations (which have static, unique names) are
being
kicked (the job is ended, not disconnected) and users are losing input
data. The system kicks out a CPI1127 when this happens. They are typing
lengthy entries and/or get distracted by phone calls, co-workers, etc.
Since they do not press any function keys, rollup/down, or Enter during
the
time limit, their entries are lost when the system kicks them. (Note:
they
are being given ten 70 length fields to enter data in the program
affected
by this timeout setting.)

<snip>


------------------------------

message: 8
date: Wed, 28 Dec 2016 10:22:54 -0500
from: Glenn Gundermann <glenn.gundermann@xxxxxxxxx>
subject: Re: Retain input buffer from fields when QINACTITV kicks user
from session. CPI1127&PSSR

Hi Scott,

How are you specifying the 20-minute limit?
Are you using system values or are you doing it programatically?

I control timeouts programatically:
- modify the display file by adding INVITE to the record format
- create the display file with WAITRCD
- in the RPG program:
- modify the file spec to include: maxdev(*file)
- replace exfmt rcdfmt-name with (1) write rcdfmt-name (2) read(e)
dspf-name;
- after the read(e), specify: if %status = 1331; do what you want to do
on the timeout; endif;

There were some questions/emails about CPF4737 but I didn't understand
them.

Yours truly,

Glenn Gundermann
Email: glenn.gundermann@xxxxxxxxx
Work: (905) 486-1162 x 239
Cell: (416) 317-3144


On 28 December 2016 at 08:53, Scott Williams <scottwill0707@xxxxxxxxx>
wrote:

I'm still kinda new to the RPG space, and I guess it's time I actually
post
a question as my research has not led me to a working result yet.

My shop has a strict 20 minute timeout setting for the workstations. This
cannot be changed. Workstations (which have static, unique names) are
being
kicked (the job is ended, not disconnected) and users are losing input
data. The system kicks out a CPI1127 when this happens. They are typing
lengthy entries and/or get distracted by phone calls, co-workers, etc.
Since they do not press any function keys, rollup/down, or Enter during
the
time limit, their entries are lost when the system kicks them. (Note:
they
are being given ten 70 length fields to enter data in the program
affected
by this timeout setting.)

I was hoping the PSSR can trap the error was have the input field written
out to a work file. A CL program will be needed to check in there is any
data out in the workfile when the resume the program. This workfile could
be cleared each night after hours to avoid left over data. The problem
I'm
running into is that even after coding a PSSR routine in the program, it
isn't executed when the system ends the job. The CPI1127 message can be
found in the QSYSOPR queue, but the PSSR doesn't seem to catch this.

Here is a sample program I wrote to test that theory. The program should
write to the XT90 file unless an error occured, then it will write to
XT91
instead.

H OPTION(*NODEBUGIO: *SRCSTMT)
H DFTACTGRP(*NO)
H*=========================================================
=============*
H* DATA LOSS INACTIVITY TEST PROGRAM
*
H*=========================================================
=============*
F* FILE SPECS
F*=========================================================
=============*
FXT90 UF A E DISK INFSR(*PSSR)
FXT91 UF A E DISK
FXT90DF CF E WORKSTN INFSR(*PSSR)
D*=========================================================
=============*
D* DEFINITION SPECS
D*=========================================================
=============*
** Program Status Data Structure
D SDS
D PGMMSGID 40 46a
D pgmruntime 6s 0
D PSSRDone S N
C*=========================================================
=============*
C* CALC SPECS
C*=========================================================
=============*
C*
/FREE
//FREE FORMAT CODE BELOW
DOU *IN03;
INPUT = *BLANKS;
IF *IN03;
LEAVE;
ENDIF;
MONITOR;
WRITE RECORD1;
//DO STUFF WITH RECORD
READ RECORD1;
INTXT = INPUT;
WRITE XT90R;
ON-ERROR;
//IF PGMMSGID = 'CPI1127';
INTX2 = INPUT;
WRITE XT91R;
//ENDIF;
ENDMON;
ENDDO;
*INLR = *ON;

BEGSR *PSSR;
IF PSSRDONE;
*INH1 = *ON;
RETURN;
ELSE;
//IF PGMMSGID = 'CPI1127';
INTX2 = INPUT;
WRITE XT91R;
//ENDIF;
ENDIF;
ENDSR;

/END-FREE


C*
O*=========================================================
=============*
O* OUTPUT SPECS
O*=========================================================
=============*
**
***END OF PROGRAM***


Display Source:

A R RECORD1 CF03(03)
A 1 2SYSNAME
A 2 71TIME
A 1 71DATE
A 2 2'XT90DF'
A 1 35'TEST DISPLAY'
A DSPATR(RI)
A COLOR(TRQ)
A INPUT 50 B 6 16

Am I barking up the wrong tree with PSSR and MONITOR? Thanks in advance.
--
Scott Williams
--
This is the RPG programming on the IBM i (AS/400 and 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.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD



------------------------------

Subject: Digest Footer

--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L)
digest 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.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD

------------------------------

End of RPG400-L Digest, Vol 15, Issue 585
*****************************************





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.