You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2010/09/07 09:11:35 UTC

DO NOT REPLY [Bug 49887] Inconsistent behaviour between HSSF and XSSF when creating a sheet with a too long name

https://issues.apache.org/bugzilla/show_bug.cgi?id=49887

Yegor Kozlov <ye...@dinom.ru> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED
         OS/Version|                            |All

--- Comment #1 from Yegor Kozlov <ye...@dinom.ru> 2010-09-07 03:11:33 EDT ---
The rule is more complex. 

Non Excel clients such as OpenOffice allow opening / editing of worksheets with
names longer than 31 characters. 
Excel (2007) opens files with long sheet names without error or warning.
However, long sheet names are silently truncated to 31 chars.  This means that
sheet name uniqueness is enforced on only the first 31 chars.

Example:

 workbook.createSheet("POI allows creating sheets with names longer than 31
characters - 1"); // OK
 workbook.createSheet("POI allows creating sheets with names longer than 31
characters - 2"); // fail, substring(0, 31) is the same as sheet0

I changed XSSF to behave as HSSF, i.e. removed the 31 chars restriction and
enforced name uniqueness on the first 31 chars. 

The fix was committed in r993246

Regards,
Yegor

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org