Fix an Excel IF Formula Comparing a Negative Currency Value
Question details
The user needs an Excel IF formula to compare a negative currency value and return the intended text.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- A worksheet compares currency values in cells N40 and N35 to report whether a budget is on track.
- Observed behavior
- The IF formula returns unexpected text, although conditional formatting appears to show the comparison correctly.
Identify which cell contains the actual amount and which contains the comparison amount. Check the underlying values in N40 and N35 rather than relying only on their currency formatting.
Check the IF Comparison and Cell References
Use this check when the formula returns a result that does not match your intended budget rule.
A negative number is less than a positive number, but it can be greater than another negative number. For example, -5 is greater than -10.
The example below returns “Budget on Track” only when N40 is greater than N35. Equal values return “Over Spending”; adjust the operator or labels if your budget rule differs.
Select the cell containing the IF formula and review its references and comparison operator in the formula bar. Confirm that N40 and N35 are the intended cells.
In an empty cell, enter =N40>N35. Check whether the TRUE or FALSE result matches the rule you want to apply.
If the intended rule is that N40 must be greater than N35, enter =IF(N40>N35,"Budget on Track","Over Spending") in the result cell. Use a different operator, such as >=, if equal values should also be on track.
Select the formatted cells and open Home > Conditional Formatting > Manage Rules. Check that the rule uses the same cells and comparison as the IF formula.

Convert Text-Formatted Currency Values to Numbers
Use this approach if either referenced cell contains a number stored as text.
Compare Negative Currency Values in WPS Spreadsheets
Open your workbook in WPS Spreadsheets, check the referenced values, and use an IF formula to return the appropriate budget message.
- 1. Open the workbook: Open WPS Spreadsheets and select Open to choose your Excel workbook.
- 2. Check the values: Select N40 and N35 to review their underlying values, then enter =ISNUMBER(N40) and =ISNUMBER(N35) in empty cells to check their data types.
- 3. Enter the comparison formula: In the result cell, enter =IF(N40>N35,"Budget on Track","Over Spending") if that comparison matches your budget rule.
- 4. Convert text if needed: If a value is stored as recognizable numeric text, try =IF(VALUE(N40)>VALUE(N35),"Budget on Track","Over Spending") in the result cell. Clean unrecognized symbols or spaces if conversion fails.

Frequently Asked Questions
Why does my IF formula return “Budget on Track” for a negative value?
The result depends on both values and the comparison operator. For example, -5 is greater than -10. Enter =N40>N35 in an empty cell to test the comparison used by the formula.
How can I tell whether a currency value is stored as text?
Enter =ISNUMBER(N40) in an empty cell. TRUE means the value is numeric; FALSE means it is not stored as a number.
Will changing the cell format to Currency fix the comparison?
Not necessarily. Changing the format through Home > Number affects the display but does not necessarily convert text into a numeric value. Check with ISNUMBER and correct or convert the source value.
Why does VALUE return a #VALUE! error?
The text may contain an unrecognized currency symbol, separator, or hidden space. Inspect the source cell in the formula bar, clean the text, and retry VALUE using a number format recognized by your Excel locale.




