Consultor Eletrônico



Kbase P77137: How to convert a Decimal value to a String, without losing leading and trailing zero's?
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   19/04/2004
Status: Unverified

GOAL:

How to convert a Decimal value to a String, without losing leading and trailing zero's?

FIX:

To accomplish this, you can use the STRING Function with the FORMAT option. For example:

DEF VAR i AS DECIMAL NO-UNDO.
DEF VAR X AS CHAR NO-UNDO.

i = 0.50.
X = STRING(i,"zz9.99").

DISPLAY i SKIP X.