MrExcel Publishing
Your One Stop for Excel Tips & Solutions

highlight particular rows


Posted by kid on February 07, 2000 2:12 AM

1st 4give 4 my poor english..i have problem..please bear
with me on this..let's say i do my work on column A1,
B1,C1 n D1..cell A1 is for item, B1 for name,C1
for marks n D1 for grade.is there any macro that
can highlight the particular rows that is A1,B1,C1 n D1
everytime when "D" n "E" appear in cell D1("D" n "E" means fail)
thanks ..ihope u undersatnd my question is..i'm also
hoping this macro can run in the next cell etc..thanks
regards


Posted by Celia on February 07, 2000 6:02 PM

kid
Instead of a macro, you might like to use one of the following methods.

(1) Put the following formula in cell E1

IF(D1=”D”,”Fail”,IF(D1=”E”,”Fail”,””))

This will put the word “Fail” in cell E1. You can change the formula to any other word(s) you prefer and can drag the formula down column E .

(2) Select the data in column D, go to Format/Conditional Formatting and set two conditions:

Condition 1. Cell Value Is/Equal To/=”D”
Condition 2. Cell Value Is/Equal To/=”E”

For each condition, select your preferred highlighting.

Celia