On Fri, 4 Jan 2013 10:43:18 -0800, Lionel Dyck <lionel.d...@us.ibm.com> wrote:

>I ran across this code from Doug Nadel several years ago and hope that
>y'all will find it useful.
>
>
>          /* ----------------------------------------------------- */
>          /* number format code thanks to Doug Nadel               */
>          /* ----------------------------------------------------- */
>           str=strip(translate('0,123,456,789,abc,def', ,
>                           right(bytes,16,','), ,
>                           '0123456789abcdef'),'L',',')
>           bytes = strip(str)
>
>Here are two examples from oorexx under windows (this works well under
>z/OS and z/VM)
>
>C:\t\new>test.rex 12345678
>Bytes: 12,345,678
>
>C:\t\new>test.rex 12345678.12
>Bytes: 12,345,678,.12
>
>

May need a tweak (or cut/paste does).  What's that extra comma before
the decimal point in the 2nd example?  

There was a recent thread on the TSO-REXX list that had some
nice examples - probably including this one (I don't follow TSO-REXX
too closely).

--
Mark Zelden - Zelden Consulting Services - z/OS, OS/390 and MVS       
mailto:m...@mzelden.com                                        
Mark's MVS Utilities: http://www.mzelden.com/mvsutil.html 
Systems Programming expert at http://expertanswercenter.techtarget.com/

Mark

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to