[Solved] Cell content automistaked: (2) is made -2

Discuss the spreadsheet application
Post Reply
User avatar
morphingstar
Posts: 100
Joined: Mon Mar 28, 2011 5:52 am
Location: Mx

[Solved] Cell content automistaked: (2) is made -2

Post by morphingstar »

I want to mark rows with priority, so 1,2,3,4,5 in 1 column. Equal priorities will later be worked on.
Some rows might contain almost what I want, so I select [example] "(2)" instead of the higher priority "2".
The resulting -2 is not a priority I want to see or use.
Auto-correct is switched off.
When I check the Auto-correct window it shows -2 in the right filed, the left field is empty. Removing "-2" helps nothing.

At this time I am entering ",(2)" which works as a botch ... .
Defining the CELL as text requires 001, 011, 111, I prefer numbers in the usual form: 1,11,111.

How to get what I want?
Thanks.

Actual application:
Schedule
departure + arrival
mark the two trip legs which show the most convenient change (time) from one to the next part of the trip.
Say two get priority 2, but another one fits almost as well, it gets (2).
Cell refuses to show the entry I want.
Last edited by morphingstar on Tue Feb 26, 2019 7:25 am, edited 2 times in total.
OO 4.1.6 on Win10. Member since StarOffice 7. Alternative name "morphingstar2" when other fails. Use Writer, Calc (as DB + Calc), Draw. Impress mainly for Eyedropper and animating GIFs. Updated 20190716.
User avatar
RusselB
Moderator
Posts: 6646
Joined: Fri Jan 03, 2014 7:31 am
Location: Sarnia, ON

Re: cell content automistaked: (2) is made -2.

Post by RusselB »

If it's just a matter of having the display look correct (ie: you aren't doing any math or sorting on that column), then you could just format the column using something like

Code: Select all

#,##0;(#,##0)
OpenOffice 4.1.7, LibreOffice 7.0.1.2 on Windows 7 Pro, Ultimate & Windows 10 Home (2004)
If you believe your problem has been resolved, please go to your first post in this topic, click the Edit button and add [Solved] to the beginning of the Subject line.
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: cell content automistaked: (2) is made -2.

Post by Villeroy »

How to enter the text value (2): '(2). The leading apostrophe is just a text tag. It won't be part of the text.
Alternatively, without the leading apostrophe, you format the cell(s) as text (number format code @) before entering any literal text.
Second alternative: ="(2)"
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
User avatar
keme
Volunteer
Posts: 3704
Joined: Wed Nov 28, 2007 10:27 am
Location: Egersund, Norway

Re: cell content automistaked: (2) is made -2.

Post by keme »

As also implied in previous response, interpreting "(2)" as a negative number is not a mistake. The "mistake" is that you assume that Calc will understand human semantics. (2) is minus two to a spreadsheet application, not because of autocorrection of any kind, but because of a well established convention for numerical presentation.

Calc, like other spreadsheets, is primarily a calculation tool, designed for handling numbers and quantifiable magnitudes. There is a good reason why the "lesser two" that you try to signify with parentheses is taken as -2: Spreadsheet software was designed around existing conventions among people who worked with numbers. Those conventions are taken from economy (accounting) and technology (engineering, science) mostly. A common way to present negative results in accounting is by having the numbers in parentheses.

To have a "graded 2" you need to go beyond plain numbers. If you have "2!" as a "strong two", "2" as a "normal two" and "(2)" as a "weak/subordinate two", you need to define that sequence, and ensure that your entry is not interpreted as something else. This is done by ...
  • forcing text entry as per Villeroy's explanation (thus disabling numeric interpretation),
  • limiting entry to the allowed options (which you can do by data validation after creating a list of allowed entries),
  • use functions like MATCH() or VLOOKUP() to determine the entry's "score", or place in the sequence (position in said list).
Post Reply