View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Mike Mike is offline
external usenet poster
 
Posts: 3,101
Default how to high light cells

How about this lets say i want to click cell k6 & i want to high light that
entire row from b6 to af6

"FSt1" wrote:

hi
try this and see if it's what you want..
this is worksheet code. right click the sheet and click view code. paste the
below macro into the code window. only works on the sheet that you paste the
code into.
Selecting outside the range A1:CP300 will not highlight cells(rows). you can
adjust the range to suit.

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim r As Range
Dim ac As Range
Set r = Range("A1:CP300")
Set ac = ActiveCell
If Not Intersect(Target, r) Is Nothing Then
Target.EntireRow.Select
ac.Activate
End If
End Sub

regards
FSt1

"Mike" wrote:

have columns from A1 to A300 TO CP1 TO CP300 if I click on a particulr cell
on any row is it possible to high light that whole row if there is a way
please tell me how!!!