Doug,

Unfortunately, you cannot pass parm values back to an OCL from a program. As you mentioned, it's the LDA or a switch.

-mark

On 7/23/2025 11:50 AM, DEnglander--- via MIDRANGE-L wrote:
Does anyone have an example of an RPGLE program being called using OCL
with parameters? I am looking for a way to communicate an RPG programs
results back to an existing OCL. Is there a way to do this without
switches or *LDA?

I have an OCL as:

*
// EVALUATE P1 = 'Y'
CALL TSTOCLR PARM(?1?)
*
// * ' PARAMETER IS'
// * '?1?'


When I run this in S36Environment, I get: Pointer or parameter error (C G
D F).

All TSTOCLR does is change the value of its incoming parameter and ends.
It would change "Y" to "n" and I'd expect the output to be PARAMETER IS n

Is this something possible, or am I restricted to LDA [or switches] only?

Doug

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