Comments (5)
I found that the problem is generated by sheetViews node in worksheets/sheet1.xml file. When I comment out the lines that append this node to output file, everything seems to work just fine.
from js-xlsx.
@Ajolos Thank you for reporting this. I'm able to print fine in OSX Office 2011. Not a comprehensive test but i can run that quickly. Differencing the downloaded and saved files, the difference in that section is the saved file does not have the attribute showGridlines="1"
. It seems that "1"
is the assumed value if not specified and should not be in the XML.
Can you try commenting out line xlsx.js:7843
(or 67_bits.js:311
then make
) and tell me if the problem persists?
showGridLines: opts.showGridLines == false ? '0' : '1',
from js-xlsx.
Well, commenting out the line you pointed didn't change anything - Excel still crashes after pressing 'Print'. However, when I comment out the next line
tabSelected: opts.tabSelected === undefined ? '1' : opts.tabSelected,
(node sheetView in output file has no attribute tabSelected)
or change its default value to '0'
tabSelected: opts.tabSelected === undefined ? '0' : opts.tabSelected,
(node sheetView in output file has attribute tabSelected="0")
I can print the file successfully.
Does it make any sense to you? So far I found the tabSelected attribute definition:
Flag indicating whether this sheet is selected. When only 1 sheet is selected and active, this value should be in synch with the activeTab value. In case of a conflict, the Start Part setting wins and sets the active sheet tab.
I didn't debug the whole library, but in the source code activeTab is mentioned only once - in line 8352:
var WBViewDef = [ ['activeTab', '0'], ... //window{Height,Width}, {x,y}Window ];
It seems like the activeTab is set to '0' by default, but tabSelected is set to '1', which is in conflict with the definition (should be in sync).
from js-xlsx.
This is great. Working into next release.
from js-xlsx.
Same as #29? Will test 0.8.13 and let you know tomorrow if it fixed my issue.
from js-xlsx.
Related Issues (20)
- Add comments/note can not export or export very slow, without comments, it will export very quick
- vite上怎么配置config.externals({ "./cptable": "var cptable" }); HOT 8
- add some comment XLSX.write page unresponsive
- Why I installed js-xlsx, there is no json_to_sheet method after import
- Not able to at add comments to the cell while writing it through xlsx-style.
- Depends on vulnerable versions of jszip
- cptable is not defined
- Need to remove unprotected cells containing formula warning icon in excel sheet
- How to set cell wrapping?
- How to parse ‘excel formula' using node js to get the actual value from the excel sheet.
- How use typescript in this project?
- Please lock the commander version, otherwise it cannot support Node v12
- Read styles for HTML table cell
- jszip is not a constructor
- How to set different text styles in cells with xlsx-style , example: C3:{ t : "s" v : "<p>Update Wifi long-term supply <span style=\"text-decoration: underline;\">plan</span> and impact to <strong>production</strong> }
- js.forEach is not a function HOT 1
- RollupError: Could not resolve "../xlsx" from "../xlsx?commonjs-external" HOT 1
- Denial of Service (DoS) affecting package jszip.
- Excel to PDF Page size and scaling issue
- what is this issue i am not able to understand and resolve
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from js-xlsx.