Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

REXX / ISREDIT issue...

Status
Not open for further replies.

ShawnStanford

Programmer
Jan 2, 2001
14
US
Wierd one here. Based on everything I can reference, the following code should step backwards through the labelled lines in a member being edited and unlabel them as it goes.

However, when it completes the labels are still visible. If I immediately run the macro again, I get no output as if there are no labels (despite the labels being visible). If I page down and run the macro again, it executes as if the labels are there (which they seem to be).

Any ideas?

Code:
/* REXX */
ADDRESS ISREDIT
"ISREDIT MACRO"

DO FOREVER
  "ISREDIT CURSOR = .ZL"
  "ISREDIT LOCATE PREV LABEL"
  IF RC \= 0 THEN LEAVE
  "ISREDIT (LINE) = LINENUM .ZCSR"
  "ISREDIT (LABNAM, NEST) = LABEL" LINE
  "ISREDIT LABEL" LINE "= ' '"
  SAY LINE LABNAM
END

"ISREDIT LOCATE 0"
RETURN 1
 
In "ISPF Edit and Edit Macros" see (under LABEL) the section "Assignment Statement Syntax". It talks there about 'nesting level'. In 34 years of dealing with SPF/ISPF, I have yet to figure this out completely and I have to sit down and study it each time I need the facility.

I suspect the labels were set with a 'level' which hides them from the macro; that is: I suspect "LOCATE LABEL PREV" is not locating any labels.

If the labels are set manually, I think you may be sunk.

There is, of course "RESET LABEL ALL" which will do the same thing.


Frank Clarke
Tampa Area REXX Programmers' Alliance
REXX Language Assn Listmaster
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top