× 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 Tue, May 16, 2017 at 5:41 PM, Dan <dan27649@xxxxxxxxx> wrote:

When I debugged CA9802R, the p_Account# field for the second call had a
junk character in position 18. I understand it's because the parameter
passed from the calling program is 17 bytes, but I thought one of the
"vary*" keywords would allow me to do this without having to pass a length
parameter.


​*VARSIZE requires a length parm and you're calling program would need to
be careful to only access the size passed. All you're really doing is
turning off the compile time size checking of that parameter.

VARYING, does not need a length parm, as it's built into the first two
bytes).


You'd be much better off using a procedure, rather than a program...

This proc...
d MaskAccount# pr 20a varying
d AccountNbr 20a Const varying Options( *Trim )


​would work
acct17 = MaskAccount#('12345678901234567');
acct20 = MaskAccount#​('12345678901234567890');

You could make a program work, it's just lots trickier...

​Charles​

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.