[Solved] Text and formula with space in same cell
[Solved] Text and formula with space in same cell
How do I add text and formula with space in same cell. This is what I have: ="Total" & (SUM(C7+C8)) and this is the result in the cell: Total233.7.Thank for any and all help.
Ken
Ken
Last edited by MrProgrammer on Sat Mar 08, 2025 4:55 pm, edited 1 time in total.
Reason: Tagged ✓ [Solved]
Reason: Tagged ✓ [Solved]
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
Greetings and welcome to the community forum!
Now don't smack yourself ...
="Total " & (SUM(C7+C8))
Also, the SUM and + are redundant; one or the other does the same job.
Now don't smack yourself ...
="Total " & (SUM(C7+C8))
Also, the SUM and + are redundant; one or the other does the same job.
AOO4/LO5 • Linux • Fedora 23
Re: text and formula with space in same cell
Thanks acknak,
If this is your answer
If this is your answer
It's the same as the one in my post.Now don't smack yourself ...
="Total " & (SUM(C7+C8))
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
Not quite ...
="Total" & (SUM(C7+C8))
="Total " & (SUM(C7+C8))
="Total" & (SUM(C7+C8))
="Total " & (SUM(C7+C8))
AOO4/LO5 • Linux • Fedora 23
Re: text and formula with space in same cell
Sorry I see the difference.
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
Sorry I see the difference.
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
Is there anyway to change the numerical valve to currency and make the text bold?
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
"valve" is "value" really, yes?Is there anyway to change the numerical valve to currency and make the text bold?
You can not apply different Styles (by a formula) for parts of a cell content.
But you can use two cells in a row to display this combination.
Tibor Kovacs, Hungary; LO7.5.8/25.8.5.2 /Win7-10-11 x64Prof.
PortableApps: LO3.3.0-25.8.5.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
PortableApps: LO3.3.0-25.8.5.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Re: text and formula with space in same cell
Thank all for the help.
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
Contrary to Tibor's post, you can get the value to appear as a formatted number by using the TEXT function.
Thus you would have something like
See the help file for TEXT function and Number Format Codes
Thus you would have something like
Code: Select all
="Total " & text(sum(c7;c8);"$###.#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.
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.
Re: text and formula with space in same cell
I did a search on TEXT formatting and I could not find anything. I am new to spreadsheets.
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
TEXT uses the same number format codes as the spreadsheet cells (Format > Cells > Numbers ...)
You can see a list of the codes in the online help: Help > OO Help > Index > "format codes;numbers"
They're also described in the LibreOffice help, which is available on the web: https://help.libreoffice.org/Common/Number_Format_Codes
You can see a list of the codes in the online help: Help > OO Help > Index > "format codes;numbers"
They're also described in the LibreOffice help, which is available on the web: https://help.libreoffice.org/Common/Number_Format_Codes
AOO4/LO5 • Linux • Fedora 23
Re: text and formula with space in same cell
Thanks,
This doesn't tell me how to make the text bold and level the numbers normal.
This doesn't tell me how to make the text bold and level the numbers normal.
Apache OpenOffice 4.1.1
Windows 8.1
Windows 8.1
Re: text and formula with space in same cell
Sorry, guess I misunderstood what you were wanting.
With your latest post I have to say that I don't think it can be done and maintain the information in a single cell.
One possibility you might try is to have the information in to separate cells, then use a concatenation operation to combine into a single cell.
With your latest post I have to say that I don't think it can be done and maintain the information in a single cell.
One possibility you might try is to have the information in to separate cells, then use a concatenation operation to combine into a single cell.
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.
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.
Re: text and formula with space in same cell
Oops, I misunderstood what you mean by "format"
The result of a formula can have only one text format, which will apply to the whole contents of the cell.
Only text that you enter can have complex text formatting.
If you want the label in bold and the number value not bold, you have to keep them in separate cells, as Russell already suggested.
Sorry, this is not possible.Kenmc wrote:... This doesn't tell me how to make the text bold and level the numbers normal.
The result of a formula can have only one text format, which will apply to the whole contents of the cell.
Only text that you enter can have complex text formatting.
If you want the label in bold and the number value not bold, you have to keep them in separate cells, as Russell already suggested.
AOO4/LO5 • Linux • Fedora 23
Re: text and formula with space in same cell
With the above approach, the cell value is text which cannot be reliably used in further calculations. (It may be useful if you want to use the entire "Total xxx" string as text, like in a mail merge context.)
The common solution is to use cell formatting instead:
The common solution is to use cell formatting instead:
- Format - Cell..., tab Numbers.
In the Format code field, enter: "Total: " $ # ##0.00
Apache OO 4.1.16 and LibreOffice 25.8, mostly on Ms Windows 10 and 11.
-
bryan.hoffmann
- Posts: 3
- Joined: Sat Jan 23, 2021 12:15 pm
Re: Text and formula with space in same cell
Excellent - this helped enormously, thanks!
Note, to get eg 'total cost is €12' in one cell, this also works: ="total cost is €"&SUM(I31:I57)
Note, to get eg 'total cost is €12' in one cell, this also works: ="total cost is €"&SUM(I31:I57)
OpenOffice 2017.24 Professional Edition Patch 0 on macOS Catalina 10.15.7