Bug 122634 - Cannot reference cell when referencing cell "Number format" is Text
Summary: Cannot reference cell when referencing cell "Number format" is Text
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.1.4.2 release
Hardware: x86-64 (AMD64) Windows (All)
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-01-10 14:01 UTC by matti.jaatinen
Modified: 2019-07-14 14:15 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Example with 4 sheets. (8.87 KB, application/vnd.oasis.opendocument.spreadsheet)
2019-02-13 06:31 UTC, matti.jaatinen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description matti.jaatinen 2019-01-10 14:01:02 UTC
Description:
Cell B1 Number format is Text
Cell B2 Number format is General
Changing B1 function does not work.
Example:
- change function to =A2 then the displayed value is =A2.
- change function to back =A1 then the displayed value is =A1.

But changing B2 works. 
Example:
- change function to =A1 then the displayed value is 11.
- change function to =A2 then the displayed value is 22.

Steps to Reproduce:
1. 
Add cell A1 value 11 and A2 value 22.

2. 
Change cells B1 and B2 Number format to General.
Add cell B1 function =A1, should now evaluate as 11.
Add B2 function =A2, should now evaluate as 22.

3. 
Change B1 Number format to Text.
Change B1 function to =A2 it should now evaluate as =A2.
Change B2 function to =A1 it should now evaluate as 11.
Change B1 function to =A1 it should now evaluate as =A1.
Change B2 function to =A2 it should now evaluate as 22.
Change B1 Number format to General.
Change B1 function to =A2 it should now evaluate as 22.
Change B2 function to =A1 it should now evaluate as 11.



Actual Results:
1. 
Add cell A1 value 11 and A2 value 22.

2. 
Change cells B1 and B2 Number format to General.
Add cell B1 function =A1, should now evaluate as 11.
Add B2 function =A2, should now evaluate as 22.

3. 
Change B1 Number format to Text.
Change B1 function to =A2 it should now evaluate as =A2.
Change B2 function to =A1 it should now evaluate as 11.
Change B1 function to =A1 it should now evaluate as =A1.
Change B2 function to =A2 it should now evaluate as 22.
Change B1 Number format to General.
Change B1 function to =A2 it should now evaluate as 22.
Change B2 function to =A1 it should now evaluate as 11.


Expected Results:
1. 
Add cell A1 value 11 and A2 value 22.

2. 
Change cells B1 and B2 Number format to General.
Add cell B1 function =A1, should now evaluate as 11.
Add B2 function =A2, should now evaluate as 22.

3. 
Change B1 Number format to Text.
Change B1 function to =A2 it should now evaluate as 22.
Change B2 function to =A1 it should now evaluate as 11.
Change B1 function to =A1 it should now evaluate as 11.
Change B2 function to =A2 it should now evaluate as 22.
Change B1 Number format to General.
Change B1 function to =A2 it should now evaluate as 22.
Change B2 function to =A1 it should now evaluate as 11.



Reproducible: Always


User Profile Reset: Yes


OpenGL enabled: Yes

Additional Info:
Comment 1 Xisco Faulí 2019-02-12 17:05:29 UTC
Thank you for reporting the bug. Please attach a sample document, as this makes it easier for us to verify the bug. 
(Please note that the attachment will be public, remove any sensitive information before attaching it. 
See https://wiki.documentfoundation.org/QA/FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F for help on how to do so.)

I have set the bug's status to 'NEEDINFO'. Please change it back to 'UNCONFIRMED' once the requested document is provided.
Comment 2 matti.jaatinen 2019-02-13 06:31:27 UTC
Created attachment 149247 [details]
Example with 4 sheets.
Comment 3 Buovjaga 2019-07-14 14:15:16 UTC
It is the expected behaviour: https://ask.libreoffice.org/en/question/41364/functions-ignored-in-calc/