:puzzled:
Hi all,
Can someone help me with the vba code to find the maximum value in a column. My spreadsheet incorporates several columns Agent Number, Date, and Sales are the main concerns. I want an automatic procedure where my macro hightlights the maximum sales of each agent. How can adapt the following macro to suit my needs.
******************************
code:
Sub Find_Max()
Dim searchRange As Range
Dim cell As Range
Dim maxValue, maxRow As Integer
Set searchRange = Columns("L")
maxValue = Application.Max(searchRange)
maxRow = Application.Match(maxValue, searchRange, 0)
Set cell = Cells(maxRow,12)
cell.Select
End Sub
*********************************
Any help on this would greatly appreciated.
Thanks,
Chris