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

issue 817 autoFilterBounds could have one element only, in this case … #818

Conversation

ivantextmagic
Copy link
Contributor

…use it as second param of AutoFilter

func IsSaneSheetName(sheetName string) error {
runeLength := utf8.RuneCountInString(sheetName)
if runeLength > 31 || runeLength == 0 {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't seem to be related to the issue you described? Why do we need to change this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry, yes. but I also, have got this problem on this file, please try it out too
auto-filter-titles.xlsx

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ivantextmagic - to my knowledge Excel still enforces 31 charaters as a limit, and historically it certainly did. Whilst the file format doesn't enforce that limit, and LibreOffice will open it just fine, it's generally not wise to create XLSX files that don't work in Excel. In general Excel is the most picky about XLSX files.

We could introduce a separate FileOption to support sheet names longer than 31 characters, but that would need to be a separate PR please.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay,returned it to 31
but still, I receive some files with characters number > 31
I'm not sure about the source, but I think it could be some old business systems which could export their data to xlsx

@tealeg tealeg merged commit 5f428c2 into tealeg:master Sep 17, 2024
1 check passed
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