How to get data-set name implicitly in REXX?

Time Sharing Option, Interactive System Productivity Facility and REstructured eXtended eXecutor

Moderator: mickeydusaor

Post Reply
Manoj
Registered Member
Posts: 33
Joined: Wed Jul 17, 2013 9:10 am

How to get data-set name implicitly in REXX?

Post by Manoj »

When I am inside a member in a PDS, that is Editing/Viewing) a dataset or PDS with ISPF EDIT - then I'll execute a REXX routine. I need to pass the member name like 'MY.PDS.(MEM)' into a variable. I need to pass it implicitly instead of getting it from user. How to do that? I'm using this but in vain:

Code: Select all

ADDRESS ISREDIT
"ISREDIT MACRO"
"ISREDIT(MEM) = DATASET"
SAY MEM
User avatar
Anuj Dhawan
Founder
Posts: 2802
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: How to get data-set name implicitly in REXX?

Post by Anuj Dhawan »

You code looks fine to me - can you please post the TRACE? You can include TRACE like this:

Code: Select all

/* REXX */                      
TRACE I                         
ADDRESS ISREDIT                 
"ISREDIT MACRO"                 
"ISREDIT (MEM) = DATASET"       
SAY MEM
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
Manoj
Registered Member
Posts: 33
Joined: Wed Jul 17, 2013 9:10 am

Re: How to get data-set name implicitly in REXX?

Post by Manoj »

Code: Select all

3 *-* ADDRESS ISREDIT
      4 *-* "ISREDIT MACRO"
        >L>   "ISREDIT MACRO"
        +++ RC(20) +++
      5 *-* "ISREDIT (MEM) = DATASET"
        >L>   "ISREDIT (MEM) = DATASET"
        +++ RC(20) +++
      6 *-* SAY MEM
        >L>   "MEM"
 MEM
 ***
User avatar
Anuj Dhawan
Founder
Posts: 2802
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: How to get data-set name implicitly in REXX?

Post by Anuj Dhawan »

With that, it looks like you are missing the /*REXX*/ in your code, are you? Please check.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
Manoj
Registered Member
Posts: 33
Joined: Wed Jul 17, 2013 9:10 am

Re: How to get data-set name implicitly in REXX?

Post by Manoj »

Silly me - yes, I was using wrong pairs of /*.

Thank you.
User avatar
Anuj Dhawan
Founder
Posts: 2802
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: How to get data-set name implicitly in REXX?

Post by Anuj Dhawan »

Glad, you got it working! :)
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “TSO, ISPF & REXX (Do you still do CLIST?!).”