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

Automatic labelling


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

New User


Joined: 21 Jun 2007
Posts: 14
Location: India

PostPosted: Tue Jul 22, 2008 4:43 pm
Reply with quote

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
View user's profile Send private message
Garry Carroll

Senior Member


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

PostPosted: Tue Jul 22, 2008 5:00 pm
Reply with quote

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
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Tue Jul 22, 2008 5:00 pm
Reply with quote

I would suggest an ISPF edit macro for this case.

O.
Back to top
View user's profile Send private message
joejacob

New User


Joined: 21 Jun 2007
Posts: 14
Location: India

PostPosted: Tue Jul 22, 2008 5:05 pm
Reply with quote

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
View user's profile Send private message
Garry Carroll

Senior Member


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

PostPosted: Tue Jul 22, 2008 5:18 pm
Reply with quote

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. icon_rolleyes.gif

Garry icon_confused.gif
Back to top
View user's profile Send private message
joejacob

New User


Joined: 21 Jun 2007
Posts: 14
Location: India

PostPosted: Tue Jul 22, 2008 5:24 pm
Reply with quote

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
View user's profile Send private message
superk

Global Moderator


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

PostPosted: Tue Jul 22, 2008 6:48 pm
Reply with quote

2.1.1 What Are Edit Macros?.
Back to top
View user's profile Send private message
Pedro

Global Moderator


Joined: 01 Sep 2006
Posts: 2547
Location: Silicon Valley

PostPosted: Tue Jul 22, 2008 9:46 pm
Reply with quote

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
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 AUTOMATIC PLAN CREATION IN REXX CLIST & REXX 6
No new posts Automatic delete after n entries in t... DB2 3
No new posts Doing automatic transaction posting i... Testing & Performance 4
No new posts Automatic process to identify jobs th... TSO/ISPF 5
No new posts Automatic Copy/REPL from DSLIST panel. TSO/ISPF 1
Search our Forums:

Back to Top