View previous topic :: View next topic
|
Author |
Message |
HameedAli
Active User
Joined: 16 Apr 2009 Posts: 151 Location: India
|
|
|
|
My REXX ISPF Edit macro contains the following lines of code, when I run it I don't see '&VAR' in the output line
Code: |
Address "ISREDIT" "MACRO PROCESS"
L = ")SET VAR1 = &VAR"
L = STRIP(L,"B")
Address "ISREDIT" "LINE_AFTER 0 =" "'"L"'" |
is what I see, Why is it so?
How can I fix it? |
|
Back to top |
|
|
MBabu
Active User
Joined: 03 Aug 2008 Posts: 400 Location: Mumbai
|
|
|
|
Code: |
Address isredit "LINE_AFTER 0 = (L)" |
|
|
Back to top |
|
|
HameedAli
Active User
Joined: 16 Apr 2009 Posts: 151 Location: India
|
|
|
|
It worked. Thanks MBabu |
|
Back to top |
|
|
Bill Dennis
Active Member
Joined: 17 Aug 2007 Posts: 562 Location: Iowa, USA
|
|
|
|
Probably REXX is trying to substitute a value for &VAR rather than leaving it as a literal string for inserting into the data. Finding none, it makes it blank.
I know CLIST has some built-in functions to prevent substitution within a variable string (&NSTR ???). Look for something similar in REXX. |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2547 Location: Silicon Valley
|
|
|
|
Its the use of quotes that tell rexx whether to substitute the variable or whether it is just text.
But I think in this case, it is not a rexx problem, but an ISPF problem. You are probably resulting in this:
Code: |
"LINE_AFTER 0 = ')SET VAR1 = &VAR' " |
being passed along to ISPF, but ISPF does its own variable substitution. |
|
Back to top |
|
|
|