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

how to create own command in ISPF.


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

New User


Joined: 31 Aug 2007
Posts: 5
Location: Mumbai

PostPosted: Thu Jun 18, 2009 1:22 pm
Reply with quote

Hi,

I have written a code in REXX to check jcl syntax(same as JSCAN). Now I want that when I open a JCL and write JSC it should start checking the syntax. So, please let me know in detail how to create own command(like JSC) and where to keep it.

Thanks
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jun 18, 2009 1:35 pm
Reply with quote

It will need to reside in the concatenation of either SYSEXEC or SYSPROC.
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1306
Location: Vilnius, Lithuania

PostPosted: Thu Jun 18, 2009 2:45 pm
Reply with quote

expat wrote:
It will need to reside in the concatenation of either SYSEXEC or SYSPROC.


Not necessarily, it can also be in SYSUEXEC, SYSUPROC or be in a command table with a

Code:
SELECT CMD(EX 'PRINO.EXEC(MYCMD)')
as the action...
Back to top
View user's profile Send private message
Kumar Prabhat Ranjan

New User


Joined: 31 Aug 2007
Posts: 5
Location: Mumbai

PostPosted: Thu Jun 18, 2009 2:56 pm
Reply with quote

Thanks for your quick response. Could you please explain the whole process.
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1306
Location: Vilnius, Lithuania

PostPosted: Thu Jun 18, 2009 3:22 pm
Reply with quote

Very puzzled icon_question.gif

You are able to write something that is presumably pretty complex, as parsing JCL is pretty complicated, but you don't know how to invoke commands?

My I suggest you give the command
Code:
TSO HELP ALTLIB
or check the appropriate TSO manual.
Back to top
View user's profile Send private message
Marso

REXX Moderator


Joined: 13 Mar 2006
Posts: 1353
Location: Israel

PostPosted: Thu Jun 18, 2009 5:28 pm
Reply with quote

Kumar Prabhat Ranjan wrote:
I have written a code in REXX to check jcl syntax(same as JSCAN). Now I want that when I open a JCL and write JSC it should start checking the syntax.

You should have written your program as an EDIT MACRO from the beginning!

What will happen now is that you will open a JCL, makes changes in it, then run your program. As your program is not a macro, it will read the JCL from the disk and check it. Unsaved changes will not be checked!

The program you wrote should be an edit macro, meaning it can read the lines that are displayed on the screen, including unsaved modifications.

Search the forum for more info about macros and read this book (there are a few interesting examples).
Back to top
View user's profile Send private message
d_pansare

New User


Joined: 25 Apr 2009
Posts: 20
Location: Pune

PostPosted: Thu Jun 25, 2009 11:47 am
Reply with quote

I hope I have understood what exactly you want to do. Nevertheless, I will just reiterate your query and then pen down the solution which fits your need..

It seems you have created REXX program to do the job scanning and you want to invoke this program with the help of ISPF command. So that is the case, then here goes the solution:

As mentioned by fellow forum member, you need to add this member to either SYSEXEC or SYSPROC. All you got to do is copy this REXX program to PDS where you would like to keep your rexx execs. Now, go to start 3.4 and list down all the datasets under your tso id i.e. RACFid.*. Once you get the whole list, shoot a command M SYSEXEC to find the PDS which contains the sysexec member. After this, open sysexec in edit and add your rexx library name to sysexec in the first line. Save it, log off and log in again.

So here you go.. you are all set to use the member name as new command...

---------------------------------------
Always get back to this forum if you face any issues....
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jun 25, 2009 11:55 am
Reply with quote

d_pansare

Quote:
you need to add this member to either SYSEXEC or SYSPROC

Plus the additional DD names provided by Prino

Quote:
shoot a command M SYSEXEC to find the PDS which contains the sysexec member

You have obviously tried this with great success icon_evil.gif

Also, did you bother reading the post by Marso.
Back to top
View user's profile Send private message
d_pansare

New User


Joined: 25 Apr 2009
Posts: 20
Location: Pune

PostPosted: Thu Jun 25, 2009 12:22 pm
Reply with quote

Quote:
You have obviously tried this with great success icon_eek.gif


I guess this command (M membname ) is somehting which is not product dependent. It is inherently present in all mainframes ( I meant ISPF sessions.. icon_confused.gif ).. Also about Marso' s post, I assumed that rexx member is already in edit macro and then suggested the possible suggestion...

Anyways, it is true that we may not have sysexec and sysprocs in user ispf profile libraries all the time.. and hence i am still struggling to find the way out to add user exec libraries to system sysexecs or sysproc libraries...

Does anyone would like to throw some light on the other alternatives to get this done...??
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1306
Location: Vilnius, Lithuania

PostPosted: Thu Jun 25, 2009 1:21 pm
Reply with quote

