Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

finding which cobol paragaph we are in

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
Ajay Baghel

Active User


Joined: 25 Apr 2007
Posts: 205
Location: Bangalore

PostPosted: Fri Sep 12, 2008 9:43 pm    Post subject: finding which cobol paragaph we are in
Reply with quote

Hi,

Is there any command to know which cobol paragraph we are in depending on the current cursor location?

Many times while analysing the abend, we give a Find on the error message. Now here, the paragraphs are quite long. (generally contain a lot of commented code) and it requires a lot of F7 to reach the beginning of paragraph name in which the error message was present.

So, is there anyway to reach the beginnning of current paragph in which the error message is present?

Any ideas?

-Ajay
Back to top
View user's profile Send private message

Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Fri Sep 12, 2008 9:55 pm    Post subject:
Reply with quote

Code:
x '*' 7 7 all          -- this will hide all the comments
f p'^' 8 11 nx prev        -- this will find the previous para or section name
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Fri Sep 12, 2008 10:08 pm    Post subject:
Reply with quote

Hi Ajay,

You may also want to put ".A" in the line your cursor is at before you do the "f"ind and use l .a to find your way back.
Back to top
View user's profile Send private message
Ajay Baghel

Active User


Joined: 25 Apr 2007
Posts: 205
Location: Bangalore

PostPosted: Wed Sep 17, 2008 2:38 am    Post subject: Reply to: finding which cobol paragaph we are in
Reply with quote

Quote:
f p'^' 8 11 nx prev -- this will find the previous para or section name


In my case,
f p'^'
is not working.

It says not found.

I went through ISPF qw help on find command and used the symbol having hex code of X'5F' on mainframe instead of '^' to refer to any non-blank character in the picture string. (This symbol is not appearing on the keyboard. That's why i am referring its hex code in the post).

So i used the below command
Code:
f p'special-symbol' 8 11 nx prev     


Where special-symbol is that symbol.

Thanks everybody!

-Ajay
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts finding delayed job/s in OPC jzhardy IBM Tools 0 Mon May 29, 2017 9:04 am
This topic is locked: you cannot edit posts or make replies. Cobol GUI (like Editor) Kala Mainframe COBOL Programming 14 Wed May 10, 2017 12:30 pm
No new posts IMS T-Pipe queue counts in a COBOL Pr... Siva NKK Kothamasu IMS DB/DC 0 Tue May 09, 2017 6:31 pm
No new posts COBOL Code Parsers and Lineage Establ... balimanja COBOL Programming 2 Tue May 02, 2017 3:30 am
No new posts Cobol upgrade - source code missing f... gthmrj IBM Tools 1 Wed Apr 26, 2017 6:04 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us