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

Control of showSheetTabs in workbook.xml #1160

Closed
Ralim opened this issue Feb 26, 2022 · 2 comments
Closed

Control of showSheetTabs in workbook.xml #1160

Ralim opened this issue Feb 26, 2022 · 2 comments
Labels
confirmed This issue can be reproduced

Comments

@Ralim
Copy link

Ralim commented Feb 26, 2022

Description
Hello,

At the moment Excelize appears to be stripping the showSheetTabs control out of the bookViews tag in workbook xml.

For my use case I just want the tag to persist through unchanged, but control would be nice.

Steps to reproduce the issue:

  1. Create excel xlsm with showSheetTabs="0" by turning off showing sheet tabs
  2. Open the file, then save the file to a new location through excelize
  3. Notice that in workbook.xml the option is no longer present

Describe the results you received:

In workbook.xml we have the following before excelize:

<bookViews>
        <workbookView showSheetTabs="0" xWindow="-108" yWindow="-108" windowWidth="23256" windowHeight="12576" tabRatio="834" xr2:uid="{00000000-000D-0000-FFFF-FFFF00000000}"/>
    </bookViews>

and after running through Excelize we have:

<bookViews>
        <workbookView xWindow="-105" yWindow="-105" windowWidth="23250" windowHeight="12570" tabRatio="834" xr2:uid="{00000000-000D-0000-FFFF-FFFF00000000}"/>
    </bookViews>

Describe the results you expected:

In workbook.xml we have the following before excelize:

<bookViews>
        <workbookView showSheetTabs="0" xWindow="-108" yWindow="-108" windowWidth="23256" windowHeight="12576" tabRatio="834" xr2:uid="{00000000-000D-0000-FFFF-FFFF00000000}"/>
    </bookViews>

and after running through Excelize we would like:

<bookViews>
        <workbookView showSheetTabs="0" xWindow="-105" yWindow="-105" windowWidth="23250" windowHeight="12570" tabRatio="834" xr2:uid="{00000000-000D-0000-FFFF-FFFF00000000}"/>
    </bookViews>

Output of go version:

go version go1.17.4 linux/arm64

Excelize version or commit ID:

	github.com/xuri/excelize/v2 v2.5.0

Environment details (OS, Microsoft Excel™ version, physical, etc.):

Tested on Linux and Mac OSX; go 1.17 and 1.18.
Files are edited with latest office365.

Notes

Happy to help in any way I can for this :)

@xuri xuri added confirmed This issue can be reproduced in progress Working in progress labels Feb 26, 2022
@xuri xuri closed this as completed in 471c8f2 Feb 26, 2022
@xuri
Copy link
Member

xuri commented Feb 26, 2022

Thanks for your issue. I have fixed it, please upgrade to the master branch code, and this patch will be released in the next version.

@xuri xuri removed the in progress Working in progress label Feb 26, 2022
@Ralim
Copy link
Author

Ralim commented Mar 1, 2022

Confirmed fixed.

Thank you ❤️

xuri added a commit to carbin-gun/excelize that referenced this issue Oct 9, 2022
* Fix show sheet tabs issue
* Ref qax-os#65, new formula functions: ERROR.TYPE, HOUR, SECOND TIMEVALUE
jenbonzhang pushed a commit to jenbonzhang/excelize that referenced this issue Oct 22, 2023
* Fix show sheet tabs issue
* Ref qax-os#65, new formula functions: ERROR.TYPE, HOUR, SECOND TIMEVALUE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
confirmed This issue can be reproduced
Projects
No open projects
Status: Bugfix
Development

No branches or pull requests

2 participants