Scroll rows with higlighted bar

  • Thread starter Thread starter Art
  • Start date Start date
A

Art

Hi All,

I'd like to have a highligthed bar that I can scroll the rows of a
worksheet with the up and down arrow keys, highlinghting one row at a time.

NOTE: this is not the same as clicking the row number to highlight the
complete row.

Is this possible?
Thanks
D
 
assign to a button or shape
sub scrolldown1row()
ActiveWindow.SmallScroll Down:=1
end sub
 
Do you mean this Art

This event you must place in a sheet module
Right click on a sheet tab and choose view code
paste the event in there
Alt-Q to go back to Excel

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Cells(Target.Row, 1).Range("A1:F1").Select
End Sub

This will select the cells in A:F off the active row
With the tab key you can go to a cell in the selection
 
I re-read your post
Put this code in the ThisWorkbook module and it will change the rowl you are
in when you move the cursor keys.
Change the commenting for only the active cell.

Private Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target
As Excel.Range)
Static OldCell As Range
If Not OldCell Is Nothing Then
'OldCell.Interior.ColorIndex = xlColorIndexNone
OldCell.EntireRow.Interior.ColorIndex = xlColorIndexNone
End If
' Target.Interior.ColorIndex = 6
Target.EntireRow.Interior.ColorIndex = 6

Set OldCell = Target
End Sub
 
Back
Top