Thread: Paint a cell ?
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Paint a cell ?

Maybe

Dim oRow As Range
Dim iCol As Long

For Each oRow In Selection.Rows
If Application.Count(oRow) 0 Then
iCol = Application.Match(Application.Max(oRow), oRow, 0)
Cells(oRow.Row, iCol).Interior.Color = vbRed
End If
Next oRow


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Skic" wrote in message ...
Hi all!

I've got a problem and ask for help.

I need some macro that will highlight (paint) a cell in each row where is
the highest value in this row.

Thanks !