View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.newusers
Bob Phillips
 
Posts: n/a
Default extracting data by a criteria ? IF this , then That?

Mike,

Assuming the names are in A, and the scores in B, then select a number of
cells in another column, and then in the formula bar, enter this formula

=IF(ISERROR(SMALL(IF(($B$1:$B$2020)*($B$1:$B$20<= 40),ROW($A1:$A20),""),ROW(
$A1:$A20))),"",
INDEX($A$1:$A$20,SMALL(IF(($B$1:$B$2020)*($B$1:$B $20<=40),ROW($A1:$A20),"")
,ROW($A1:$A20))))

which is an array formula, it should be committed with Ctrl-Shift-Enter, not
just Enter.

This will test for all students with a score of 21-40.

You can highlight the originals using conditional formatting using a formula
of

=COUNTIF(E:E,$A1)0

assuming that you put the formula in columen E


--

HTH

Bob Phillips

(remove nothere from the email address if mailing direct)

"MikeR-Oz" wrote in message
...
AS a teacher I have two columns - 1 with childrens names the 2nd cloumn

has
scores.

I want to be able to extract those children by name who have scored within

a
range of marks or < a mark or scored a set mark etc and have this shown in

a
report or area of the spreadsheet.

Possible?

ALSO can those children who meet the criteria have the original cells with
their 2 columns automatically change colour ? as a way of highlighting

them?

Thanks
for your assistance
Mike