ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   IF Formula to produce coloured statements (https://www.excelbanter.com/excel-programming/326588-if-formula-produce-coloured-statements.html)

Lil Miss Norti

IF Formula to produce coloured statements
 
Dear Experts,

I've quickly scanned this forum and searched the Excel help but to no
avail...could you please assist me?

I have an IF formula as follows:

=IF(G2<=D21,"OVERDUE","OK")

I want the results (either OVERDUE or OK) to be displayed in different
colours - OVERDUE in red and OK in green. I've tried using the [red] and
[green] tags but in the formula it mistakes them for the true/false
statements.

Is there a way to do this?

(FYI, the IF formula is based on dates...I don't know if this is relevant
but the spreadsheet is to show whether or not recurring work/tasks are
overdue and are based on when they were last completed, add on however many
months before the next one is due and then this IF formula reflects the
status of those tasks).

Regards,
Kylii

Lil Miss Norti

IF Formula to produce coloured statements
 
In addition to this...

I now have to have an additional IF statement in the same field. I don't
know if a nested IF will work since its the same as the current one, OR IF
another factor is reached...if this doesnt make sense I will explain in more
detail...

"Lil Miss Norti" wrote:

Dear Experts,

I've quickly scanned this forum and searched the Excel help but to no
avail...could you please assist me?

I have an IF formula as follows:

=IF(G2<=D21,"OVERDUE","OK")

I want the results (either OVERDUE or OK) to be displayed in different
colours - OVERDUE in red and OK in green. I've tried using the [red] and
[green] tags but in the formula it mistakes them for the true/false
statements.

Is there a way to do this?

(FYI, the IF formula is based on dates...I don't know if this is relevant
but the spreadsheet is to show whether or not recurring work/tasks are
overdue and are based on when they were last completed, add on however many
months before the next one is due and then this IF formula reflects the
status of those tasks).

Regards,
Kylii


OJ[_2_]

IF Formula to produce coloured statements
 
Kylii,
A worksheet formula cannot effect a change on the formatting (or any
other part, for that matter) of the sheet itself, it can only return a
value to the cell in which it resides. In order to achieve the effect
you are describing you need to look at Conditional Formatting in the
Format menu and in help.

Hth,
O


Lil Miss Norti

IF Formula to produce coloured statements
 
OJ,

Thanks for your help...

I have another question on IF formulae...

I want a cell to display an IF statement if the data in one of 2 cells
displays a certain result.

I've tried the following:
=IF(Data!A1:B1="Overdue","OVERDUE","OK")
to see whether or not the data in Data!A1 or B1 equals 'Overdue' to then
display it as 'Overdue' on the main worksheet, else to display 'Ok'. Is this
possible with just one IF statement?

Kylii


"OJ" wrote:

Kylii,
A worksheet formula cannot effect a change on the formatting (or any
other part, for that matter) of the sheet itself, it can only return a
value to the cell in which it resides. In order to achieve the effect
you are describing you need to look at Conditional Formatting in the
Format menu and in help.

Hth,
O



GaryDK[_2_]

IF Formula to produce coloured statements
 
Try this, Kylii -

=IF(OR(Data!A1="Overdue",Data!B1="Overdue"),"OVERD UE","OK")

Gary
(less two thru five for direct)



All times are GMT +1. The time now is 12:33 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com