> -----Original Message----- > From: IBM Mainframe Discussion List > [mailto:[EMAIL PROTECTED] On Behalf Of Ludmila Koganer > Sent: Wednesday, August 22, 2007 3:23 PM > To: [email protected] > Subject: Re: Calling a AMODE 31 program from AMODE 64 > > > Thanks for the quick response. > OK here is my code. > I have two simple starter programs, PGM64A in AMODE 64 and > PGM A in AMODE 31 > I need to pass a field CRITDTE to PGMA and return a return > value from PGMA. > The code is below. > PGM64A CSECT > PGM64A AMODE 64 > PGM64A RMODE 31 > BAKR 14,0 > LARL 13,SAVEAREA > LARL 12,PGM64A > USING PGM64A,12 > LGHI 15,0 > LLGF 1,CRITDTE > LLGT 15,=V(PGMA) > SAM31 > BASR 14,15 > PR , > > CRITDTE DS CL8 > SAVEAREA DS 0D'0',F'0',C'F1SA' > > LTORG > END PGM64A. > > I can BASR to PGMA no problem. Every time I try to modify the > inbound parm, > I get S0C4 / Reson 11. I am not sure where I am coding incorrectly. > Following a few other posts I tried difft combinations of Loaing parm > including LA, LLGT but it is not working. Since if I don't > alter the inbound > block it runs, I am making some glorious mistake on passing > the parm. I > cant seem to figure out,. > > > > pgmA is a vsery simple subroutine that only has a > L 3,0(1) > LA 5,UPDTXT > MVC 0(7,3),0(5) =======>Receive inbound value in Reg 3 > and update with > the value in updtxt > besides the std prolog and epilog. > > Regards, > Ludmil
LLGF does not load the address of CRITDATE into R1. It loads the value contained in the first 4 bytes of CRITDATE into R1. I don't see where CRITDATE is initialized. Also your comments on the MVC instruction say the exact opposite of what is happening. The receiving field is the first field. You are moving the data at UPDTXT into the storage pointed to by R3. And R3 contains who-knows-what which was originally in the first 4 bytes of CRITDATE. -- John McKown Senior Systems Programmer HealthMarkets Keeping the Promise of Affordable Coverage Administrative Services Group Information Technology The information contained in this e-mail message may be privileged and/or confidential. It is for intended addressee(s) only. If you are not the intended recipient, you are hereby notified that any disclosure, reproduction, distribution or other use of this communication is strictly prohibited and could, in certain circumstances, be a criminal offense. If you have received this e-mail in error, please notify the sender by reply and delete this message without copying or disclosing it. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html

