Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
ISPF EDIT Macro Code explanation

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
View previous topic :: :: View next topic  
Author Message
sivatechdrive

Active User


Joined: 17 Oct 2004
Posts: 190
Location: hyderabad

PostPosted: Mon Mar 26, 2007 8:19 pm    Post subject: ISPF EDIT Macro Code explanation
Reply with quote

HI all

MY dataset is 'TEST.UES.COBOL(TEST1)'.

I had to insert a new line when 'FRANK' is found, i got the below code from a website But i dont know there to give my input dataset 'TEST.UES.COBOL(TEST1)'.

Can some one please explain me the below Code & where to mention my input dataset & other needed details

/* REXX */
STRING = 'FRANK'
ADDRESS ISPEXEC 'VPUT STRING'
ADDRESS ISPEXEC "EDIT DATASET('UESR.MY.DSN') MACRO(MYMACRO)"

MYMACRO:

ADDRESS ISREDIT
ADDRESS ISPEXEC "VGET STRING"
LINE3 = 'BLUE'
LINE2 = 'RED'
LINE1 = 'ORANGE'
"F" STRING
IF RC > 0 THEN EXIT
"LINE_AFTER .ZCSR = (LINE3)"
"LINE_AFTER .ZCSR = (LINE2)"
"LINE_AFTER .ZCSR = (LINE1)"
"END"
EXIT
Back to top
View user's profile Send private message

William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Mon Mar 26, 2007 8:47 pm    Post subject:
Reply with quote

I'd think that the dataset you want to edit goes right after the "EDIT DATASET".
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4650
Location: Raleigh, NC, USA

PostPosted: Mon Mar 26, 2007 9:30 pm    Post subject: Re: ISPF EDIT Macro Code explanation
Reply with quote

... and make sure that the code for the macro MYMACRO resides in a valid PDS allocated in your TSO session to the SYSPROC DD.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IBEGENER RETURN CODE 12 anilkumar922 All Other Mainframe Topics 1 Wed Dec 13, 2017 11:41 am
No new posts Finding the plan when code compiled u... Ahemad DB2 1 Fri Dec 01, 2017 6:38 pm
No new posts Strange Code amitc23 COBOL Programming 6 Tue Nov 28, 2017 11:25 am
This topic is locked: you cannot edit posts or make replies. ISREDIT Macro is not returning back t... nico_neoz CLIST & REXX 21 Sat Nov 18, 2017 7:40 pm
No new posts interesting explanation of DB concurr... dbzTHEdinosauer General Talk & Fun Stuff 0 Thu Oct 26, 2017 3:02 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us