CONTROL NOMSG vs MSG On Thu, Sep 18, 2025 at 4:09 PM Phil Smith III <[email protected]> wrote:
> Ok, ok, it "ran" but it didn't function. Doesn't answer my question, which > was: > > Is there some setting that might be suppressing that error > > That would explain his results: it didn't do anything because it lacked > the MACRO statement. > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Seymour J Metz > Sent: Thursday, September 18, 2025 5:03 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > All of this is output from the macro: > > * Command in error . : CAPS OFF > * > * > * > * Command not executed > * > * An ISREDIT MACRO statement must precede any executable statements. > * > * > * > * Error message ID . : ISRE741 > * > * > * > * Last return code . : 28 > * > * > * > * Macro executing . : CX > * > * > * > * Press ENTER key to terminate the macro. > * > > > -- > Shmuel (Seymour J.) Metz > http://mason.gmu.edu/~smetz3 > עַם יִשְׂרָאֵל חַי > נֵ֣צַח יִשְׂרָאֵ֔ל לֹ֥א יְשַׁקֵּ֖ר > > > > > ________________________________________ > From: IBM Mainframe Discussion List <[email protected]> on behalf > of Phil Smith III <[email protected]> > Sent: Thursday, September 18, 2025 3:53 PM > To: [email protected] <[email protected]> > Subject: Re: Edit macro CHANGE not preseriving case > > > External Message: Use Caution > > > Sorry, where? I see one post that shows the macro, no messages? I'm > missing something!! > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Seymour J Metz > Sent: Thursday, September 18, 2025 3:02 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > I know that because the messages say that the macro was running. > > The issues for CLIST and REXX are different. > > -- > Shmuel (Seymour J.) Metz > http://mason.gmu.edu/~smetz3 > עַם יִשְׂרָאֵל חַי > נֵ֣צַח יִשְׂרָאֵ֔ל לֹ֥א יְשַׁקֵּ֖ר > > > > > ________________________________________ > From: IBM Mainframe Discussion List <[email protected]> on behalf > of Phil Smith III <[email protected]> > Sent: Thursday, September 18, 2025 11:50 AM > To: [email protected] <[email protected]> > Subject: Re: Edit macro CHANGE not preseriving case > > > External Message: Use Caution > > > Right...sorry, not trying to sound pissy, but what's your point? How do we > know that? Why didn't he get the error I did? Why (at least with the MACRO > statement) does it work for others? I think we still have some mysteries > here! > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Seymour J Metz > Sent: Wednesday, September 17, 2025 9:07 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > The macro did run, it just didn't do what OP expected. > > -- > Shmuel (Seymour J.) Metz > http://mason.gmu.edu/~smetz3 > עַם יִשְׂרָאֵל חַי > נֵ֣צַח יִשְׂרָאֵ֔ל לֹ֥א יְשַׁקֵּ֖ר > > > > > ________________________________________ > From: IBM Mainframe Discussion List <[email protected]> on behalf > of Phil Smith III <[email protected]> > Sent: Wednesday, September 17, 2025 3:20 PM > To: [email protected] <[email protected]> > Subject: Re: Edit macro CHANGE not preseriving case > > > External Message: Use Caution > > > Huh, I just assumed he was right about it not working. If I try to run it > as OP had it, with no MACRO statement, I get: > > > ****************************************************************************** > * > * > * Command in error . : CAPS OFF > * > * > * > * Command not executed > * > * An ISREDIT MACRO statement must precede any executable statements. > * > * > * > * Error message ID . : ISRE741 > * > * > * > * Last return code . : 28 > * > * > * > * Macro executing . : CX > * > * > * > * Press ENTER key to terminate the macro. > * > * > * > * > * > * > * > > ****************************************************************************** > > Is there some setting that might be suppressing that error, such that the > real answer is "Your macro didn't really even run"? > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Schmitt, Michael > Sent: Wednesday, September 17, 2025 3:09 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > There's something more subtle going on. And, the original example works > for me: > > /* REXX */ > address ISREDIT > "MACRO" > CAPS OFF > CHANGE 'AAA' 'Aaa' ALL > exit > > If I execute it on itself I get: > > /* REXX */ > address ISREDIT > "MACRO" > CAPS OFF > CHANGE 'Aaa' 'Aaa' ALL > exit > > which is as expected. > > Yes, it is treating CAPS, OFF, CHANGE, and ALL as variables, so they have > their own uppercase value. But 'AAA' and 'Aaa" are literals, not variables. > So the command to Edit should be: > > CHANGE AAA Aaa ALL > > And Edit preserves entered case on the "to" string of a change command; it > is same as CHANGE AAA c'Aaa' ALL. > > So why didn't it work for the original poster? > > Note: I'm on z/OS 2.5. > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Phil Smith III > Sent: Wednesday, September 17, 2025 12:43 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > Assuming your code is Rexx, what you're missing is that your double quotes > are being consumed by Rexx. What you're passing on the CHANGE is: > > (variable) ISREDIT > (space) > (variable) CHANGE > (space) > (literal) LOWER > (space) > (literal) lower > (space) > (variable) WORD > (space) > (variable) ALL > > Now, none of those variables have (presumably) been set, so their values > are the uppercase versions of the variable name. Thus what ISPF sees is: > ISREDIT CHANGE LOWER LOWER WORD ALL > > In other words, your quotes aren't getting to ISPF. Hence the quotes in > Chip's version: > "ISREDIT CHANGE 'LOWER' 'lower' word all" > > That makes the ENTIRE command a literal to Rexx, so it gets passed as is > (minus the single quotes), and ISPF sees what you want it to see. > > Make sense? This is basic Rexx stuff but gets confusing with ISPF in the > mix because of the quotes thing. My usual rule of thumb is to use single > quotes for Rexx literals, so I can use the double quotes inside for ISPF. > You could also double the quotes, but that gets super-fugly and even more > confusing: > ISREDIT CHANGE """LOWER""" """lower""" word all > > That will mean ISPF sees: > (variable) ISREDIT > (space) > (variable) CHANGE > (space) > (literal) " > (literal) LOWER > (literal) " > (space) > (literal) " > (literal) lower > (literal) " > (space) > (variable) WORD > (space) > (variable) ALL > > In Rexx, it's a very good idea to ALWAYS know what's a literal and what's > a variable and to quote all literals. It not only avoids problems but is > also more efficient. > > (The "problems" part comes when you have that line as you wrote it > working, and then someone assigns variable LOWER to some value and all hell > breaks loose!) > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Steely.Mark > Sent: Wednesday, September 17, 2025 1:07 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > I have the same issue - this is the code I use: > > ISREDIT MACRO > ISREDIT CAPS OFF > ISREDIT CHANGE "LOWER" "lower" word all > ISREDIT RESET > EXIT CODE(0) > > I did test the REXX version below and that did work - is there a way to > get this version to work ? > > Thank You > > > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Phil Smith III > Sent: Wednesday, September 17, 2025 11:57 AM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > ! > > CAUTION! EXTERNAL SENDER! STOP, ASSESS, AND VERIFY Do you know this > person? Were you expecting this email? If not, report it using the Report > Phishing Button! > > Thank you! As a long-time XEDIT maven I'd been looking for such a book, > for some reason never found it before. 488pp, that'll take a while to > digest... > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Grantham, Chip > Sent: Wednesday, September 17, 2025 12:42 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > Google z/OS 3.1 ISPF Edit and Edit Macros > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Phil Smith III > Sent: Wednesday, September 17, 2025 11:37 AM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > What does > 'Macro ()' > do? Pointer to doc would be great if you have it! > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of Grantham, Chip > Sent: Wednesday, September 17, 2025 12:32 PM > To: [email protected] > Subject: Re: Edit macro CHANGE not preseriving case > > Try this: > /* REXX */ > address isredit > 'Macro ()' > 'CAPS OFF' > 'CHANGE "AAA" "Aaa"' all > Exit > > -----Original Message----- > From: IBM Mainframe Discussion List <[email protected]> On Behalf > Of ITschak Mugzach > Sent: Wednesday, September 17, 2025 11:25 AM > To: [email protected] > Subject: Edit macro CHANGE not preseriving case > > I wrote a simple edit macro to change the case of a text. but it is still > keeping the old case and not folding to lower case. for example: > > /* Rexx */ > Address ISREDIT > CAPS OFF > CHANGE 'AAA' 'Aaa' ALL > > What am I doing wrong? > > ITschak Mugzach > *|** IronSphere Platform* *|* *Information Security Continuous Monitoring > for z/OS, x/Linux & IBM I **| z/VM coming soon * > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, send email > to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > > > > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > > > > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > > > > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > -- Mike A Schwab, Springfield IL USA Where do Forest Rangers go to get away from it all? ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
