Print Page | Close Window

Localization

Printed From: Crystal Reports Book
Category: Crystal Reports for Visual Studio 2005 and Newer
Forum Name: Writing Code
Forum Discription: .NET programming API, report integration
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=10874
Printed Date: 04 May 2025 at 6:41pm


Topic: Localization
Posted By: eranohayon
Subject: Localization
Date Posted: 18 Aug 2010 at 11:04pm
I need to display Sum of groups and Total in the format of the system locale (e.g. in english- 123,123 in russion- 123 123).
In addition, because the summarised values are integers, I don't want to display the decimal digits.
If I change the Number format property of the field to 0 decimal digits, the format automaticaly is changed to- Custom. In this case the decimal digits are not displayed but the format of the number is not localized.
If I change the Number format back to the System default, the number is displayed according to the system locale but again the decimal digits are displayed.
 
I tried to solve it by adding a formula instead of using the Group wizard:
CStr(Sum ({sample_header_List_view.total_tests}),0)
But this is o.k. for the Total, and not for the groups sub totals. I didn't find a way to sum by group in a formula.
 
Helppppppppp



Replies:
Posted By: hilfy
Date Posted: 19 Aug 2010 at 11:06am

Create a formula like this:

CStr(Sum ({sample_header_List_view.total_tests}, {group field}),0)
 
There are two forms of the Summary functions (Sum, Count, etc.):
 
Sum({field}) gives you the grand total for the report
Sum({field}, {group field}) gives you the total for a group that has been defined on the report.
 
-Dell
 


-------------
Proviti, Data & Analytics Practice
http://www.protiviti.com/US-en/data-management-advanced-analytics - www.protiviti.com/US-en/data-management-advanced-analytics



Print Page | Close Window