IBM MAINFRAME HELP & SUPPORT FORUMS
Technical Forums for IBM Mainframe Applications like COBOL, JCL, CICS, DB2, FileAid, DFSORT, Endevor, Xpediter, CoolGen, CA-7&11, AbendAid, IMS, IDMS, PL/I, MqSeries, SyncSort, Assembler, ChangeMan, Easytrieve, InterTest, REXX, CLIST etc...
 

Automatic labelling

THIS IS AN ARCHIVE FORUM: CLICK HERE TO GO TO THE ORIGINAL TOPIC

 
       IBMMAINFRAMES.com - IBM Mainframe Support Forums Index -> TSO/ISPF
View previous topic :: View next topic  
Author Message
joejacob



Joined: 21 Jun 2007
Posts: 14
Location: India

Posted: Tue Jul 22, 2008 4:43 pm    Post subject: Automatic labelling  

I need to develop a tool to search for a particular working storage variable in a member of PDS.

When the cursor is placed on the working storage variable to be searched and the user presses a PF key say F4 the the cursor should go to the declaration of the working storage variable and when the user presses the same key again the cursor should go to the subsequent occurrence of the same variable. Finally when the user presses another PF key the cursor should go to the initial position.

This is similar to the search for a word conducted in an editor. But in this case the program should read the working storage variable from the cursor position instead of giving the string to be searched as an input.
Back to top  
Garry Carroll



Joined: 08 May 2006
Posts: 166
Location: Dublin, Ireland

Posted: Tue Jul 22, 2008 5:00 pm    Post subject:  

Why would you want to do this when TSO Browse/Edit/View already provides FIND and RFIND which give this sort of functionality?

This looks like homework ?

Garry.
Back to top  
ofer71



Joined: 27 Dec 2005
Posts: 1930
Location: Israel

Posted: Tue Jul 22, 2008 5:00 pm    Post subject:  

I would suggest an ISPF edit macro for this case.

O.
Back to top  
joejacob



Joined: 21 Jun 2007
Posts: 14
Location: India

Posted: Tue Jul 22, 2008 5:05 pm    Post subject: Reply to: Automatic labelling  

I need to develop this because in find user has to type the variable to be searched in the command section and press F5 instead I need to search the variable by placing the cursor under it and just press the PF key so tht it becomes more easier.

I'm new to REXX so please explain the commands that can be used for this.
Back to top  
Garry Carroll



Joined: 08 May 2006
Posts: 166
Location: Dublin, Ireland

Posted: Tue Jul 22, 2008 5:18 pm    Post subject:  

Quote: instead I need to search the variable by placing the cursor under it and just press the PF key so tht it becomes more easier.

So, under your scenario, the user has to read through the text until they see the exact string they want - possibly several pages down, THEN position the cursor on it and THEN start the PF key searching?? This hardly seems Quote: more easier

ofer71's suggestion of using an ISPF Edit Macro would probably suit, but you still have to get the user to initiate this someway. :roll:

Garry :?
Back to top  
joejacob



Joined: 21 Jun 2007
Posts: 14
Location: India

Posted: Tue Jul 22, 2008 5:24 pm    Post subject:  

I need this tool particularly for debugging purpose suppose if he come across a variable and he needs to see its declaration and picture clause on a key press the cursor has to go to the declaration. This and on subsequent presses it should go to the next occurrence.

Can you explain how ISPF Edit Macro works?
Back to top  
superk



Joined: 26 Apr 2004
Posts: 3265
Location: Charlotte,NC USA

Posted: Tue Jul 22, 2008 6:48 pm    Post subject: Reply to: Automatic labelling  

2.1.1 What Are Edit Macros?.
Back to top  
Pedro



Joined: 01 Sep 2006
Posts: 510
Location: work

Posted: Tue Jul 22, 2008 9:46 pm    Post subject: Reply to: Automatic labelling  

Quote: I needthis tool particularly for debugging purpose suppose if he come across a variable and he needs to see
It is not clear if you need or he needs... however I sort of see the benefit.

Study the ISPF Edit manual. I suggest to use:
1. CURSOR macro instruction to determine line and column of cursor location.
2. LINE macro instruction to get the data into rexx variable
3. UP MAX macro instruction
4. EXCLUDE ALL to hide all lines
5. Use the FIND ALL macro instruction to find occurrences of the search text.

The cursor should be at the first instance, which frequently is the variable declaration. Use F5 to move cursor to next instance of the variable.

Use RESET command to show other lines.
Back to top  
 
       IBMMAINFRAMES.com - IBM Mainframe Support Forums Index -> TSO/ISPF
Page 1 of 1
THIS IS AN ARCIVE FORUM IN READ ONLY MODE. IF YOU WANT TO ASK YOUR DOUBTS USE THE ACTUAL FORUM