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



Is there any way for an RPG to determine what program called it?

Two ways.

a) You can send a program message to your caller, and then retrieve that message. In the informaition for the message, it'll tell the program it was sent from, and the program it was sent to. You can use the QMHSNDPM and QMHRCVPM APIs to send & receive a message.

I'm pretty sure there's an example of this (though, it may be CL) in the Midrange.com FAQ.

b) You can use the QWVRCSTK API to retrieve the call stack, and see which program precedes yours.


The problem with BOTH of these solutions is performance. This'll significantly slow down the process of writing records. For some applications, that won't matter, for some it will... if performance is an issue, you might want to do some benchmarks and check it out.


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.