Seems reasonable to me. An exception should only thrown if the truncated name 
matches an existing sheet name.






On Sunday 31 October 2021, 07:53:42 GMT, Andreas Reichel 
<[email protected]> wrote: 





Greetings,

maybe I hit another small glitch:

1) I have a long list of distinct Sheet Names, but some of them have
more than 31 characters
2) when adding new sheets to the workbook, it looks like exceeding
characters are cut of silently from the sheet name
3) thus failing, when cutting of the characters makes the sheet name
non distinct

This behaviour is at least confusing, when you generate Sheet Names
from a database query.
I spent the half last night looking for any duplicates in the query
itself and it took me a long time to figure out what actually happened.

So maybe, present a warning when cutting off sheet names and maybe a
severe exception, when cutting off the sheet name will collide with an
existing sheet?
If you agree on this approach, I would be able to craft a PR -- and
fulfil my dream of contributing to POI finally :-) 

Warm regards
Andreas


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to