When I'm using Excel 2010, and I have a certain row selected, if I then tab away to another window or sheet, the row/cell that's highlighted is no longer visible. This is really annoying when looking back at the unfocused window. This there a way to turn this functionality off, so that the row is again highlighted on the unfocused Window?
Asked
Active
Viewed 2,050 times
1
-
there doesn't seem to be any option relating to this.. i'm using Excel 2007 and it has the same behavior. – drudge Mar 09 '18 at 20:49
-
@drudge Wow that sucks. What kind of "feature" did Microsoft add here? – leeand00 Mar 09 '18 at 21:08
-
duplicate of 501560 – drudge Mar 09 '18 at 23:26
-
@leeand00, check the code below, it will help you to fix the issue. – Rajesh Sinha Mar 12 '18 at 13:12
1 Answers
-2
I would like to suggest use "Workbook Sheet SelectionChange Event" in place of "Workbook_SheetActivate". Because ultimate you need to select a Cell to highlight the Row.
Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Excel.Range)
If Target.Cells.Count > 1 Then Exit Sub
Application.ScreenUpdating = False
Cells.Interior.ColorIndex = 0
With Target
.EntireRow.Interior.ColorIndex = 19
End With
Application.ScreenUpdating = True
End Sub
How it works: Select a Cell the Row will be highlighted. Move to other sheet and when you return to the sheet, you find still the Row is highlighted.
To remove fill colour from the Row you can use this code,
ActiveCell.Interior.ColorIndex = xlNone
Rajesh Sinha
- 9,218
- 6
- 17
- 37