How to Highlight active row

matts

New Member
Joined
Sep 11, 2002
Messages
41
Is there a way to highlight a row if it is the active row i.e if I click into any cell in row 2 then the whole row is lit up in yellow or some colour. In that way, I can setup a document so that when a user tabs or arrows down the page, the whole row is highlighted allowing them to easily view across the line all the relevant values.
 

Some videos you may like

Excel Facts

Quick Sum
Select a range of cells. The total appears in bottom right of Excel screen. Right-click total to add Max, Min, Count, Average.

Yogi Anand

MrExcel MVP
Joined
Mar 12, 2002
Messages
11,454
Hi matts:
Welcome to the Board!
You can use the following conditional formatting for the rows of interest ...

Formula Is =cell("row")=row() ... Pattern -- specify color of your choice, say 'Yellow'

This will highlite the entire row on either making an entry in any cell of that row, or using the DEL key, or using the F9 key

If you want to have the entire row highlighted simply on selection without having to make an entry in any cell, or using the DEL key, or the F9 key, you can use the following SUB to force CALC on any cell selection in the sheet:

Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Excel.Range)
Calculate
End Sub

You want to check whether it is desirable for you to use the SUB for the automatic calculation feature.

Regards!

Yogi
 

Yogi Anand

MrExcel MVP
Joined
Mar 12, 2002
Messages
11,454
On 2002-09-15 23:06, Brian from Maui wrote:
Yogi,

I'm trying this formula, but I must be missing something...it doesn't work. :)

Hi Brian:
Step by SteP ...
1. First select the rows of interest
2. Conditional Formating ...
Formula IS =cell("row")=row() Pattern ... Color
What this says is that for any cellmselction create the Pattern for the entire row
3. then if make an entry in any cell, use the DEL key, or the F9 key, the Conditional Formating takes place.

I hope this helps.

Regards!

Yogi
 

Brian from Maui

MrExcel MVP
Joined
Feb 16, 2002
Messages
8,458

ADVERTISEMENT

Aloha Yogi,

Thanks Yogi, I was highlighting parts of a row. Does this work for a range in a row?
This message was edited by Brian from Maui on 2002-09-15 23:33
 

Yogi Anand

MrExcel MVP
Joined
Mar 12, 2002
Messages
11,454
On 2002-09-15 23:32, Brian from Maui wrote:
Aloha Yogi,

Thanks Yogi, I was highlighting parts of a row. Does this work for a range in a row?
This message was edited by Brian from Maui on 2002-09-15 23:33

Hi Brian:

It should ... provided we can specifically define the range that should be operated on.

Regards!

Yogi
 

matts

New Member
Joined
Sep 11, 2002
Messages
41
Thankyou for the responses, that does work well but, only when I enter a value into a cell. I really need a setup where i don't have to enter a value but instead, just select an active cell by clicking into it or arrowing down. When a cell is selected in the range the row should highlight.
 

matts

New Member
Joined
Sep 11, 2002
Messages
41
Hello NateO

That is exactly what I needed. Thankyou for the solution.

matts
 

Watch MrExcel Video

Forum statistics

Threads
1,119,002
Messages
5,575,504
Members
412,672
Latest member
vitaminshop20
Top