Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Rounding up data that is converted to text
Message
From
08/03/2004 15:17:23
 
 
To
08/03/2004 14:51:41
General information
Forum:
Visual FoxPro
Category:
Crystal Reports
Miscellaneous
Thread ID:
00884212
Message ID:
00884227
Views:
6
What happens if you use a format statement that doesn't include decimals?


>I have data that is generated from calculations that for some reason is significant to two decimal places and I can't get rid of the decimal part.
>
>numbervar nAnswer := 0;
>stringvar sResult := '':
>
>nAnswer := 22/7;
>sResult := CSTR(TRUNCATE(nAnswer,0);
>
>doesn't work, nor does Round.
>the result displays on the report as 3.14 instead of 3.
>
>Thanks
>Jim
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Previous
Reply
Map
View

Click here to load this message in the networking platform