View previous topic :: View next topic
|
Author |
Message |
mpestolas
New User
Joined: 09 Jan 2023 Posts: 1 Location: canada
|
|
|
|
Hello,
hoping to get some help. I am a beginner on rexx. hope someone could help me. is there a way in rexx macro I can create a macro to edit the below jcl:
=COLS> ----+----1----+----2----+----3
****** *****************************
==MSG> NOTE: CAPS ON NUMBER ON
000100 *
000200 * CURRENT: YYYYMMDD
000300 *
006000 COPY ALL
006100 18,6,C,EQ,'014744'
006200 REPL
006300 10,8,C,'20230210'
insert a current date with format: YYYYMMDD on column #10
Appreciate your help.
Thank you,
Mike |
|
Back to top |
|
|
Joerg.Findeisen
Senior Member
Joined: 15 Aug 2015 Posts: 1334 Location: Bamberg, Germany
|
|
|
|
What have you tried yourself so far? Also, please make use of the Code Button when presenting Code/Data. |
|
Back to top |
|
|
sergeyken
Senior Member
Joined: 29 Apr 2008 Posts: 2140 Location: USA
|
|
|
|
mpestolas wrote: |
is there a way in rexx macro I can create a macro to edit the below jcl:
Code: |
=COLS> ----+----1----+----2----+----3
****** *****************************
==MSG> NOTE: CAPS ON NUMBER ON
000100 *
000200 * CURRENT: YYYYMMDD
000300 *
006000 COPY ALL
006100 18,6,C,EQ,'014744'
006200 REPL
006300 10,8,C,'20230210' |
|
1) Learn how to use the Code button when posting your samples
2) your sample has nothing to do with JCL. Not even a bit. That is just several text lines from an unknown source, and nothing else
3) the answer to your question is: Yes, there are several ways to do this in REXX |
|
Back to top |
|
|
Willy Jensen
Active Member
Joined: 01 Sep 2015 Posts: 735 Location: Denmark
|
|
|
|
Sure, but.. when you say insert, but do you mean replace? You mention column 10, I assume that this is just for line 006300 ? Must the change command take into account that the current value is a date, or is there a fixed value?
You can experiment with this, which is just one method:
Code: |
/* ISPF edit macro rexx */
Address Isredit "MACRO PROCESS (p)"
Address Isredit
newdate=date('s')
"change p'========' '"newdate"' 1 17 last" |
Do chceck the manual for details. |
|
Back to top |
|
|
|