You are what we call in Dutch "talking out of your neck" - i.e. complete and utter nonsense, such as
d_pansare wrote:
... rexx member is already in edit macro ...
and
d_pansare wrote:
... we may not have sysexec and sysprocs in user ispf profile libraries all the time ...

Please start reading manuals before commenting on matters that are obviously way beyond your clearly very limited understanding!
Back to top
View user's profile Send private message
d_pansare

New User


Joined: 25 Apr 2009
Posts: 20
Location: Pune

PostPosted: Thu Jun 25, 2009 1:43 pm
Reply with quote

Quote:
d_pansare wrote:
... we may not have sysexec and sysprocs in user ispf profile libraries all the time ...

Please start reading manuals before commenting on matters that are obviously way beyond your clearly very limited understanding! icon_redface.gif



All I meant by this was.. not everywhere you get the sysexec and sysproc.. there could be somehing else ( I have stated it as I have seen it on some mainfranes..)..

and yeah I did ask that how do we add the user exec libraries to system exec libraries if sysexec and sysproc is not up there.. as you know to read such huge manuals to understand this is gonaa take ages...so was just looking for shorter way... icon_cool.gif
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Thu Jun 25, 2009 2:02 pm
Reply with quote

Quote:
not everywhere you get the sysexec and sysproc


due to different setup standards a SYSEXEC dd might be missing never the SYSPROC one

the only tso logon procedure whitout the SYSPROC DD would be the "REAL EMERGENCY ONE"
just the IKJEFT01 and nothing else to be sure not to get any jcl errors at logon
- seen it, done it, used it, the customer was happy that I had strongly insisted in having one
- they had fouled up a catalog and no logon proc would work
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jun 25, 2009 3:49 pm
Reply with quote

prino wrote:
You are what we call in Dutch "talking out of your neck" - i.e. complete and utter nonsense

And in Engish we use a rather different part of the anatomy in this phrase icon_lol.gif
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Thu Jun 25, 2009 5:05 pm
Reply with quote

Quote:
You are what we call in Dutch "talking out of your neck"


Quote:
And in Engish we use a rather different part of the anatomy in this phrase


considering 'where the head is' at this time, both phrases refer to the same area of anatomy.
Back to top
View user's profile Send private message
Pedro

Global Moderator


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

PostPosted: Thu Jun 25, 2009 10:04 pm
Reply with quote

Quote:
Once you get the whole list, shoot a command


I do not condone violence. Other than that, I do not know what it means. perhaps you meant: "issue a command"
Back to top
View user's profile Send private message
Pedro

Global Moderator


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

PostPosted: Fri Jun 26, 2009 4:40 am
Reply with quote

Quote:
I guess this command (M membname ) is somehting which is not product dependent. It is inherently present in all mainframes ( I meant ISPF sessions.. icon_confused.gif ).


The 'M' command is in all sites, but your use of 'SYSEXEC' is not. It likely is only a local convention.

To add rexx programs to your environment, there are several alternatives:

- The logon proc will allocate the SYSPROC or SYSEXEC dd names and specify the system dataset names. If your system programmers support multiple logon procs, you might use one with more customization. Most people cannot add to the logon proc.

- Some logon procs execute a clist or exec so that you can add your private customization. There is no universal convention for names (hence your use of a SYSEXEC member does not work for us).

- The default logon panel has a 'command' field where you can launch your private customization exec.

- After logon, you can explicitly invoke your private customization exec.

- You may be able to add customization to the invocation of an application.

- You can use ALTLIB ACT command of TSO to add an SYSUEXEC or SYSUPROC dd to the local environment. (I could not get it work for across split screens).

- To add an exec to TSO session, throughout all of your ISPF environments, the only sure-fire way that I know is to add your dataset to the SYSPROC or SYSEXEC concatenation. Or copy your member to dataset already in concatenation.

- you can compile and link to create a load module (requires rexx compiler)
* add load module to your STEPLIB.

* specify load dsn using the TSOLIB command.

* concat load dsn to ISPLLIB or ISPLOAD before starting ISPF
Back to top
View user's profile Send private message
d_pansare

New User


Joined: 25 Apr 2009
Posts: 20
Location: Pune

PostPosted: Fri Jun 26, 2009 1:32 pm
Reply with quote

Quote:

I do not condone violence. Other than that, I do not know what it means. perhaps you meant: "issue a command"


Yeah.. I did mean "issue a command"
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 RACF - Rebuild SETROPTS command which... All Other Mainframe Topics 3
No new posts Routing command Address SDSF to other... TSO/ISPF 2
No new posts Looking for a little history of ISPF ... TSO/ISPF 5
No new posts DTL - how to define key with stacked ... TSO/ISPF 3
No new posts LTJ command CA Products 4
Search our Forums:

Back to Top