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

custom sheet name causes excel content blank #116

Closed
doggytty opened this issue Sep 8, 2017 · 2 comments
Closed

custom sheet name causes excel content blank #116

doggytty opened this issue Sep 8, 2017 · 2 comments

Comments

@doggytty
Copy link

doggytty commented Sep 8, 2017

Hi!
When I changed the sheet name from ”sheet2“ to ”T1“ in the sample code, I found that there was no data in the generated excel, also I could not get the data using ”T1“.
Look at the source code, in the sheet.go file setContentTypes method, the xml name has been fixed to sheet+index. So I using sheet+index when set cell value, but when I want to obtain sheetIndex, I must use "T1".
This is too inconvenient, Is there any way to solve this question?

Thx

@xuri
Copy link
Member

xuri commented Sep 11, 2017

We can use the GetSheetMap() function to get all sheets index and name map and use "Sheet" + index to set the cell value currently. Please reference issue #25, #43, #47, #51, #89, #101 and godoc.

@doggytty
Copy link
Author

o,that's very good, thank you, sir!

xuri added a commit that referenced this issue Sep 13, 2017
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

No branches or pull requests

2 participants