Bug 119646 - EDITING: Hide and omit single quote before equal sign at start of cell string (escape formula recognizer like number recognizer)
Summary: EDITING: Hide and omit single quote before equal sign at start of cell string...
Status: RESOLVED WONTFIX
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.1.0.3 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-09-02 13:19 UTC by gekacheka
Modified: 2018-10-01 18:07 UTC (History)
2 users (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 gekacheka 2018-09-02 13:19:51 UTC
Description:
A single quote may be used to avoid autorecognizing numbers, so they may be stored as strings (for example to preserve leading zeros).  This single quote is hidden in the cell, but shown in the editing field.

Currently, this does not work for string values that start with an equal sign.

If the single quote is omitted, then the formula recognizer fails and an error is produced.  (Exception: a single character string consisting of the equal sign character.)  Good.

If the single quote is included as a prefix before the equal sign, then the single quote is shown in the cell and included in the string value.  Bad.




Steps to Reproduce:
STEPS TO REPRODUCE:

Type or paste the following three characters into a cell
'==



Actual Results:
ACTUAL:  cell value is string
'==

(Can verify value contains the single quote ' by exporting to csv or other format.)

Expected Results:
EXPECT:  cell value is string
==

(Can verify value omits the single quote ' by exporting to csv or other format.)



Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 6.1.0.3 (x64)
Build ID: efb621ed25068d70781dc026f7e9c5187a4decd1
CPU threads: 2; OS: Windows 6.1; UI render: default; 
Locale: en-US (en_US); Calc: group threaded
Comment 1 Buovjaga 2018-10-01 15:44:42 UTC
Talked with Eike about this and he thinks this would be going too far. Better to just format the cell as text. Closing.
Comment 2 gekacheka 2018-10-01 17:50:05 UTC
(In reply to Buovjaga from comment #1)
> Talked with Eike about this and he thinks this would be going too far.
> Better to just format the cell as text. Closing.

Hi, could you please explain "just format the cell as text" ?

That is what I was trying to do.  Is there another way that does not involve using a single quote?
Comment 3 Buovjaga 2018-10-01 17:55:09 UTC
(In reply to gekacheka from comment #2)
> (In reply to Buovjaga from comment #1)
> > Talked with Eike about this and he thinks this would be going too far.
> > Better to just format the cell as text. Closing.
> 
> Hi, could you please explain "just format the cell as text" ?
> 
> That is what I was trying to do.  Is there another way that does not involve
> using a single quote?

Right-click cell/cell selection - Format cells or menu Format - Cells or Ctrl+1.
Numbers tab, change category to "Text".
Now your formulas will stay as text and not as evaluated functions.
Comment 4 gekacheka 2018-10-01 18:07:39 UTC
(In reply to Buovjaga from comment #3)
> (In reply to gekacheka from comment #2)
> > Hi, could you please explain "just format the cell as text" ?
> > 
> > That is what I was trying to do.  Is there another way that does not involve
> > using a single quote?
> 
> Right-click cell/cell selection - Format cells or menu Format - Cells or
> Ctrl+1.
> Numbers tab, change category to "Text".
> Now your formulas will stay as text and not as evaluated functions.

Aha. Thank you.  I missed that approach.
I must set the cell format to 'Text' BEFORE entering a text like 
==