![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Feb 2002
Location: Tampa, Fla
Posts: 44
|
I have a pricing sheet that I have vendor pricing in. How can I highlight the lowest cost in a row?
a1=15.12 b1=12.43 c1=13.50 I want to highlight (in some way)text color or cell background color cell b1 Thanks |
|
|
|
|
|
#2 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: Portland, OR USA
Posts: 1,374
|
Quote:
=A1=MIN($A$1:$C$1) Then click the Format button, and go to the Patterns tab and format as you like. Hope this helps, Russell |
|
|
|
|
|
|
#3 |
|
Board Regular
Join Date: Feb 2002
Location: SRC
Posts: 165
|
This may do you
Sub LowRange() Dim LastRow As Integer Dim FLoop As Integer Dim LowAddress As String LastRow = Range(worksheets("sheet1").UsedRange.Address).Rows.Count LowAddress = "$B$1" For FLoop = 1 To LastRow If Range("B" & FLoop).Value < Range(LowAddress).Value And Range("B" & FLoop).Value <> "" Then LowAddress = Range("B" & FLoop).Address End If Next FLoop Range(LowAddress).Interior.ColorIndex = 3 End Sub |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|