Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Convert decimal to string

546 views
Skip to first unread message

Connie Phillips

unread,
Dec 3, 1997, 3:00:00 AM12/3/97
to

I need to put a decimal field into a message box. I converted it to
string, and it shows about 10 decimal places. I only want the user to
see 2 decimal places to the right of the decimal.

Connie Phillips
phillip...@bsc.bls.com

Boris Gasin [TeamPS]

unread,
Dec 3, 1997, 3:00:00 AM12/3/97
to

On Wed, 03 Dec 1997 15:39:12 -0500, in
powersoft.public.powerbuilder.general Connie Phillips
<phillip...@bsc.bellsouth.net> wrote:

>I need to put a decimal field into a message box. I converted it to
>string, and it shows about 10 decimal places. I only want the user to
>see 2 decimal places to the right of the decimal.

Connie,

You can use the second optional argument to specify the number of
decimal places:

String(10.9999999,"#,##0.00")

HTH,
--
Boris Gasin [TeamPS]
mailto:bga...@advent2000.com

Have a heart,
http://home.sprynet.com/sprynet/JCredit/eds_stry.htm

forums.powersoft.com

unread,
Dec 3, 1997, 3:00:00 AM12/3/97
to

use mid to find the decimal then left() to chop off > 2 places beyond it..
.02

Connie Phillips wrote in message <3485C3...@bsc.bellsouth.net>...


>I need to put a decimal field into a message box. I converted it to
>string, and it shows about 10 decimal places. I only want the user to
>see 2 decimal places to the right of the decimal.
>

>Connie Phillips
>phillip...@bsc.bls.com

0 new messages