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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Constants in linkage section 2

Status
Not open for further replies.

FilipVolvo

Programmer
Jan 30, 2001
2
SE
Can someone tell me if there's is a way to define constants in the linkage section of the program?
 
Hi,

You can not define constants in the linkage section of a program because it is not its own data. The true storage remains in the calling program or on an other place you point the address to.

What you can do is using 88 levels, which are not constants, but can help you to define some general values.

Try to use copymembers for general definitions used by several programs like record descriptions, linkage areas, etc. Use self-explaining 88 levels to create something general that everybody understands.

I hope this is helpful.
 
FilipVolvo,

since the linkage section is meant as an area for two programs to communicate with eachother, i fail to see the significance of defining constants in it. As Crox indicated, it is impossible, too. However: the calling program provides a reference to parts of its working storage in the USING ... clause, so of course you can provide constants there, if you want. These constant values then are simply information passed to the called program.

Hope i was able to contribute something.

Good luck !
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top