Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default HIGHLIGHTING ROWS & COLUMNS

I have a worksheet that is 61 columns wide and 21 rows
high. I would like to be able to highlight the entire Row
and Column, relative to the cell that is active (up and
down, left and right), within this grid. Can anyone
suggest anything, perhaps in conditional formatting, that
might achieve this task?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 90
Default HIGHLIGHTING ROWS & COLUMNS

You know selection is generally something to be avoided, but I assume
you really want it. Conditional formatting is one cool way but it would
seem to be "expensive" to have to format every cell on the sheet. AAR
for any such matters the first step should always be to check with Chip:
http://search.freefind.com/find.html...atch+ALL+words

and John:
http://search.atomz.com/search/?sp-q...6ae-sp00000000

You may be particularly interested in this instead of selection:
http://www.cpearson.com/excel/banding.htm

Since this is the programming area one programming solution is
sCol = Mid(ActiveCell.Address, 2, InStr(2,ActiveCell.Address,"$") - 2)
sRow = ActiveCell.Row
Range(sCol & ":" & sCol & "," & sRow & ":" & sRow).Select

If you want to limit it to 61 columns etc. modify the following.
Range(sCol & "1:" & sCol & "65536" & ",A" & sRow & ":IV" & sRow).Select

sCol is awkward because I don't know a direct way to get the column
letter. Perhaps someone else can supply that.

An alternate solution may be available with EntireRow et al.
You might poke around .Resize but I believe it's only for a rectangle.
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Highlighting Columns Gord Dibben Excel Discussion (Misc queries) 0 February 17th 10 07:56 PM
Highlighting Rows with VB. Xman Excel Worksheet Functions 12 January 23rd 09 12:48 PM
Highlighting rows and columns klsb123 Excel Discussion (Misc queries) 1 October 16th 08 11:46 PM
Highlighting selected cells/rows/columns [email protected] New Users to Excel 0 May 21st 08 09:13 PM
Highlighting rows/columns is there a way to darken the highlight? Jerri Lynne Excel Discussion (Misc queries) 1 February 23rd 08 08:39 PM


All times are GMT +1. The time now is 05:21 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"