Occur error when I open excel
-
Hi, When I open excel file, I get this error. How can I solve this error ?
Could you help me please ?
-
Could you please replicate the problem in playground?
https://playground.jsreport.net/
I would take a look there, thank you
-
Thank's for quick reply. I have added template on this url. https://playground.jsreport.net/w/anon/u5fNcaEM.
-
Thank you. I've spent some time with it and here are the recommendations.
There are two approaches you can combine:
- problem isolation - try to remove all code you have there and add it parts one by one to find what is causing the corrupted excel
- open the corrupted file on the desktop, let it recover it. Then unzip both original and fixed files and compare what has changed.
One problem I found when checking corrupted excel is that the sheets have no names
<sheet name="{{{$localizedResource.dailyInformation}}}"/>
I believe you just didn't upload everything to the playground so this actually works for you, lets continue.The second problem I found when trying to isolate the cause of the corruption. I removed all segments in your code and started to add them one by one. This was the first one that caused the problem.
{{xlsxRemove "xl/worksheets/sheet1.xml" "worksheet.sheetData[0].row" 2}} {{#xlsxAdd "xl/worksheets/sheet1.xml" "worksheet.sheetData[0].row" }} <row> <c s="{{@root.$removedItem.c.[1].$.s}}"><is><t>{{$localizedResource.daily}}</t></is></c> <c s="{{@root.$removedItem.c.[3].$.s}}"><v>{{tableDailyExpactive}}</v></c> <c s="{{@root.$removedItem.c.[4].$.s}}"><v>{{tableDailyImpactive}}</v></c> <c s="{{@root.$removedItem.c.[5].$.s}}"><v>{{tableDailyIncome}}</v></c> </row> {{/xlsxAdd}}
Here you remove the third row but there are just two in the shee1.
I didn't continue further, but I hope this helps you to identify and fix the problems you have.
-
Thank's for your help. I didn't upload translation part. Sorry for that. I will try.