rjplante
Well-known Member
- Joined
- Oct 31, 2008
- Messages
- 574
- Office Version
- 365
- Platform
- Windows
I have been using a process outlined on the tech republic website (see link below) to highlight the selected row from column A to column L. In general the process works great, however I have found a problem. I don't know if the problem is with the process, or if it is with Excel 365.
https://www.techrepublic.com/articl...or-both-using-vba-and-conditional-formatting/
The above process uses VBA on the worksheet to update the term SelRow with the ActiveCell.Row.
The Name manager assigns SelRow to cell Z2 on my spreadsheet.
Then using conditional formatting and entering the formula [=Row(B3)=SelRow] will allow me to fill the cells from A8:L1008 when any cell in column L is selected.
My problem arises when I deleted a row near at the end of the list. I deleted the last row and shifted the cells up. Now if I select a row before the last row I deleted, only the row selected will highlight, no problem. If I select a row after the row I deleted, that row, and the one before it is highlighted. I tried deleting another row at the end of my list which was blank just to see what would happen. Now, anytime after that row is selected, the active row is selected, as well as the previous two. If I cannot figure this out, I will have to scrap the process as this will end up highlighting several rows throughout the worksheet and not just my active row, as data rows are deleted over time.
Any help to restore this process to its proper function would be great.
Thanks in advance!!
Robert
https://www.techrepublic.com/articl...or-both-using-vba-and-conditional-formatting/
The above process uses VBA on the worksheet to update the term SelRow with the ActiveCell.Row.
The Name manager assigns SelRow to cell Z2 on my spreadsheet.
Then using conditional formatting and entering the formula [=Row(B3)=SelRow] will allow me to fill the cells from A8:L1008 when any cell in column L is selected.
My problem arises when I deleted a row near at the end of the list. I deleted the last row and shifted the cells up. Now if I select a row before the last row I deleted, only the row selected will highlight, no problem. If I select a row after the row I deleted, that row, and the one before it is highlighted. I tried deleting another row at the end of my list which was blank just to see what would happen. Now, anytime after that row is selected, the active row is selected, as well as the previous two. If I cannot figure this out, I will have to scrap the process as this will end up highlighting several rows throughout the worksheet and not just my active row, as data rows are deleted over time.
Any help to restore this process to its proper function would be great.
Thanks in advance!!
Robert