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

Line number updation in editor


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

New User


Joined: 19 Jun 2009
Posts: 27
Location: Chennai

PostPosted: Wed Nov 18, 2009 6:17 pm
Reply with quote

Is there any way to set a value to the line number in the editor window using REXX? If it is possibe, post the REXX code to implement it.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Wed Nov 18, 2009 6:29 pm
Reply with quote

why would You want to override the line numbers?
isn' t RENUM enough
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Wed Nov 18, 2009 7:07 pm
Reply with quote

Ganesh,

are you referring to the editor window LINE NUMBER, which is ALWAYS in sequential order starting from 1.

or are you refering to the PAGE/LINE NUMBER of a source module?

If you are referring to the first, no.

If you are referring to the second, yes.

as for at the REXX code to change, you can either follow Enrico's suggestion
or
modify the data in columns 1 thru 6 / or / 73 thru 80 depending upon the EDIT Profiles NUM parm.
Back to top
View user's profile Send private message
Ronald Burr

Active User


Joined: 22 Oct 2009
Posts: 293
Location: U.S.A.

PostPosted: Wed Nov 18, 2009 8:53 pm
Reply with quote

Ganesh,
You really, really need to articulate your request in a more definitive manner. What, exactly, is it that you are trying to do?
Are you trying to run an edit macro in which you want to set some variable to the value of the line number of the line on which the cursor is positioned at the time the macro is invoked? If so, WHICH line number? the ISPF (sequential) line number or the Program Source line number? If the program source line number, which one? COBOL line number (cols 1-6) or STD line number (last 8 bytes)? What if it is blank? or non-numeric?
Are you trying to actually CHANGE the line number of the line on which the cursor is positioned at the time the macro is invoked? If so, which one?
etc. etc. etc.
Back to top
View user's profile Send private message
GaneshMF

New User


Joined: 19 Jun 2009
Posts: 27
Location: Chennai

PostPosted: Wed Nov 18, 2009 10:47 pm
Reply with quote

Thanks for your reply.

I wish to clear the editor window in a single command..
So I thought of introducing 'D99999' in the first editor window line number.

Thats what i need to populate the line number with a value (D99999).
Back to top
View user's profile Send private message
GaneshMF

New User


Joined: 19 Jun 2009
Posts: 27
Location: Chennai

PostPosted: Wed Nov 18, 2009 10:49 pm
Reply with quote

@Dick Brenholtz

Thanks for your reply.

I wish to override the editor window line number..
As I said in the previous reply, I wish to clear the editor screen in one command. So I thought of overriding the first line number.
Back to top
View user's profile Send private message
GaneshMF

New User


Joined: 19 Jun 2009
Posts: 27
Location: Chennai

PostPosted: Wed Nov 18, 2009 10:52 pm
Reply with quote

@ Ronald Burr

Thanks for your reply.

I need to override the sequential line number at the left of the editor window when the labels are usually set.. As i have said in the previous reply, I need to use that for clearing the screen.
Back to top
View user's profile Send private message
Ronald Burr

Active User


Joined: 22 Oct 2009
Posts: 293
Location: U.S.A.

PostPosted: Wed Nov 18, 2009 11:11 pm
Reply with quote

I think that if you had stated your objective in your original post, you could have/would have received an answer ages ago. Instead, you tried to ask people how to achieve something that you thought was necessary to accomplish that objective. Assuming that there is only one way to accomplish something is usually a mistake. That being said. . .

You can "clear the screen" in any edit session by
a) entering "X ALL;DEL ALL X" on the command line, or
b) writing a REXX edit Macro to do the same, and invoking it.
The REXX edit macro Could be as simple as
Code:
/* REXX */                 
 ADDRESS ISPEXEC           
  "CONTROL ERRORS RETURN" 
  "ISREDIT MACRO NOPROCESS"
  "ISREDIT DEL 1 .ZLAST"   
 RETURN


It is NOT necessary to know what line numbering options are in effect, nor what the line numbers are, if all you want to do is delete them all.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Wed Nov 18, 2009 11:15 pm
Reply with quote

Ganesh,

there are many ways to do this; an easy way is:
ISREDIT EXCLUDE ALL
ISREDIT DELETE ALL EXCLUDED

or
X ALL
Del ALL X

and a label is the only way I know of 'modifying' a 'line number'
and that is really not a modification; the line number stays intact.

had you bothered to mention what you goal was, this thread would have
been much smaller. probably one reply.
Back to top
View user's profile Send private message
Pedro

Global Moderator


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

PostPosted: Thu Nov 19, 2009 4:42 am
Reply with quote

regarding:
Code:
X ALL
Del ALL X


I think this is simpler:
Code:
DEL ALL NX

Why do people remember the X version better?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Nov 19, 2009 5:33 am
Reply with quote

our soul wish in life is Not to be eXcluded icon_wink.gif

But, if the goal is to clear the screen - read delete all lines;

to assume that there are no excluded lines at time of macro invocation
would leave the workarea with excluded lines if one were to simply
delete all NX.
Back to top
View user's profile Send private message
Pedro

Global Moderator


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

PostPosted: Thu Nov 19, 2009 6:05 am
Reply with quote

Ganesh said:
Quote:
So I thought of introducing 'D99999' in the first editor window line number.


What was wrong with typing D99999?

>> update
Sorry, I missed the " using REXX" in first post
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 400
Location: Mumbai

PostPosted: Thu Nov 19, 2009 7:05 am
Reply with quote

If I may make one more comment on stating the original problem (not to belabor the point, but to clarify it)...

When you start a topic, it is best to state exactly what you are trying to accomplish rather than ask how to implement a proposed design you have.

I know that sounds a little arrogant of me, but as you've seen, the best way to accomplish your ultimate goal had nothing to do with your proposed solution and no one could have known what you wanted to accomplish by the original description. A good reference for these types of problems is catb.org/esr/faqs/smart-questions.html
Back to top
View user's profile Send private message
GaneshMF

New User


Joined: 19 Jun 2009
Posts: 27
Location: Chennai

PostPosted: Sat Nov 21, 2009 12:22 am
Reply with quote

Thank you for all your replies.

I am clear now of what i need to post for making others understand what the problem is and getting a solution.

Sorry for the inconvience caused.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Sat Nov 21, 2009 12:30 am
Reply with quote

a general message to all the illiterates in this forum
UPDATION
is not a word. It may mean something in your chatroom dribble
but in the real world, it is UPDATE which is a verb.

If you just have to use a noun, then use modification.

an update does not occur until it becomes a part of a permenant repository
(saved/written to a file/disc).
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10886
Location: italy

PostPosted: Sat Nov 21, 2009 12:32 am
Reply with quote

what about UPDATATION... seen it around here
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 Write line by line from two files DFSORT/ICETOOL 7
No new posts Pulling a fixed number of records fro... DB2 2
No new posts Substring number between 2 characters... DFSORT/ICETOOL 2
No new posts Generate random number from range of ... COBOL Programming 3
No new posts Increase the number of columns in the... IBM Tools 3
Search our Forums:

Back to Top