Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ROUNDing up
Message
De
20/04/2009 14:04:09
 
 
À
13/04/2009 18:26:29
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Divers
Thread ID:
01394685
Message ID:
01395622
Vues:
76
Thanks!

>>Hi All:
>>
>>Is there a function out there that will always ROUND up if the following digit is greater than 0?
>>
>>Examples:
>>
>>
>>ROUND(123.4512,2)   returns 123.45
>>ROUNDUP(123.4512,2)   returns 123.46
>>
>>
>>Kinda like CEILING, which only works on the integer level.
>>
>>Thanks,
>>
>>Yossi
>How about something like
>FUNCTION roundup(tnNumber,tnDigits)
>RETURN CEILING(tnNumber*10^tnDigits)/(10^tnDigits)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform