Give Color to negative number

R

Rohan

Hello everyone,

I have a question about a formula.
I have 3 colums, lets say A, B and C (in C we have the result of A-B).
what I want is:

When A-B= negative number it should turn Red and when its positive it must
be green.

I hope someone can help me.

Kind regards,

Rohan
 
J

Jack Dahlgren

Sorry, that sort of conditional formatting can not be done. You could
display an indicator which could be read or green or the result, but not
both in the same field. Also you can't control the text color in a cell
using a formula.
You could use a macro to do this, but you would need to run the macro
whenever you wanted it to calculate.

If you need the red and green and also the result, make two fields which
each have the same formula. Use one for the result and the other for the
graphical indicator,.

-Jack Dahlgren
 
R

Rohan

Thank you very much.

I was looking for hours on the forum for a solution:)
anyway you have any other suggestion for me.

I shall explain what the client wants.
they have two colums.
1 with baseline cost and the other1 with Actual coast.
in the 3th column they want the difference between baseline cost - actual
cost.
and when the result is negative it should turn "Red" and 'green' for positive.

Do you have some other suggestion for me what i can do.

Kind regards,

Rohan
 
J

Jack Dahlgren

There is a predefined cost variance field which will show the difference
between baseline cost and cost. Why not just display that?

Then use a custom field, set the value to the cost variance field and use a
graphical indicator for it.

Steps:
Insert a column (I'd probably try a text field)
Right click the column header and select customize
Rename the field if necessary
click the formula button
go to the "field" drop down and choose cost variance
click OK
click the "Graphical Indicators" button
set the criteria and indicator the way you want
click ok
click ok

I think your client is mistaken about comparing actual cost to baseline
cost. Actual cost is going to be less than Baseline most of the time if the
task is not completed. They should use cost instead. Cost = actual cost +
remaining cost. Actual cost is only accrued cost.

-Jack Dahlgren
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top