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

Modify a JCl opened in view mode and close the file in Rexx


IBM Mainframe Forums -> CLIST & REXX
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
vijay_pampana

New User


Joined: 19 Jan 2008
Posts: 15
Location: Hyderabad

PostPosted: Wed Nov 12, 2008 10:24 pm
Reply with quote

Hi,

I have written a REXX tool which will open a PS file in view mode containing a JCL. The user can make all the changes in the JCL and submit the Job.

When I make any changes to the JCL which is opened in the view mode, I could not able to come out of the PS file. When I press CANCEL and ENTER it is giving the following error message.
INVALID COMMAND

When I open the jcl in EDIT mode was able to come out of PSfile but I want to open the file in view mode to make sure there are no changes done to the JCL's

Code:

ELSE IF RESETSWITCH = 'V' THEN DO                                 
    FILE1 = FILE1'('JOBNAME')'                                   
    [b]ADDRESS ISPEXEC "VIEW DATASET('"FILE1"')"                    [/b]
    SAY "PLEASE PROVIDE THE JOB DETAILS OF THE SUBMITTED JOB"     
    PULL DETAILS                                                 
    PARSE VAR DETAILS JOBNAM1 "(" JOBID ")" .   


Where File1 is the PS file which is open in the view mode.

Thanks
--Vijay
Back to top
View user's profile Send private message
Pedro

Global Moderator


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

PostPosted: Thu Nov 13, 2008 2:13 am
Reply with quote

Quote:
When I press CANCEL and ENTER

Sorry, that is not clear to me. Can you show us what is on the command line right before you get the error message?

Also, use the KEYS command and show us the definitions of PF3 and PF12.
Back to top
View user's profile Send private message
vijay_pampana

New User


Joined: 19 Jan 2008
Posts: 15
Location: Hyderabad

PostPosted: Thu Nov 13, 2008 9:32 am
Reply with quote

After making changes to the JCL in view mode I have submitted job. To close the view mode I press PF3 Key. The following Popup appear

Code:
Command ===>                                                 
                                                       
           You are currently in View mode:                 
                                                       
Press Enter to confirm exit from View.  No changes     
will be saved.                                         
                                                       
Enter the    END    or    EXIT    command to return to View,           
where you can use the    CREATE    or    REPLACE    primary           
commands to save your changes.                         
                                                       


When I press ENTER I am getting a error message as INVALID COMMAND

Code:
                    Invalid command
    Command ===>                                                   
                                                         
            You are currently in View mode:                 
                                                         
 Press Enter to confirm exit from View.  No changes       
 will be saved.                                           
                                                         
 Enter the    END    or    EXIT    command to return to View,           
 where you can use the    CREATE    or    REPLACE    primary             
 commands to save your changes.                           


When I press PF1 the complete error message is

Code:
Only ISPF system commands may be entered on this panel.


Please let me know if you need any further information

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

Global Moderator


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

PostPosted: Thu Nov 13, 2008 10:36 pm
Reply with quote

Sorry, I do not know why it does not work for you.

What happens when you type CANCEL instead of using PF3?
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 400
Location: Mumbai

PostPosted: Fri Nov 14, 2008 1:28 am
Reply with quote

Sounds like something on the Rexx stack.

Why are you asking the user to give you the job name and number? Why not just submit the job yourself and trap that information with outtrap()?
Back to top
View user's profile Send private message
Pedro

Global Moderator


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

PostPosted: Fri Nov 14, 2008 2:56 am
Reply with quote

Can you type RETP in the command line and see what command was invalid?
Back to top
View user's profile Send private message
vijay_pampana

New User


Joined: 19 Jan 2008
Posts: 15
Location: Hyderabad

PostPosted: Fri Nov 14, 2008 10:01 am
Reply with quote

Thanks for the replies.

HI Pedro,
I tried with PF3 key and Enter and it is giving the same error mesaage.
When I type RETP in the command line, Please find the screen output below.

Code:
Select the command                
to be retrieved                   
                    More:     +
       1.     RES                 
       2.     3                   
       3.     3.4                 
       4.     5                   
       5.     CM                 
       6.                        


I dont see any invalid command from them.

Hi Mbabu,

The jcl is opened in view mode so I want the user to submit the job with the what ever changes user requires in the JCL. As JCl is submitted by USER I could not able to trap the TSO submitted message from my Rexx program. So I am asking the user to enter those details. The problem which I am facing is coming out of JCL opened in view mode.

Thanks
--VIjay
Back to top
View user's profile Send private message
Pedro

Global Moderator


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

PostPosted: Fri Nov 14, 2008 11:34 pm
Reply with quote

Repeat: What happens when you type CANCEL instead of using PF3?
Back to top
View user's profile Send private message
vijay_pampana

New User


Joined: 19 Jan 2008
Posts: 15
Location: Hyderabad

PostPosted: Mon Nov 17, 2008 9:12 am
Reply with quote

I am getting the same error message when I use CANCEL instead of PF3

Please find the RETP command output below.

Code:
Select the command                
to be retrieved                   
                    More:     +
       1.     CANCEL               
       2.     RES                 
       3.     3                   
       4.     3.4                 
       5.                          



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

Global Moderator


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

PostPosted: Mon Nov 17, 2008 3:50 pm
Reply with quote

Have you considered copying the base JCL into a user file and submitting from there and deleting the file after submission ?
Back to top
View user's profile Send private message
vijay_pampana

New User


Joined: 19 Jan 2008
Posts: 15
Location: Hyderabad

PostPosted: Mon Nov 17, 2008 4:12 pm
Reply with quote

Thanks Expat for the reply.

I have done that and was able to proceed with my REXX program.
I want to know why my rexx program facing problem when opening in PS file in view mode. So I thought of putting a post and know the mistake with my rexx code.

Thanks
Vijay
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 -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts HILITE on Browse mode? TSO/ISPF 2
No new posts Running REXX through JOB CLIST & REXX 13
No new posts Error to read log with rexx CLIST & REXX 11
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
Search our Forums:

Back to Top