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

do not skip empty string in shared strings so that indexes match #232

Merged
merged 1 commit into from
Dec 2, 2016
Merged

do not skip empty string in shared strings so that indexes match #232

merged 1 commit into from
Dec 2, 2016

Conversation

pookong
Copy link

@pookong pookong commented Nov 28, 2016

when working with shared strings this library adds empty string into shared strings (as it should), but when the shared strings are processed into xml, the empty string is omitted

workbook with cells ['foo', '', 'bar'] creates xl/sharedStrings.xml like:

<sst xmlns="..." count="3" uniqueCount="3">
  <si><t>foo</t></si>
  <si/>
  <si><t>bar</t></si>
</sst>

with missing <t> tag in <si>

this results in missing shared string in some excel reading libs that do not count this <si> as a string

when the sheet is opened and resaved with MS Excel, the shares string includes an empty <t> tag

@guyonroche guyonroche merged commit 202593a into exceljs:master Dec 2, 2016
@guyonroche
Copy link
Collaborator

Good catch! Thanks again for the contribution

@pookong
Copy link
Author

pookong commented Dec 7, 2016

thanks for merging... and for the whole lib - it surely pulled a thorn out of my foot :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants