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
 
How to locate error flaged lines in initial macro?

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

New User


Joined: 05 Jun 2006
Posts: 19

PostPosted: Fri Jul 22, 2011 5:40 pm    Post subject: How to locate error flaged lines in initial macro?
Reply with quote

Hi,
Is there any other way or command to display the line with an error flag after locating it using LOCATE FIRST ERROR command in initial macro as I can not use DISPLAY_LINES command in this case.

Regards,
Dubasir.
Back to top
View user's profile Send private message

dubasir

New User


Joined: 05 Jun 2006
Posts: 19

PostPosted: Mon Jul 25, 2011 10:36 am    Post subject: How to locate error flaged lines in initial macro?
Reply with quote

Even I cannot locate the error lines using LOCATE command in this case.
Please tell me how can I locate the error lines.

Regards,
Dubasir.
Back to top
View user's profile Send private message
Garry Carroll

Active Member


Joined: 08 May 2006
Posts: 998
Location: Dublin, Ireland / Edinburgh, Scotland

PostPosted: Mon Jul 25, 2011 11:54 am    Post subject:
Reply with quote

It might help if we knew where you wanted to find these error flags and how you propose to find them.

icon_rolleyes.gif

You just missed psychic day...

Garry.
Back to top
View user's profile Send private message
Stefan

Active User


Joined: 12 Jan 2006
Posts: 110
Location: Germany

PostPosted: Mon Jul 25, 2011 12:13 pm    Post subject: Re: How to locate error flaged lines in initial macro?
Reply with quote

dubasir wrote:
Hi,
Is there any other way or command to display the line with an error flag ...

I don't understand what you mean by "display the line". In the Edit macro manual you can read "Remember that commands referencing display values (DISPLAY_COLS, DISPLAY_LINES, DOWN, LEFT, RIGHT, UP, LOCATE) are invalid in an initial macro because no data has been displayed".
You cannot display a line before ISPF Edit itself has displayed the data. What process caused the lines to be flagged as erroneous? If this is your own initial macro too, then what is the real problem?
Back to top
View user's profile Send private message
dubasir

New User


Joined: 05 Jun 2006
Posts: 19

PostPosted: Mon Jul 25, 2011 2:22 pm    Post subject: Reply to: How to locate error flaged lines in initial macro?
Reply with quote

I am calling a macro using ISPEXEC EDIT DATASET command as I wanted to edit a dataset/ member in background.
In the macro, I am performing some string replacement because of which we might get error flaged lines (If the line exceeds the reclengh after replace). So, i wanted to locate these error lines (==ERR) and do some process on these lines.
As it is an initial macro, I can not use LOCATE command to locate them. So, is there any alternative to do this?

Regards,
Dubasir.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1894
Location: UK

PostPosted: Mon Jul 25, 2011 2:25 pm    Post subject:
Reply with quote

Yes, read the line to be changed and calculate if the changed length is going to cause an error and act accordingly.
Back to top
View user's profile Send private message
dubasir

New User


Joined: 05 Jun 2006
Posts: 19

PostPosted: Mon Jul 25, 2011 2:36 pm    Post subject: Reply to: How to locate error flaged lines in initial macro?
Reply with quote

Yes, we can do this way. But, Can't we do it in other way like first replace all, then get the each error line and do the required process?

Regards,
Dubasir.
Back to top
View user's profile Send private message
Stefan

Active User


Joined: 12 Jan 2006
Posts: 110
Location: Germany

PostPosted: Mon Jul 25, 2011 3:05 pm    Post subject: Re: Reply to: How to locate error flaged lines in initial ma
Reply with quote

dubasir wrote:
Yes, we can do this way. But, Can't we do it in other way like first replace all, then get the each error line and do the required process?

No, you can't do this. When you use "change all" then ISPF Edit only returns a return code. So I propose to use "change" in a loop on every line and check the return code on each turn. Thus you get the unsuccessful changes (regardless of the reason) and can process the line as desired.
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7315

PostPosted: Mon Jul 25, 2011 4:50 pm    Post subject: Reply to: How to locate error flaged lines in initial macro?
Reply with quote

You might find this topic, "Problem in string replace in PDS members", useful. Since it is only two topics away from yours I'm going to put in the equivalent amount of effort and not put in the link. Same forum, two posts away.

After all that, I hope it does help :-)
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 IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts FTP Skip or ignore error and process ... AJAYREDDY All Other Mainframe Topics 3 Wed Sep 27, 2017 8:12 pm
No new posts Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am
No new posts exec macro in the end of edit anatol CLIST & REXX 8 Fri Sep 22, 2017 5:10 am
No new posts FUSE - IBM MQ - CICS integration error Kevin Vaz CICS 1 Mon Sep 18, 2017 4:31 pm

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