How can you change the color of the selected range?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How do you change the default colour that excel applies to a selected range
of cells? I do not want to permenantly highlight them (fill them) but I do
want the selected range to be more obvious?
 
Very odd request?

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Cells.Interior.ColorIndex = xlColorIndexNone
Target.Interior.ColorIndex = 3
End Sub


--

HTH

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

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top