Ok. I have to be missing something obvious. I am passing my parameter, but it is empty once inside the service program.
1. Main Program loads PLIST1 data and calls procedure (values verified in debug):
------------------------------------------------------
(this is in my QCPYSRC used by SRVPGM and main PGM)
dcl-pr VS_RateShop char(15) ExtProc('VS_RateShop');
inPlist1 likeds(plist1) const;
end-pr;
------------------------------------------------------
(This is in main PGM)
dcl-ds plist1 extname('PLIST1DS') inz;
end-ds;
.... code here
Carrier = VS_RateShop(plist1);
------------------------------------------------------
2. Inside VS_RateShop procedure, plist1 is empty. I have plist1 defined in the "top" of my service program source.
------------------------------------------------------
dcl-ds plist1 extname('PLIST1DS') inz;
end-ds;
dcl-proc VS_RateShop Export;
dcl-pi *n char(15);
inPlist1 likeds(plist1) const;
end-pi;
------------------------------------------------------
What am I missing here?
Greg
-----Original Message-----
From: RPG400-L [mailto:rpg400-l-bounces@xxxxxxxxxxxxxxxxxx] On Behalf Of Barbara Morris
Sent: Saturday, April 13, 2019 12:37 PM
To: rpg400-l@xxxxxxxxxxxxxxxxxx
Subject: Re: Advice passing a large parameter
On 2019-04-12 11:41 AM, Vernon Hamberg wrote:
I think when using VALUE a copy of the data is always made, then a
pointer to THAT is passed. Again, this wasn't clearly stated in the
7.3 manual, but other places on the 'Net say this.
When using VALUE, you're right that a copy is always made, but it's the entire copy that gets passed, not a pointer.
--
Barbara
--
This is the RPG programming on IBM i (RPG400-L) mailing list To post a message email: RPG400-L@xxxxxxxxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit:
https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://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:
https://amazon.midrange.com
As an Amazon Associate we earn from qualifying purchases.