COBOL - Calling alternate entry points



Desenvolvido por DORNELLES Carlos Alberto - Analista de Sistemas - Brasília DF. - cad_cobol@hotmail.com

COBOL - Structuring complex applications - Calling alternate entry points

Enterprise COBOL for z/OS, Version 4.2, Programming Guide


Static calls to alternate entry points work without restriction.

Dynamic calls to alternate entry points require the following elements:

  • Either explicitly specified NAME or ALIAS linkage-editor or binder control statements, or use of the NAME compiler option which generates them automatically.
  • An intervening CANCEL for any dynamic call to the same module at a different entry point.
    CANCEL causes the program to be invoked in initial state when it is called at a new entry point.

You can specify another entry point at which a program will begin running by using the ENTRY label in the called program.
However, this method is not recommended in a structured program.


© Copyright IBM Corp.