Hi,
I currently use a combination of VBA and conditional formatting to highlight the row the cursor is on for a specific worksheet.
VBA Sheet Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Target.Calculate
End Sub
Conditional Formatting:
=CELL("row")=CELL("row",A1)
What I'm finding annoying is when I make a selection change on a sheet in a different workbook and then go back to this spreadsheet the row is no longer highlighted, due to me changing the selection in the other workbook.
Therefore, my question is, can I amend the VBA code to restrict it to that specific workbook/worksheet only (i.e. so that it ignores selection changes in other workbooks)?
Many thanks!
Sam
I currently use a combination of VBA and conditional formatting to highlight the row the cursor is on for a specific worksheet.
VBA Sheet Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Target.Calculate
End Sub
Conditional Formatting:
=CELL("row")=CELL("row",A1)
What I'm finding annoying is when I make a selection change on a sheet in a different workbook and then go back to this spreadsheet the row is no longer highlighted, due to me changing the selection in the other workbook.
Therefore, my question is, can I amend the VBA code to restrict it to that specific workbook/worksheet only (i.e. so that it ignores selection changes in other workbooks)?
Many thanks!
Sam