|
On Mon, 13 Aug 2001, Christopher A. Libby wrote:
> How would one go about using quotes in an RPG literal? I'm trying to put
> together a string which will be used to call an AS/400 command, however this
> command has several quotes (') in it. How would I escape them?
The escape syntax always seemed clumsy to me so I put a constant in our
main definition /copy member that defines the constant SQ as a single
quote. Then I just do:
C eval string = 'this is nice, isn' + SQ + 't it?'
The main definition /copy member looks like:
DSQ C CONST(X'7D')
so I guess you could skip the /copy and write it in hex every time - but I
like the constant better :)
James Rich
james@eaerich.com
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.