Reputation: 5326
I am trying to figure out how to format the result in an expression in Excel. I wrote
=IF(C30 > B30, "You would save $" & Format(C30-B30, "Currency") & "!", "No savings")
inside the cell but it doesn't work. Simply put, I want the currency formatted inside the expression.
How?
Upvotes: 3
Views: 21300
Reputation: 2108
Many years later, this works, too!
=IF(C4>D4,"You would save " & DOLLAR(C4-D4,2) & "!","No Savings!")
Upvotes: 3
Reputation: 21
Use this formula
=IF(C30 > B30, "You would save " & Currency(C30-B30, 0) & "!", "No savings")
Upvotes: 2
Reputation: 12339
I think you are looking for the Concatenate function. Excel doesn't seem to have the Format function you have indicated.
This worked for me in Excel 2007:
=IF(C30 > B30, CONCATENATE("You would save $",C30-B30, "!"), "No savings")
Upvotes: -1
Reputation: 42890
Have you tried the Text function?
=IF(C30 > B30, "You would save " & Text(C30-B30, "$0.00") & "!", "No savings")
Upvotes: 10