How do i change the color of a cell when tabbing?

L

Lisa Z

How do i change the color of a cell when tabbing so it's easier to move
around spreadsheet knowing where the cursor is located?
 
S

Socko

Copy the code below to a given worksheet codemodule. Once you do it
and save the excel workbook, on that particular sheet you would see
the cell graying out when you tab or move between range or cells.

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim mySht As Worksheet
Set mySht = Target.Parent
mySht.Cells.Interior.ColorIndex = 0
Target.Interior.ColorIndex = 15
End Sub

I hope this helps...

Selva V Pasupathy
For more on Excel, VBA, & other Resources
Please visit: http://socko.wordpress.com
 

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

Top