Bug Hunting Session
Bug 103027 - Can't name a sheet starting with the ' [apostrophe] character
Summary: Can't name a sheet starting with the ' [apostrophe] character
Status: CLOSED WONTFIX
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:6.0.0
Keywords:
Depends on:
Blocks: Sheet
  Show dependency treegraph
 
Reported: 2016-10-06 06:23 UTC by fcastillousfq
Modified: 2017-09-04 11:38 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description fcastillousfq 2016-10-06 06:23:05 UTC
Description:
If I want to named a sheet starting with the ' [apostrophe] character, a dialog showing an "invalid sheet name" shows, stating that the name must not be a duplicate or contain certain characters, which ' [apostrophe] is not listed.
In fact, I can place a ' anywhere in the name as long as is not the first character, and libreoffice doesn't have a problem with it.
As a workaround, I start the name with a space followed by ' [apostrophe] and that does the trick. Nonetheless, this is a bug.

Steps to Reproduce:
1.Rename any sheet
2.Make sure the first character in the name is ' [apostrophe]

Actual Results:  
The "Invalid sheet name" dialog should appear

Expected Results:
The sheet should be renamed without any problems. The ' [apostrophe] character is not an invalid one.


Reproducible: Always

User Profile Reset: Yes

Additional Info:


User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.143 Safari/537.36
Comment 1 Jean-Baptiste Faure 2016-10-06 19:37:09 UTC
Reproducible with master under Ubuntu 16.04. The error message is displayed if the apostrophe is the first or the last character. And, indeed, the apostrophe is not in the given list of invalid characters.

Best regards. JBF
Comment 2 Eike Rathke 2017-09-04 11:26:15 UTC
Apostrophe isn't allowed as first or last character because Excel can't handle it (probably due to the sheet name when used in references can be single quoted and a single ' quote contained is escaped by doubling it '' and they can't cope with that if it's right at the start or end of a single quoted name). Won't change. We may add a hint to the dialog though.
Comment 3 Commit Notification 2017-09-04 11:37:44 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=62c6e17fc03ae54cf3f6b667cf8ba205b92996a5

Apostrophe ' is invalid as first or last character in sheet name, tdf#103027

It will be available in 6.0.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.