× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Field attributes must me equal you have defined var1 as 9,5 and var2 as 10 char so rpg should be the same length and type.


Regards,

Chamara Withanachchi
IBM Certified Power System Expert
RPG Programmer
(owner of www.rpgiv.info)

WWW.RPGIV.INFO
Mob: +971 50 5698644
Tel: +971 6 5595887
chamaraw@xxxxxxxxxx
www.rpgiv.info
i want to be future ready. i want control. i want an i.


Sent from my BlackBerry® wireless device

-----Original Message-----
From: PEPITOVADECURT <pepitovadecurt@xxxxxxxxx>

Date: Wed, 22 Apr 2009 11:51:09
To: <rpg400-l@xxxxxxxxxxxx>
Subject: Re: Call a RPG program from a CL, decimals error


Hi this is the definition in RPG, is correct?
C *ENTRY PLIST
C PARM P0S9NN 309
C PARM P0S9NP 36

Thank's


J.Beckeringh@xxxxxxxxxxxxxxxxxxxxxxxxxx
escribió:
Then obviously the definition in your RPG program does not match the
definition in your CL program. Make sure that the definition in RPG
specifies packed, not zoned.

Joep Beckeringh


rpg400-l-bounces@xxxxxxxxxxxx wrote on 22-04-2009 10:56:23:

Hi I call a RPG program from a CL but a decimal data error appears when
call a RPG program.

PGM
DCL VAR(&VAR1) TYPE(*DEC) LEN(9 5)
DCL VAR(&VAR2) TYPE(*CHAR) LEN(10)
DCL VAR(&RESU) TYPE(*CHAR) LEN(10)
DCL VAR(&PAN) TYPE(*CHAR) LEN(10)
RTVDTAARA DTAARA(*LDA (511 10)) RTNVAR(&PAN)

CHGVAR VAR(&VAR1) VALUE(1234,01200)

/* Send num ex: 1231,2100 and returns 1.231,21 */
CALL PGM(PR2535) PARM(&VAR1 &VAR2)
CHGVAR VAR(&RESU) VALUE(&VAR2)

SNDBRKMSG MSG(&RESU) TOMSGQ(&PAN)
ENDPGM


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.