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

autoset worksheet name if options[:name] is nil #437

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

autoset worksheet name if options[:name] is nil #437

wants to merge 1 commit into from

Conversation

ghost
Copy link

@ghost ghost commented Dec 19, 2015

axlsx generates broken package if worksheet initialized without :name option. An example to reproduce the issue:

Axlsx::Package.new do |p|
  p.workbook.add_worksheet { |sheet| sheet.add_row ["test"] }  
  p.serialize('test.xlsx') 
end  

MS Excel can't open packages containing a worksheet without name (Excel could not open test.xlsx because some content is unreadable.)

<!-- test.xlsx/xl/workbook.xml -->
<?xml version="1.0" encoding="UTF-8"?>
<workbook xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships">
<workbookPr date1904="false"/>
  <sheets>
    <sheet sheetId="1" r:id="rId4"></sheet>
  </sheets>
</workbook>

tested with latest MSO on OSX and iOS

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.

1 participant