Most likely it is seeing the dash as a minus sign which hints to me that quite possibly the apostrophes are not lining up the way you think they are?


On 4/17/2012 4:17 PM, dale janus wrote:
I have somewhat convoluted series of programs that is used to email
shipping documents and invoices to customers. Our billing process runs a
CL program that (naturally) calls RPG. In the RPG program I use QCMDEXE
to put together a long string of 7 parameters to call another CL program
which uses software called BLUESERIES to actually do the emailing (and
occasional fax).


As I struggled to put this together, I had trouble getting RPG to string
the commands together with quotes and parentheses, etc. I don't remember
all the methods I tried.

I created a command to call the last CL program. RPG calls the CMD with
parameters, which runs the CL program and the documents get emailed.
Customers are happy, billing dept is happy, life is good.

Then one of our customers has an email address with a hyphen in it. The
CMD blows up.

"Message . . . . : Expression operator not allowed for parameter EMAIL.
Cause . . . . . : An expression operator was found immediately before or
after a character string with no intervening blanks on a parameter
that does
not support expressions. Character string expressions are only allowed in
CHGVAR commands, IF commands, or a parameter defined with EXPR(*YES).
Arithmetic, relational, and logical expressions are only allowed on the
CHGVAR and IF commands. Recovery . . . : Remove the expression
operator
or insert a blank between the operator and the character string. More
information on expression operators can be found in the CL Reference
manual."


Is there an easy way to edit the CMD parameters as part of the CMD? Or
if I edit in RPG and find a hyphen, what can I do to pass it correctly?

This whole thing took me a while to get working and for some reason, I
could not set up the QCMDEXE call correctly with the 7 parameters if I
had to "CALL MYCLPGM (parm1 parm2 parm etc). But I could with the CMD.


So to recap in reverse, the final step is a CL program that receives
parameter of email address, customer name, type of document to send. It
creates a path statement and runs BLUESERIES to send/fax the documents.

A CMD is used to fire off the CL program. If the email address has a
hyphen in it, the CMD bombs.

An RPG program calls the CMD

Thanks
---Dale


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.