Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request]: Adjusting formulas for repeated lines #109

Open
LoreScianatico opened this issue Jan 26, 2021 · 5 comments
Open

[Feature Request]: Adjusting formulas for repeated lines #109

LoreScianatico opened this issue Jan 26, 2021 · 5 comments
Labels
P: Low S: on hold The issue is on hold until further notice T: enhancement Functionality that enhances existing features

Comments

@LoreScianatico
Copy link

Problem to solve
Adjusting formulas on rows/columns when multiple lines are printed

Proposed solution
Suppose I'm printing a template with some kind of iterations, and I have sums across rows and columns. At the moment the formula gets repeated as it is, without being adjusted according to the new inserted lines. I guess this happens because it is considered to be a constant. It would be nice if the formulas would be adjusted, even if I totally understand that it's not easy to detect if the cell content is a formula or not.

Describe alternatives you've considered
At the moment I'm simply doing some post-processing of the file after carbone gives me the filled report.

Additional context
I'm attaching an example of printed report:
simple.xlsx

@LoreScianatico LoreScianatico changed the title [Feature Request]: [Feature Request]: Adjusting formulas for repeated lines Jan 26, 2021
@steevepay
Copy link
Member

Hello Lorenzo, thank you for reaching us!
I totally acknowledge the issue and you have two solutions:

  • Before the rendering, define your formulas to a longer range.
  • After the rendering, a VBA Macro would adjust formulas based on the data range.
    For 2021, we plan to improve the XLSX support and I keep the idea of adjusting formulas.

@steevepay steevepay added P: Low S: on hold The issue is on hold until further notice T: enhancement Functionality that enhances existing features labels Jan 29, 2021
@steevepay steevepay mentioned this issue Feb 3, 2021
21 tasks
@loneil
Copy link

loneil commented Oct 21, 2021

I'm wondering if the comment from @steevepay about "Before the rendering, define your formulas to a longer range" will work for Excel spreadsheets?

I'm trying to just sum up a column of data and can't seem to get it to render the formula after the replacements no matter what I try in the SUM...

If I set the endpoint of the sum

image

With this data

{"people":[{"name":"Mike","age":22},{"name":"Vanessa","age":33},{"name":"Michelle","age":44},{"name":"Patrick","age":55}]}

I'm still getting 0 as the result out of Carbone.

image

Has anyone figured out how to get a simple column sum in Excel to work in Carbone?

@lucasoboli
Copy link

Maybe if you start from B2 instead of B1, so you don't take into account the first row which contains text instead of an integer.

@loneil
Copy link

loneil commented Oct 21, 2021

@lucasoboli sorry my screenshot had a mistake there, yes I've been trying from B2 with the same results (had pasted B1 to take the screenshot by accident)

image

So using =SUM(B2:B99999) for example, has the same result where the resultant cell after Carbone is still 0.

@erennyuksell
Copy link

any solution?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P: Low S: on hold The issue is on hold until further notice T: enhancement Functionality that enhances existing features
Projects
None yet
Development

No branches or pull requests

5 participants