how to add value within variable in RPGLE

3790 pts.
Tags:
RPGLE Program
how to add the variable value which is already in one variable.... for example -- one variable VAR1 has 56789... i want to add 5+6+7+8+9... is it possible....

Software/Hardware used:
as400 v5r3

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

Discuss This Question: 3  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • CharlieBrowne
    You can also use %Subst and a DO loop
    62,265 pointsBadges:
    report
  • TomLiotta
    You can also OVERLAY the characters as an array of digits and use XFOOT or %XFOOT() to sum the array. Tom
    125,585 pointsBadges:
    report
  • The Most-Watched IT Questions: December 13, 2011 - ITKE Community Blog
    [...] A member wonders how to add value within variable in RPGLE and gets their [...]
    0 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: