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
 
Can We Send Index as a Parameter while calling another PROG

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
sudheer648

New User


Joined: 23 May 2005
Posts: 97
Location: Chennai

PostPosted: Thu Jun 16, 2005 10:51 am    Post subject: Can We Send Index as a Parameter while calling another PROG
Reply with quote

Hi,

Can we Send the Index as a Parameter while calling another Program.
Back to top
View user's profile Send private message

sangiah

New User


Joined: 10 Jun 2005
Posts: 62

PostPosted: Thu Jun 16, 2005 11:23 am    Post subject: Re: Can We Send Index as a Parameter while calling another P
Reply with quote

Yes index variables can be part of a communication area
Back to top
View user's profile Send private message
sudheer648

New User


Joined: 23 May 2005
Posts: 97
Location: Chennai

PostPosted: Thu Jun 16, 2005 11:36 am    Post subject: Re: Can We Send Index as a Parameter while calling another P
Reply with quote

hi sangiah,

Are you sure of it.Subscript can be sent as a parameter can index as can be sent as parmeter while calling another prg.
Back to top
View user's profile Send private message
Sangita

New User


Joined: 02 Jun 2005
Posts: 17

PostPosted: Thu Jun 16, 2005 2:32 pm    Post subject: Re: Can We Send Index as a Parameter while calling another P
Reply with quote

Hi Sudheer,

I don't think we can pass index as parameter as index is not defined in the working storage of the program so cannot be passed through
linkage.
Please corect me if I am wrong.

Regards,
Sangita
Back to top
View user's profile Send private message
sudheer648

New User


Joined: 23 May 2005
Posts: 97
Location: Chennai

PostPosted: Thu Jun 16, 2005 2:55 pm    Post subject: Re: Can We Send Index as a Parameter while calling another P
Reply with quote

Hi Sangita,

I know that we cannot pass Index as a parameter.But i want views of all Folks about the same.
Back to top
View user's profile Send private message
sangiah

New User


Joined: 10 Jun 2005
Posts: 62

PostPosted: Thu Jun 16, 2005 3:36 pm    Post subject: Re: Can We Send Index as a Parameter while calling another P
Reply with quote

Here is the example

05 WS-OCCURS PIC 999 OCCURS 10 TIMES
INDEXED BY WS-IDX.
05 WS-SUB USAGE IS INDEX.


PROCEDURE DIVISION
SET WS-IDX UP BY 1.
MOVE 100 TO WS-OCCURS(WS-IDX)
SET WS-SUB TO WS-IDX

pass WS-SUB in the communication area of calling program.
Back to top
View user's profile Send private message
sudheer648

New User


Joined: 23 May 2005
Posts: 97
Location: Chennai

PostPosted: Thu Jun 16, 2005 4:30 pm    Post subject: Re: Can We Send Index as a Parameter while calling another P
Reply with quote

Hi Sangiah,

Quote:
Here is the example

05 WS-OCCURS PIC 999 OCCURS 10 TIMES
INDEXED BY WS-IDX.
05 WS-SUB USAGE IS INDEX.


PROCEDURE DIVISION
SET WS-IDX UP BY 1.
MOVE 100 TO WS-OCCURS(WS-IDX)
SET WS-SUB TO WS-IDX

pass WS-SUB in the communication area of calling program.


Can we Pass WS-SUB in the Communication Area?????
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts KSDS and Index file in cobol deepak14450 COBOL Programming 9 Fri Dec 22, 2017 9:36 am
No new posts Unable to send mail with SMTP commands harsh.saxena579 JCL & VSAM 10 Tue Dec 12, 2017 1:58 pm
No new posts DUMMY When do I need add a DCB parameter Martylin JCL & VSAM 3 Fri Dec 08, 2017 7:20 am
No new posts Rexx to send an email without SMTP Se... upendrasri All Other Mainframe Topics 12 Sun Nov 19, 2017 7:59 pm
No new posts Calling IKJEFT01 program from Rexx upendrasri CLIST & REXX 8 Wed Nov 15, 2017 4:27 pm

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