IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Locate a label set by anothet macro


IBM Mainframe Forums -> TSO/ISPF
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
swathykrishnan

New User


Joined: 01 Oct 2010
Posts: 43
Location: Bangalore

PostPosted: Thu Sep 03, 2015 12:32 pm
Reply with quote

Hello,

I am Setting a Label .A for a line using the command
Code:
"ISREDIT (LNM) = LINENUM .ZCSR"     
"ISREDIT LABEL (LNM) = .A" 


But when I try to locate the Label using another macro(without exiting the current Screen) ist giving an error message

Code:
"ISREDIT LOCATE .A"     
 
Command in error . : LOCATE .A                       
                                                     
 Invalid parameter                                   
 Invalid line number or label or LOCATE keyword.     
                                                     
   Error message ID . : ISRE066                       
                                                     
   Last return code . : 20   


And the same will work if we write both codes in same macro.
I have tried by saving the linenum to Profile variable and locate the line using linenum in next macro. But that also returned the same error.
Back to top
View user's profile Send private message
RahulG31

Active User


Joined: 20 Dec 2014
Posts: 446
Location: USA

PostPosted: Thu Sep 03, 2015 7:30 pm
Reply with quote

Can you make sure that it is the problem with Locate and Not the Label ?

May be the label is Not set and that is why it's not able to locate?

Can you check please?
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1306
Location: Vilnius, Lithuania

PostPosted: Thu Sep 03, 2015 7:52 pm
Reply with quote

Are your macros calling each other, i.e.

from the Edit command-line:
Code:
"macro"

from "macro":
Code:
"isredit submacro"

from "submacro":
Code:
"isredit another"

The answer is almost certainly yes, which means that you urgently need to read the chapter about the LABEL command in the manual, because that will explain everything.

And in fact, even if you call them sequentially, you will run into the same problem, that, after reading the manual, turns out to be not a problem at all, because it's working as designed!
Back to top
View user's profile Send private message
swathykrishnan

New User


Joined: 01 Oct 2010
Posts: 43
Location: Bangalore

PostPosted: Fri Sep 04, 2015 12:38 pm
Reply with quote

Hi All,

I am using two different macros. In one macro i will set the Label as .A. In another one I will try to locate the Label .A. And as I said earlier ist working properly if I use the command LOCATE LABEL .A in the first macro itself.

I did this after reading the Manual www-01.ibm.com/support/knowledgecenter/SSLTBW_1.13.0/com.ibm.zos.r13.f54em00/labels.htm%23labels
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Fri Sep 04, 2015 2:44 pm
Reply with quote

So the first macro does not call the second macro? If that is the case you did NOT read all of that document - especially the section Referring to labels
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> TSO/ISPF

 


Similar Topics
Topic Forum Replies
No new posts PRINTOUT macro PL/I & Assembler 0
No new posts create rexx edit Macro that edits the... CLIST & REXX 3
No new posts Issues with executing a REXX MACRO th... TSO/ISPF 4
No new posts Need to locate SMF Exit IEFUJI All Other Mainframe Topics 3
No new posts Facing issue in Run Edit Macro Job CLIST & REXX 9
Search our Forums:

Back to Top