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



When I copied his source on our 7.3 TR10 system, I could compile the command. The problem that was missed by me at least was that specifying MIN(0) before MIN(1) causes the required parameters to become optional. You can see required parameters by prompting and looking at the color highlighting of the prompt input. Optional will have normal color and required will have HI (white by default) color. I fixed the command source by moving the required before the optional and then specified PROMPT('aaaa' 2) for the required and PROMPT('bbbb' 1) for the optional. After compiling the source and attempting to run the command the system complains about the missing required values.

But I still don't understand why not just make them has a DFT() value if there is a case when the values might not be passed. They are just Y/N inputs after all.

-Matt


-----Original Message-----
From: MIDRANGE-L <midrange-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of Bruce Vining
Sent: Friday, July 30, 2021 3:17 PM
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxxxxxxxx>
Subject: Re: Restricting user command values

I have not verified (no good access to an i), but suspect a warning message in the compile listing... And who really looks at those listings (well, other than me lol)

On Fri, Jul 30, 2021 at 4:55 PM Carel via MIDRANGE-L < midrange-l@xxxxxxxxxxxxxxxxxx> wrote:

You can have some control over the position of PARMS with the second
element on the PROMPT key word.

But as those are missing, I wonder how this could compile. Having
required PARMS (max(1)) after optional ones always throws compile
errors at me.


Op 30-7-2021 om 21:52 schreef Charles Wilt:
You can't have optional parms appear before required ones...

Change MIN(0) to MIN(1) for these
PARM KWD(DATE) TYPE(*CHAR) LEN(8) MIN(0) +
DFT(*CURRENT) PROMPT('Date to process +
(YYYYMMDD)')
PARM KWD(ITEM) TYPE(*DEC) LEN(6 0) MIN(0) +
DFT(0) PROMPT('Item to process')
PARM KWD(STORE) TYPE(*DEC) LEN(3 0) MIN(0) +
DFT(0) PROMPT('Store to process')
PARM KWD(VENDOR) TYPE(*DEC) LEN(5 0) MIN(0) +
DFT(0) PROMPT('Vendor to process')

HTH,
Charles


On Fri, Jul 30, 2021 at 12:41 PM Robert Rogerson
<rogersonra@xxxxxxxxx>
wrote:

Hi all, this has me stumped. I have this source for a command

CMD PROMPT('SBT BIMBO Refresh ')
PARM KWD(DATE) TYPE(*CHAR) LEN(8) MIN(0) +
DFT(*CURRENT) PROMPT('Date to process +
(YYYYMMDD)')
PARM KWD(ITEM) TYPE(*DEC) LEN(6 0) MIN(0) +
DFT(0) PROMPT('Item to process')
PARM KWD(STORE) TYPE(*DEC) LEN(3 0) MIN(0) +
DFT(0) PROMPT('Store to process')
PARM KWD(VENDOR) TYPE(*DEC) LEN(5 0) MIN(0) +
DFT(0) PROMPT('Vendor to process')
PARM KWD(MODE) TYPE(*CHAR) LEN(1) MIN(1) +
VALUES('Y' 'N') RSTD(*YES) +
PROMPT('Update Production (Y/N)')
PARM KWD(SENDEDI) TYPE(*CHAR) LEN(1) MIN(1) +
VALUES(Y N) RSTD(*YES) +
PROMPT('Send EDI Sales (Y/N)')
PARM KWD(CLSBSLP) TYPE(*CHAR) LEN(1) MIN(1) +
VALUES(Y N) RSTD(*YES) +
PROMPT('Clear SBTSALESP')

If I call the command from the command line SB0125CMD
DATE(20210708) ITEM(883082) the cpp is called.

I thought the only valid values for the last three parameters would
be
Y or
N and since MIN(1) is specified it could only be Y or N.

But the CPP is being called and the last three parameters are blank.

How do I restrict the last three parms to only Y or N and not blank?

Thanks,

Rob
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L)
mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit:
https://urldefense.com/v3/__https://lists.midrange.com/mailman/list
info/midrange-l__;!!O6xM9Yim9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt
6J5p5sLZw1GiLmCLVW8Wlsz_LYgaf1Nqv$
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://urldefense.com/v3/__https://archive.midrange.com/midrange-l__;!!O6xM9Yim9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5sLZw1GiLmCLVW8Wlsz_LYp9nFiTK$ .

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription
related
questions.

Help support midrange.com by shopping at amazon.com with our
affiliate
link:
https://urldefense.com/v3/__https://amazon.midrange.com__;!!O6xM9Yi
m9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5sLZw1GiLmCLVW8Wlsz_LYg
5n75WZ$


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit:
https://urldefense.com/v3/__https://lists.midrange.com/mailman/listinf
o/midrange-l__;!!O6xM9Yim9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5s
LZw1GiLmCLVW8Wlsz_LYgaf1Nqv$ or email:
MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://urldefense.com/v3/__https://archive.midrange.com/midrange-l__;!!O6xM9Yim9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5sLZw1GiLmCLVW8Wlsz_LYp9nFiTK$ .

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription
related questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link:
https://urldefense.com/v3/__https://amazon.midrange.com__;!!O6xM9Yim9Y
k!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5sLZw1GiLmCLVW8Wlsz_LYg5n75WZ
$



--
Thanks and Regards,
Bruce
931-505-1915
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit: https://urldefense.com/v3/__https://lists.midrange.com/mailman/listinfo/midrange-l__;!!O6xM9Yim9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5sLZw1GiLmCLVW8Wlsz_LYgaf1Nqv$
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at https://urldefense.com/v3/__https://archive.midrange.com/midrange-l__;!!O6xM9Yim9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5sLZw1GiLmCLVW8Wlsz_LYp9nFiTK$ .

Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related questions.

Help support midrange.com by shopping at amazon.com with our affiliate link: https://urldefense.com/v3/__https://amazon.midrange.com__;!!O6xM9Yim9Yk!uATAhNcdd5VgM9OPqr6psGY8eloFEEfVUVt6J5p5sLZw1GiLmCLVW8Wlsz_LYg5n75WZ$

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.