cuba-platform / yarg

Yet Another Report Generator - CUBA Platform reporting engine
https://www.cuba-platform.com
Apache License 2.0
239 stars 75 forks source link

Excel Formulae is not working when converting excel to pdf #135

Closed VarmaTech closed 1 year ago

VarmaTech commented 3 years ago

Hi , i have 2 column in which 1 column need to show grand total so i have kept formuale in excel as ''=SUM(CELL:CELL)" grand total is coming in excel but when i tried converting to pdf using excel template by LibreOffice5 it is showing zero .

version yarg 2.1.5

Desire456 commented 2 years ago

Hi @VarmaTech,

Can not reproduce your issue. Please check https://github.com/cuba-platform/reports/issues/199. If it doesn't help can you please provide the report or minimal sample application to reproduce your issue?

VarmaTech commented 2 years ago

Desire456 commented : That occurs because the template is created using Microsoft Office. There is a shared formula that was created in MS Office and not supported by LibreOffice. You can create a template using LibreOffice or don't use shared formulas in MS Office. When you create the template using LibreOffice all works correctly. The correct workflow for this case is creating templates in LibreOffice and reading reports from everywhere or creating templates in Microsoft Office and not using shared formulas.

How ever the template is created , Yarg logic should work right ? how can we tell the end user to create template only in LibreOffice or not to use Shared Formulas . Max user use Microsoft Office . This is not the way to close the issue.

Gavrilov-Ivan commented 1 year ago

Added option to force evaluation of formulas. Configured by DefaultFormatterFactory#setFormulasPostProcessingEvaluationEnabled or cuba.reporting.formulasPostProcessingEvaluationEnabled property. 'False' by default.