Question

I have a column name as "Amount" in CR. I need to sum that column.

I created a new formula and tried sum( { MycolumnName} ) and it says

"A number field or currency amount field is required here"

Is there any way to apply conversion in formula itself.

Was it helpful?

Solution

Why create a formula when you can just create a summary field by selecting your column and going to the menu and selecting Insert Summary, Insert Subtotal or Insert Grand Total depending on your needs? You can place the summary field in a group section as a subtotal, or in the report footer as a grand total.

If you need to apply a conversion in the formula, you can use CCur like this:

sum( CCur({ MycolumnName}) ) 

More information on converting types in Crystal Reports can be found here.

OTHER TIPS

Change the type xs:string to xs:decimal of the column MycolumnName in xs:element in .xsd page

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top