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




On 30/01/2009, at 7:49 PM, David FOXWELL wrote:

I'll rephrase that. The CLP is called with the MSGF paramèters MSGF, MSGID and MSGDTA. The TOMSGQ parameter is *TOPGMQ.

Presuming those are the only specified parameters and the command defaults have not been changed then the message will be sent to the message queue of the call stack entry immediately preceding the CL program i.e., the caller of the CL program. This is almost exactly what the help text for TOPGMQ states.

In an OPM environment the call stack message queue will be the same name as the program. In an ILE environment the call stack message queue will be a procedure name.


The message gets shown in a message subfile, something I only ever used when I started learning but never since.

The DDS defining the message subfile links the message subfile to a call stack message queue via the SFLPGMQ keyword. I suggest you read about that in the "DDS for display file" section in the InfoCentre

The OPM program that currently displays the message subfile will set the SFLPGMQ variable to its own name.

In an ILE environment you will either have to modify the CLP to send the message to the PEP of the caller or you will have to use the long form of SFLPGMQ to nominate a procedure in the calling program to receive the message and modify the CLP to send to that procedure.

Again, there have been previous discussions on this topic so the archives will provide further information.


As for the ILE question, what I am trying to say is, I want to be sure that I don't have a sub procedure somewhere that calls an OPM and therefore strays outside of my ACTGRP.

Why do you care? As long as the called programs don't rely on overrides, commitment definitions, or variables scoped to the activation group it generally won't matter if the called program runs in another activation group. So what is the reason for your concern?

The only way you can accomplish what you want is via 3rd-party "where- used" software or by writing your own tool to do the grunt work. DSPPGMREF will give an outfile listing the programs called, QBNLPGMI and QBNLSPGM will give bound reference information, and QCLRPGMI will give the activation group attribute. That should be sufficient to get you started. I can foresee some difficulties but none insurmountable.


Regards,
Simon Coulter.
--------------------------------------------------------------------
FlyByNight Software OS/400, i5/OS Technical Specialists

http://www.flybynight.com.au/
Phone: +61 2 6657 8251 Mobile: +61 0411 091 400 /"\
Fax: +61 2 6657 8251 \ /
X
ASCII Ribbon campaign against HTML E-Mail / \
--------------------------------------------------------------------




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.