Libreoffice how to convert a text cell to a number

Solved
girondingue -  
 Anonymous user -
Hello,
my setup: Windows 10 and / Firefox 95.0
I retrieved (Enedis) a spreadsheet in which one (or more) cell(s) contained text and a number (0.331 kWh). Thanks to the formula = left(c2,5), I extracted the number alone (0.331) into a new column.
But this figure is not in "number" format. I can't perform any operations.
How can I change this data to number format?
Thank you in advance for your suggestions.

4 réponses

yclik Posted messages 3865 Registration date   Status Membre Last intervention   1 603
 
Hello
If the values are preceded by an apostrophe ' (visible in the formula bar once the cell is selected)

One solution is
Select the column
Data>text to columns
separator '
6
girondingue
 
In the formula bar formula, I have the formula =left(c2,5).
0
Anonymous user
 
Hello
What do you think is the difference between a number and text???
Me, French (it's not an insult), if I write 0.31 it's text because we use a comma, not a point...
If you retrieve a document in Anglo-Saxon format, it's the opposite...
If the number comes from an excerpt of text, sometimes, there’s an extra space, same thing!!
So you need to either use Find/Replace to replace all . with ,
Or all the spaces with , (nothing)
Catch you later
If the answer helped you, a little thank you is super nice...
Is it resolved? The green button at the top, that's good!

Let him who has never opened a user manual throw the first mouse ;-)
1
girondingue
 
Oops, I didn't notice it was a dot ....
I'm trying the search/replace.
Thank you very much.
0
Anonymous user
 
Hello
If you have resolved your issue, that's great.
Thank you, it's a thumbs up!!
See you later
--
If the answer helped you, a little thank you is really nice...
Is it resolved? The green button at the top is good!

Let him who has never opened a user manual throw the first mouse ;-)
1
girondingue
 
With all my thanks to everyone who helped me.
Have a good end of the day.
0