× 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 6/13/2013 3:47 PM, Mark S Waterbury wrote:
It takes only a few seconds to write a small "test harness" in CL, e.g.:

PGM
DCL &PARM1 *CHAR 100 VALUE('/this/is/a/test')
DCL &PARM2 *CHAR 3 VALUE('3 ')
CALL PGM(TARGETPGM) PARM(&PARM1 &PARM2)
RETURN
ENDPGM


Just as quick to write a command, which I think is much handier for testing.

Source file
CMD ('command description goes here')
PARM DIR TYPE(*CHAR) LEN(255) CASE(*MIXED) PROMPT('Directory')
PARM DAYS TYPE(*CHAR) LEN(3) PROMPT('Days')

==> CRTCMD mylib/mytest pgm(mylib/targetpgm) srcfile(...)

==> mylib/mytest '/this/is/a/test' 3

One benefit of a command here is that you don't have to remember to add the quotes on the 3. The command knows it's a 3 byte character. Too bad the quotes are needed for the path, but that's because of the slashes.

Without slashes, you don't need the quotes. The CASE(*MIXED) causes it to keep the case as typed.

==> mylib/mytest a.txt 3

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.