Re: MF NE 3.1 Call fails to pass linkage



On 28 Sep, 21:17, "Paul H" <NoSpamphobergNoS...@xxxxxxx> wrote:
===========================
More info - I wrote 2 very small test programs:
  ---------------------------
 calling program "call1.cbl":

       data division.
       working-storage section.
       01  link-area.
           03  link-company        pic 9(3).
           03  link-lease-no       pic 9(10).
       01  resp                    pic x value " ".
       procedure division.
           display "starting call1".
           move zeros to link-area.
           call "call2" using link-area.
           display link-area.
           display "press enter".
           accept resp.
           stop run.
  ---------------------------
called program "call2.cbl":

       data division.
       working-storage section.
       01  resp                    pic x value " ".
       linkage section.
       01  link-area.
           03  link-company        pic 9(3).
           03  link-lease-no       pic 9(10).
       procedure division.
           display "starting call2".
           display link-area.
           move all "123" to link-area.
           display link-area.
           display "press enter".
           accept resp.
           exit program.

======================="Paul H" <NoSpamphobergNoS...@xxxxxxx> wrote in message

news:48dfddc9$0$5483$bbae4d71@xxxxxxxxxxxxxxxxxxxxxx
I have one program calling another - "call using link-area." - using a
simple linkage:
01  link-area.
    03  link-company pic 9(3).
    03  link-lease-no pic 9(10).
In the called program, the same structure exists in the linkage section.
When animating, stepping thru the call, the 1st reference to link-company in
the called program gives the error "203   CALL parameter not supplied".  I
cannot find error 203 anywhere, but the call should be working correctly.  I
have current patches to my 3.1.  Any ideas what's happening?  TIA, Paul

Shouldn't the called program have the statement "procedure division
using link-area." rather than just "procedure division"?
.



Relevant Pages

  • Re: Attribute BASED and LINKAGE SECTION
    ... Isn't a LINKAGE SECTION item implicitly BASED? ... allocated storage should be assigned to ... procedure division using linkage-parm1. ... data-name-1 shall not contain a BASED clause or a REDEFINES clause. ...
    (comp.lang.cobol)
  • Re: Attribute BASED and LINKAGE SECTION
    ... procedure division using ls-parm1. ... In the LINKAGE SECTION, if a top-level item ... PROCEDURE DIVISION, then it MUST have ... in the '02 Standard Linkage Section items are not "implicitly" ...
    (comp.lang.cobol)