HP3000-L Archives

October 2004, Week 1

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Jack Nickels <[log in to unmask]>
Reply To:
Jack Nickels <[log in to unmask]>
Date:
Thu, 7 Oct 2004 06:24:11 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (64 lines)
Hi All,

I have two programs. A called program (program b) and
the calling program (program a).

The way i call is as below

Progam A
--------

Setup Arguement & Key
DBFIND datasetc
IF DB-OK AND CHAIN LENGTH > 0
   DBGET Mode 5
   PERFORM UNTIL End of Chain
      Call 'program b' using Common Area
                             Parameter1
      DBGET Mode 5

   END PERFORM
END-IF


Program B
---------

$control dynamic

Performs DBFIND
DBGET MOde 5
DBUPD datasetc
Goback

Ideally, the DBGET Mode 5 in program A inside the
Perform Until chain should have been successful. But
everytime, the Perform
Until chain is exited. I am assuming that the Common
area between the called and the calling program is
causing the issue.

Is there any way for the calling program (program a)
to retain its values in the common area that may have
got affected by the called program (Program B)

One way of doing it is to store the pointer before
call in a local variable in program a. But is there a
cleaner solution to this. Am i missing something in
the $CONTROL parameters.

We will not be able to keep the common area out of the
linkage section for some reasons
Thanks for your help
-Jack



_______________________________
Do you Yahoo!?
Declare Yourself - Register online to vote today!
http://vote.yahoo.com

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2