Hi Guys,

I have a problem and would like an extra pair of eyes.

To help, I have detailed my exact set up below.

I have 2 cells of data.

Cell B10 has the amount of days an order has been delayed. B10 equals 10

Call C10 has the last action taken. The first number in the cells was the number of days it was delayed when the last action was taken. C10 equals 9 POT SENT 04/08/15

Cell D10 gives me just the days from cell C10, either 1 digit or 2, depending on whether the 2nd "letter" is a space or not.

=IF(RIGHT(LEFT(C10,2),1)=" ",LEFT(C10,1),LEFT(C10,2))
Cell E10 looks at cell B10 to tell me if it is proceeded by a minus (-) if it is, then it returns a 1, if not a zero

=IF(LEFT(B10,1)="-",1,0)
Cell F10 returns the value in cell B10, but without the (-) if its a negative number.

=RIGHT(TRIM(B10),LEN(B10)-E10)
This all leads up to cell G10
What I am trying to get Excel to work out is if Cell B10 is greater or lesser than the value in cell C10. To this end, I have employed formulae to work out the following:

1) if the number is not a minus (E10=0) then work out if B10 is greater than D10.
2)If the number is a minus (E10=1) then work out if B10 is greater than D10 + F10 (the positive version of B10)

=IF(E10=0,IF(TRIM(B10)>TRIM(D10),1,0),IF(B10>D10+F10,1,0))
The thinking behind this is that Excel is not taking + or - numbers into account on this sheet so -5 is being reported as greater than 6, so if I add them together it will report that -5 is not greater than 11.

However, using the exact setup above, Excel is telling me that 10 is not greater than 9.



Can someone have a look at this and let me know where this is going wrong, or, if you have one, a simpler solution.

Many Thanks

Pete